mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2024-12-12 08:43:55 +02:00
Prevent weird loop error
> Invalid data passed to 'loop', it requires a list, got this instead: matrix_postgres_additional_databases. Hint: If you passed a list/dict of just one element, try adding wantlist=True to your lookup invocation or use q/query instead of lookup. Well, or working around it, as I've done in this commit (which seems more sane than `wantlist=True` stuff).
This commit is contained in:
parent
e2952f16f7
commit
c765ceb270
@ -1,4 +1,5 @@
|
||||
---
|
||||
|
||||
- name: Retrieve IP of postgres container
|
||||
command: "{{ matrix_host_command_docker }} inspect matrix-postgres --format='{% raw %}{{ .NetworkSettings.Networks.{% endraw %}{{ matrix_docker_network }}{% raw %}.IPAddress }}{% endraw %}'"
|
||||
register: matrix_postgres_container_ip
|
||||
@ -12,7 +13,7 @@
|
||||
login_user: "{{ matrix_postgres_connection_username }}"
|
||||
login_password: "{{ matrix_postgres_connection_password }}"
|
||||
login_db: "{{ matrix_postgres_db_name }}"
|
||||
loop: matrix_postgres_additional_databases
|
||||
loop: "{{ matrix_postgres_additional_databases }}"
|
||||
|
||||
- name: Create additional users in postgres
|
||||
postgresql_db:
|
||||
@ -24,4 +25,4 @@
|
||||
login_port: 5432
|
||||
login_user: "{{ matrix_postgres_connection_username }}"
|
||||
login_password: "{{ matrix_postgres_connection_password }}"
|
||||
loop: matrix_postgres_additional_databases
|
||||
loop: "{{ matrix_postgres_additional_databases }}"
|
||||
|
Loading…
Reference in New Issue
Block a user