fix(postgresql): change tags for some initializing tasks

When building an image, having those tasks in prepare would result in
the DB being initialized with a password, which would then be the same
on each host the image is rolled out to.

This commit prevents that from happening, the DB itself is initialized
in the deploy stage.
This commit is contained in:
Lars Kaiser 2022-12-01 20:30:15 +01:00
parent 724399522c
commit 1715103831
No known key found for this signature in database
GPG key ID: BB97304A16BC5DCF

View file

@ -37,15 +37,15 @@
env:
POSTGRES_PASSWORD: "{{ postgresql_superuser_password }}"
register: postgresql_container
tags: [ 'prepare', 'prepare-postgresql' ]
tags: [ 'deploy', 'deploy-postgresql' ]
- name: Wait for container to be initialized
wait_for:
path: "{{ postgresql_socket_path }}/.s.PGSQL.5432"
tags: [ 'prepare', 'prepare-postgresql' ]
tags: [ 'deploy', 'deploy-postgresql' ]
- name: Stop initialized container
community.docker.docker_container:
name: "{{ postgresql_container_name }}"
state: absent
tags: [ 'prepare', 'prepare-postgresql' ]
tags: [ 'deploy', 'deploy-postgresql' ]