mirror of
https://github.com/saltstack-formulas/postgres-formula.git
synced 2025-04-16 09:40:26 +00:00

It is just a variant of init_db. A more correct solution would be to support configuring a different initdb command while passing values from the pillar by default like version. This would make it truly generic but is probably not achievable given current pillar self-referencing capabilities (ie. none). Thus, I decided to make it OS family specific since Debian provides its own tools to manage clusters, etc. Gentoo also has a specific way to initialize a new cluster which does not fit with commands.initdb so the current if/elif would be extended when support is added for Gentoo.
26 lines
587 B
YAML
26 lines
587 B
YAML
postgres:
|
|
pkg: postgresql
|
|
pkg_dev: postgresql-devel
|
|
pkg_libpq_dev: postgresql-libs
|
|
pkg_client: postgresql-client
|
|
pkgs_extra:
|
|
python: python-psycopg2
|
|
service: postgresql
|
|
conf_dir: /var/lib/pgsql/data
|
|
data_dir: /var/lib/pgsql/data
|
|
version: 9.1
|
|
use_upstream_repo: False
|
|
users: {}
|
|
acls: []
|
|
databases: {}
|
|
tablespaces: {}
|
|
postgresconf_backup: True
|
|
postgresconf: ""
|
|
pg_hba.conf: salt://postgres/pg_hba.conf
|
|
initdb: True
|
|
initdb_user: root
|
|
initdb_args: --data-checksum
|
|
commands:
|
|
initdb: service postgresql initdb
|
|
user: postgres
|
|
group: postgres
|