...
On the remote system, add your SSH public key to ~/.ssh/authorized_keys
.
vars.yml
Create a file called vars.yml
. This file will have some values for our setup, as well as some options that we shall pass to the driver when we run it. (Those options could alternatively be passed through the command line.)
Code Block |
---|
### TODO Maybe some AWS stuff
### SVN credentials
# FIXME these ought to be secured using ansible-vault, or at least this file should not be readable
svn_username: jmft2 # CHANGEME
svn_password: something # CHANGEME
### Where do you want to store output?
mountpoint: /media/apollo
storagedir: /media/apollo
driver_dir: MyDriver
driver: MyDriver
######
### Options for the driver itself
series: ansible
simulation: tut3 # TODO can we do a loop here?
flags: -name "{{series}}_{{simulation}}"
|
Playbook
In your base directory, create the file playbook.yml
:
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
---
- name: Mount S3 storage
hosts: albatross
remote_user: pi
become: no
gather_facts: no
vars_files:
- vars.yml
roles:
- role: mountstorage
- name: Build and run MercuryDPM
hosts: albatross
remote_user: pi
become: no # FIXME Do we have to run everything as root?
gather_facts: no
vars_files:
- vars.yml
roles:
- role: workhorse
|
...