forked from evolix/ansible-roles
[Cleanup] postgresql: space before and after variable name
This commit is contained in:
parent
119e134373
commit
9e0202d3de
|
@ -10,13 +10,13 @@
|
|||
|
||||
- name: Allow conf.d/*.conf files to be included in PostgreSQL configuration
|
||||
lineinfile:
|
||||
name: "/etc/postgresql/{{postgresql_version}}/main/postgresql.conf"
|
||||
name: "/etc/postgresql/{{ postgresql_version }}/main/postgresql.conf"
|
||||
line: include_dir = 'conf.d'
|
||||
notify: restart postgresql
|
||||
|
||||
- name: Create conf.d directory
|
||||
file:
|
||||
name: "/etc/postgresql/{{postgresql_version}}/main/conf.d/"
|
||||
name: "/etc/postgresql/{{ postgresql_version }}/main/conf.d/"
|
||||
state: directory
|
||||
owner: postgres
|
||||
group: postgres
|
||||
|
@ -25,7 +25,7 @@
|
|||
- name: Copy PostgreSQL config file
|
||||
template:
|
||||
src: postgresql.conf.j2
|
||||
dest: "/etc/postgresql/{{postgresql_version}}/main/conf.d/zz-evolinux.conf"
|
||||
dest: "/etc/postgresql/{{ postgresql_version }}/main/conf.d/zz-evolinux.conf"
|
||||
owner: postgres
|
||||
group: postgres
|
||||
mode: "0644"
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
- name: Add Munin plugins for PostgreSQL
|
||||
file:
|
||||
state: link
|
||||
src: '/usr/share/munin/plugins/{{item}}'
|
||||
dest: '/etc/munin/plugins/{{item}}'
|
||||
src: '/usr/share/munin/plugins/{{ item }}'
|
||||
dest: '/etc/munin/plugins/{{ item }}'
|
||||
with_items:
|
||||
- postgres_bgwriter
|
||||
- postgres_checkpoints
|
||||
|
@ -26,10 +26,10 @@
|
|||
- name: Add Munin plugins for PostgreSQL (for specific databases)
|
||||
file:
|
||||
state: link
|
||||
src: '/usr/share/munin/plugins/{{item[0]}}'
|
||||
dest: '/etc/munin/plugins/{{item[0]}}{{item[1]}}'
|
||||
src: '/usr/share/munin/plugins/{{ item[0] }}'
|
||||
dest: '/etc/munin/plugins/{{ item[0] }}{{ item[1] }}'
|
||||
with_nested:
|
||||
- ['postgres_cache_', 'postgres_connections_', 'postgres_locks_', 'postgres_querylength_', 'postgres_scans_', 'postgres_size_', 'postgres_transactions_', 'postgres_tuples_']
|
||||
- '{{postgresql_databases}}'
|
||||
- '{{ postgresql_databases }}'
|
||||
notify: restart munin-node
|
||||
when: etc_munin_plugins.stat.exists and usr_share_munin_plugins.stat.exists
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
lineinfile:
|
||||
name: /etc/nagios/nrpe.d/evolix.cfg
|
||||
regexp: '^command\[check_pgsql\]='
|
||||
line: 'command[check_pgsql]=/usr/lib/nagios/plugins/check_pgsql -H localhost -l nrpe -p "{{postgresql_nrpe_password.stdout}}"'
|
||||
line: 'command[check_pgsql]=/usr/lib/nagios/plugins/check_pgsql -H localhost -l nrpe -p "{{ postgresql_nrpe_password.stdout }}"'
|
||||
notify: restart nagios-nrpe-server
|
||||
when: postgresql_create_nrpe_user.changed
|
||||
when: nrpe_evolix_config.stat.exists
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
|
||||
- name: Install postgresql package
|
||||
apt:
|
||||
name: '{{item}}'
|
||||
name: '{{ item }}'
|
||||
with_items:
|
||||
- "postgresql-{{postgresql_version}}"
|
||||
- "postgresql-{{ postgresql_version }}"
|
||||
- ptop
|
||||
- libdbd-pg-perl
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
- name: Add PGDG repository
|
||||
apt_repository:
|
||||
repo: "deb http://apt.postgresql.org/pub/repos/apt/ {{ansible_distribution_release}}-pgdg main"
|
||||
repo: "deb http://apt.postgresql.org/pub/repos/apt/ {{ ansible_distribution_release }}-pgdg main"
|
||||
update_cache: yes
|
||||
|
||||
- name: Add GPG key for PGDG repository
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
---
|
||||
- name: Install PostGIS extention
|
||||
- name: Install PostGIS extention
|
||||
apt:
|
||||
name:
|
||||
- postgis
|
||||
|
|
Loading…
Reference in a new issue