mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-10-26 05:50:36 -07:00
tests: fix tests on Debian 8
This commit is contained in:
parent
cf62a62b83
commit
c20d1fced7
6 changed files with 24 additions and 14 deletions
|
|
@ -52,15 +52,15 @@
|
|||
loop_var: postgresql_package_item
|
||||
when: ansible_pkg_mgr == 'apt'
|
||||
|
||||
- name: Initialize postgres (systemd)
|
||||
- name: Initialize postgres (RedHat systemd)
|
||||
command: postgresql-setup initdb
|
||||
when: ansible_distribution == "Fedora" or (ansible_os_family == "RedHat" and ansible_distribution_major_version|int >= 7)
|
||||
|
||||
- name: Initialize postgres (sysv)
|
||||
- name: Initialize postgres (RedHat sysv)
|
||||
command: /sbin/service postgresql initdb
|
||||
when: ansible_os_family == "RedHat" and ansible_distribution_major_version|int <= 6
|
||||
|
||||
- name: Iniitalize postgres (upstart)
|
||||
- name: Iniitalize postgres (Debian)
|
||||
command: /usr/bin/pg_createcluster {{ pg_ver }} main
|
||||
# Sometimes package install creates the db cluster, sometimes this step is needed
|
||||
ignore_errors: True
|
||||
|
|
|
|||
10
test/integration/roles/setup_postgresql_db/vars/Debian-8.yml
Normal file
10
test/integration/roles/setup_postgresql_db/vars/Debian-8.yml
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
postgresql_service: "postgresql"
|
||||
|
||||
postgresql_packages:
|
||||
- "postgresql"
|
||||
- "postgresql-common"
|
||||
- "python-psycopg2"
|
||||
|
||||
pg_hba_location: "/etc/postgresql/9.4/main/pg_hba.conf"
|
||||
pg_dir: "/var/lib/postgresql/9.4/main"
|
||||
pg_ver: 9.4
|
||||
Loading…
Add table
Add a link
Reference in a new issue