Rename directory [ci skip]
This commit is contained in:
parent
65c100a812
commit
cf58cc6d23
16
.github/workflows/ci.yml
vendored
16
.github/workflows/ci.yml
vendored
|
@ -201,23 +201,23 @@ jobs:
|
||||||
- name: Cache dependencies
|
- name: Cache dependencies
|
||||||
uses: actions/cache@d9747005de0f7240e5d35a68dca96b3f41b8b340
|
uses: actions/cache@d9747005de0f7240e5d35a68dca96b3f41b8b340
|
||||||
with:
|
with:
|
||||||
path: tools/ansible/.roles
|
path: tools/deployment/.roles
|
||||||
key: dependencies-composer-${{ hashFiles('tools/ansible/requirements.yml') }}
|
key: dependencies-composer-${{ hashFiles('tools/deployment/requirements.yml') }}
|
||||||
|
|
||||||
- name: Download Ansible roles
|
- name: Download Ansible roles
|
||||||
run: ansible-galaxy install -r tools/ansible/requirements.yml
|
run: ansible-galaxy install -r tools/deployment/requirements.yml
|
||||||
|
|
||||||
- name: Export the Ansible Vault password
|
- name: Export the Ansible Vault password
|
||||||
run: echo $ANSIBLE_VAULT_PASS > tools/ansible/.vault-pass.txt
|
run: echo $ANSIBLE_VAULT_PASS > tools/deployment/.vault-pass.txt
|
||||||
env:
|
env:
|
||||||
ANSIBLE_VAULT_PASS: ${{ secrets.ANSIBLE_VAULT_PASS }}
|
ANSIBLE_VAULT_PASS: ${{ secrets.ANSIBLE_VAULT_PASS }}
|
||||||
|
|
||||||
- name: Deploy the code
|
- name: Deploy the code
|
||||||
run: >
|
run: >
|
||||||
ansible-playbook tools/ansible/deploy.yml
|
ansible-playbook tools/deployment/deploy.yml
|
||||||
-i tools/ansible/hosts.yml
|
-i tools/deployment/hosts.yml
|
||||||
-e "ansistrano_deploy_branch=$GITHUB_SHA"
|
-e "ansistrano_deploy_branch=$GITHUB_SHA"
|
||||||
--vault-password-file=tools/ansible/.vault-pass.txt
|
--vault-password-file=tools/deployment/.vault-pass.txt
|
||||||
|
|
||||||
- name: Remove the Ansible Vault password file
|
- name: Remove the Ansible Vault password file
|
||||||
run: rm tools/ansible/.vault-pass.txt
|
run: rm tools/deployment/.vault-pass.txt
|
||||||
|
|
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -30,6 +30,6 @@
|
||||||
/.idea/workspace.xml
|
/.idea/workspace.xml
|
||||||
/.platform/local/
|
/.platform/local/
|
||||||
/node_modules/
|
/node_modules/
|
||||||
/tools/ansible/.roles/
|
/tools/deployment/.roles/
|
||||||
/vendor/
|
/vendor/
|
||||||
/web/themes/custom/*/body-field-values.txt
|
/web/themes/custom/*/body-field-values.txt
|
||||||
|
|
10
README.md
10
README.md
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
## Hosting
|
## Hosting
|
||||||
|
|
||||||
This site is hosted on a DigitalOcean droplet, which was created using [Ansible][] (see `tools/ansible/digitalocean.yml`).
|
This site is hosted on a DigitalOcean droplet, which was created using [Ansible][] (see `tools/deployment/digitalocean.yml`).
|
||||||
|
|
||||||
[Ansible]: https://www.ansible.com
|
[Ansible]: https://www.ansible.com
|
||||||
|
|
||||||
|
@ -12,10 +12,10 @@ To re-provision the server:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Download the required roles
|
# Download the required roles
|
||||||
ansible-galaxy install -r tools/ansible/requirements.yml --force
|
ansible-galaxy install -r tools/deployment/requirements.yml --force
|
||||||
|
|
||||||
# Run the provision playbook
|
# Run the provision playbook
|
||||||
ansible-playbook tools/ansible/provision.yml
|
ansible-playbook tools/deployment/provision.yml
|
||||||
```
|
```
|
||||||
|
|
||||||
### Deploying
|
### Deploying
|
||||||
|
@ -25,14 +25,14 @@ Ansible Vault is used to manage sensitive information like database passwords.
|
||||||
|
|
||||||
Deployments are triggered automatically when changes are pushed to GitHub, and are performed automatically via GitHub Actions on each push to the `production` branch.
|
Deployments are triggered automatically when changes are pushed to GitHub, and are performed automatically via GitHub Actions on each push to the `production` branch.
|
||||||
|
|
||||||
To run a deployment manually, run `ansible-playbook tools/ansible/deploy.yml --ask-vault-pass`.
|
To run a deployment manually, run `ansible-playbook tools/deployment/deploy.yml --ask-vault-pass`.
|
||||||
The Vault password is stored in LastPass.
|
The Vault password is stored in LastPass.
|
||||||
|
|
||||||
[Ansistrano]: https://ansistrano.com
|
[Ansistrano]: https://ansistrano.com
|
||||||
|
|
||||||
#### Generating settings files
|
#### Generating settings files
|
||||||
|
|
||||||
Production settings files are generated automatically during a deployment. This is done using the [opdavies.drupal_settings_files][drupal_settings_files] Ansible role, using variables from `tools/ansible/vars/deploy_vars.yml`, and performed during Ansistrano’s `After update code` build step.
|
Production settings files are generated automatically during a deployment. This is done using the [opdavies.drupal_settings_files][drupal_settings_files] Ansible role, using variables from `tools/deployment/vars/deploy_vars.yml`, and performed during Ansistrano’s `After update code` build step.
|
||||||
|
|
||||||
[drupal_settings_files]: https://galaxy.ansible.com/opdavies/drupal_settings_files
|
[drupal_settings_files]: https://galaxy.ansible.com/opdavies/drupal_settings_files
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue