1
0
mirror of https://github.com/fspc/workstand.git synced 2025-03-13 01:43:22 -04:00
2016-03-23 16:29:28 -06:00

56 lines
1.0 KiB
YAML

---
- name: Create the necessary directories
sudo: yes
file:
dest: "{{item}}"
state: directory
owner: "{{postgresql_admin_user}}"
group: "{{postgresql_admin_group}}"
with_items:
- "{{postgresql_conf_directory}}"
- "{{postgresql_data_directory}}"
- "{{postgresql_runtime_directory}}"
- "{{postgresql_log_directory}}"
tags:
- postgresql
- db
- conf
- name: Configure PostgreSQL
sudo: yes
template:
src: "{{item}}"
dest: "{{postgresql_conf_directory}}/{{item}}"
with_items:
- postgresql.conf
- pg_ctl.conf
- environment
notify: restart postgresql
tags:
- postgresql
- db
- conf
- name: Configure PostgreSQL (authentication)
sudo: yes
template:
src: pg_hba.conf
dest: "{{postgresql_hba_file}}"
notify: restart postgresql
tags:
- postgresql
- db
- conf
- name: Configure PostgreSQL (ident)
sudo: yes
template:
src: pg_ident.conf
dest: "{{postgresql_ident_file}}"
notify: restart postgresql
tags:
- postgresql
- db
- conf