Improvements to initdb stuff
This commit is contained in:
@@ -7,6 +7,7 @@ postgres:
|
||||
python: python-psycopg2
|
||||
service: postgresql
|
||||
conf_dir: /var/lib/pgsql/data
|
||||
runtime_dir: /var/lib/pgsql/data
|
||||
create_cluster: False
|
||||
init_db: False
|
||||
version: 9.1
|
||||
@@ -21,5 +22,6 @@ postgres:
|
||||
commands:
|
||||
initdb: service postgresql initdb
|
||||
initdb_user: root
|
||||
initdb_args: --data-checksum
|
||||
user: postgres
|
||||
group: postgres
|
||||
|
||||
@@ -32,8 +32,8 @@ postgresql-initdb:
|
||||
cmd.run:
|
||||
- cwd: /
|
||||
- user: {{ postgres.initdb_user }}
|
||||
- name: {{ postgres.commands.initdb }}
|
||||
- unless: test -f {{ postgres.conf_dir }}/postgresql.conf
|
||||
- name: {{ postgres.commands.initdb }} {{ postgres.initdb_args }} -D {{ postgres.runtime_dir }}
|
||||
- unless: test -f {{ postgres.runtime_dir }}/PG_VERSION
|
||||
- env:
|
||||
LC_ALL: C.UTF-8
|
||||
{% endif %}
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
RedHat:
|
||||
init_db: True
|
||||
commands:
|
||||
initdb: initdb /var/lib/pgsql/data
|
||||
initdb: initdb
|
||||
initdb_user: postgres
|
||||
pkg: postgresql-server
|
||||
pkg_client: postgresql
|
||||
pkg_repo: pgdg94
|
||||
@@ -11,8 +12,10 @@ Debian:
|
||||
pkg_repo_file: /etc/apt/sources.list.d/pgdg.list
|
||||
pkg_libpq_dev: libpq-dev
|
||||
Suse:
|
||||
init_db: True
|
||||
commands:
|
||||
initdb: initdb /var/lib/pgsql/data
|
||||
initdb: initdb
|
||||
initdb_user: postgres
|
||||
pkg: postgresql-server
|
||||
pkg_client: postgresql
|
||||
FreeBSD:
|
||||
|
||||
Reference in New Issue
Block a user