Project

General

Profile

Ansible for inherited sites » History » Version 5

Jon Goldberg, 11/09/2020 07:37 PM

1 5 Jon Goldberg
{{last_updated_at}} by {{last_updated_by}}
2
3 1 Jon Goldberg
# Ansible for inherited sites
4
Because inherited/legacy sites weren't created by Ansible, we need to take additional steps to ensure we work properly with them.
5
6
* From the [Website List](https://crm.megaphonetech.com/website-list), make sure to fill in appropriate values in the *Overrides* section of the site.
7 2 Jon Goldberg
* If Ansible can't find passwords for various users, it will try to create them.  Use `pass insert` to fix this.  e.g.:
8 1 Jon Goldberg
9
```bash
10 2 Jon Goldberg
pass insert nwu/nwuserver/mysql/root #MySQL root password
11
pass insert nwu/nwuserver/borg/local #Passphrase for local borg repo
12
pass insert nwu/nwuserver/borg/remote #Passphrase for remote borg repo
13
pass insert nwu/nwuserver/nwu.org/mysql #CMS/CRM MySQL password - one per vhost
14
pass insert nwu/nwuserver/nwu.org/admin #CRM/CRM password for user "admin" - one per vhost
15
pass insert nwu/nwuserver/nwu.org/sitekey #CiviCRM site key - one per vhost
16 1 Jon Goldberg
```
17 3 Jon Goldberg
18
* Running Ansible will uninstall `mod_php`! If you're converting from `mod_php`, you can enable both `mod_php` and `php-fpm` by running this after Ansible PHP roles: `apt install libapache2-mod-php7.0`
19 4 Jon Goldberg
* git commands all run as the "run as user" to keep permissions sane.  If the "run as user" is `www-data`, that means `www-data` needs a home directory for its SSH key.  You can't move the home directory unless you stop its processes - Apache and `php-fpm`.