Ansible and Pantheon¶
Ansible can be used to successfully create local dev sites for Pantheon:
- Install Terminus somewhere in the global path (e.g. /usr/local/bin)
- Create a machine token in Pantheon, add it to
passat the root of the client directory (e.g.
reamp/pantheonmachinetoken) (only necessary once per live site)
- There are overrides, a "pantheon" group, and a "Pantheon Site Code" field in the Website List. Check an existing Pantheon site.
- You also need to override the Civi db name on all sites to indicate they're all the same database.
- DB sync strategy on the Website List live site entry should be "Pantheon".
- Add both your own SSH public key and the key of the "run as" user to your Pantheon account.
- Manually SSH into the git server as "run as" user to add to known_hosts (for git)
- Probably running without tags is fine, but this is known to work:
ansible-playbook main-playbook.yml -l mysite.local --tags site-upa,site-mysql,site-main,site-db-sync,site-dns,site-permissions