fix(readme): more informations about postgres

This commit is contained in:
Thomas Maurice 2024-03-27 09:15:31 +01:00
parent 4667b5de57
commit f563e24b86
Signed by: thomas
GPG key ID: 1D577F50583032A6

View file

@ -171,7 +171,9 @@ Then create the [user](https://docs.ansible.com/ansible/latest/collections/commu
lc_ctype: "C"
```
Bonus point if you store the username in an encrypted fashion in your repository with either [ansible vault](https://docs.ansible.com/ansible/latest/vault_guide/vault_managing_passwords.html) or [sops](https://github.com/getsops/sops).
To create the user and the database you will need to `become` the postgres user on the server, you can achieve this by adding the `become: true` and `become_user: postgres` directives to your relevant tasks.
Bonus point if you store the password in an encrypted fashion in your repository with either [ansible vault](https://docs.ansible.com/ansible/latest/vault_guide/vault_managing_passwords.html) or [sops](https://github.com/getsops/sops).
If you end up using sops, please also encrypt your secret with the following age public key so I am able to decrypt them later on `age18rkuwwpzl3az5gr093uhvk7cwg348eajxsm9fjansur5qa97csfs597zh6`, this can be achieved running `sops <file> --add-age <my key>`