Given that I have a role name postgres
that runs locally and has this definition of roles/postgres/tasks/main.yml
- name: Ping
postgresql_ping:
login_host: localhost
login_user: postgres
login_password: postgres
db: postgres
- name: Create database
postgresql_db:
login_host: localhost
login_user: postgres
login_password: postgres
name: newdb
encoding: UTF-8
- name: Drop database
postgresql_db:
login_host: localhost
login_user: postgres
login_password: postgres
name: newdb
state: absent
Is there a way for me to reduce that by moving the parameters login_host
, login_user
, and login_password
somewhere else so wherein I use the postgressql
galaxy collection, it will always connect to the same database instance?