postgres: store DB password with other secrets

Let’s uncomplicate our lives. Also I’m not sure if the ~/.pgpass stuff
ever worked properly or even at all.
This commit is contained in:
Timotej Lazar 2024-08-15 12:57:15 +02:00
parent 3261bc7f98
commit 8ba6959065
2 changed files with 3 additions and 28 deletions

View file

@ -65,6 +65,8 @@
line: "ALLOWED_HOSTS = ['{{ dns_name }}']"
- key: 'USER.*PostgreSQL username'
line: " 'USER': '{{ user }}', # PostgreSQL username"
- key: 'PASSWORD.*PostgreSQL password'
line: " 'PASSWORD': '{{ password.db_pass }}', # PostgreSQL password"
# XXX unnecessary?
#- key: '(OPTIONS|PASSWORD).*PostgreSQL password'
# line: " 'OPTIONS': { 'passfile': '{{ user_info.home }}/.pgpass' }, # PostgreSQL password"