forked from ISTI-ansible-roles/ansible-roles
d4science-ghn-cluster: playbook to configure a postgresql/pgpool cluster in the dev environment.
This commit is contained in:
parent
59308c5e5c
commit
d11b513c2d
|
@ -3,8 +3,10 @@
|
||||||
pg_use_postgresql_org_repo: True
|
pg_use_postgresql_org_repo: True
|
||||||
|
|
||||||
psql_postgresql_install: True
|
psql_postgresql_install: True
|
||||||
|
psql_pkg_state: installed
|
||||||
postgresql_enabled: True
|
postgresql_enabled: True
|
||||||
psql_pgpool_install: False
|
psql_pgpool_install: False
|
||||||
|
psql_pgpool_pkg_state: installed
|
||||||
# 9.3 is the default version for Ubuntu trusty
|
# 9.3 is the default version for Ubuntu trusty
|
||||||
# It is highly recommended to use the postgresql.org repositories
|
# It is highly recommended to use the postgresql.org repositories
|
||||||
#
|
#
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
---
|
---
|
||||||
- name: install the postgresql packages
|
- name: install the postgresql packages
|
||||||
apt: pkg={{ item }} state=installed
|
apt: pkg={{ item }} state={{ psql_pkg_state }}
|
||||||
with_items: '{{ postgresql_pkgs }}'
|
with_items: '{{ postgresql_pkgs }}'
|
||||||
notify: Restart postgresql
|
notify: Restart postgresql
|
||||||
tags: [ 'postgresql', 'postgres' ]
|
tags: [ 'postgresql', 'postgres' ]
|
||||||
|
|
||||||
- name: Install the packages that ansible needs to manage the postgresql users and databases
|
- name: Install the packages that ansible needs to manage the postgresql users and databases
|
||||||
apt: pkg={{ item }} state=installed
|
apt: pkg={{ item }} state={{ psql_pkg_state }}
|
||||||
with_items:
|
with_items:
|
||||||
- python-psycopg2
|
- python-psycopg2
|
||||||
tags: [ 'postgresql', 'postgres' ]
|
tags: [ 'postgresql', 'postgres' ]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
---
|
---
|
||||||
- name: Install the pgpool package
|
- name: Install the pgpool package
|
||||||
apt: name={{ item }} state=installed
|
apt: name={{ item }} state={{ psql_pgpool_pkg_state }}
|
||||||
with_items: '{{ pgpool_pkgs }}'
|
with_items: '{{ pgpool_pkgs }}'
|
||||||
tags: [ 'postgresql', 'pgpool' ]
|
tags: [ 'postgresql', 'pgpool' ]
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue