postgres-formula/postgres/codenamemap.yaml
Jon Nelson 0220b67a85 - re-arrange cluster initialization to a set of variables in a dictionary
which control three things:
    1. should we initialize?
    2. if so, how?
    3. what environment variables and user to use
  The approach taken is very similar to what the Apache formula uses, namely:
  a default dictionary which is over-ridden by:
     os-specific defaults,
     then os codename defaults,
     then os finger defaults,
     and finally user-specified pillar values
- this also adds support for grains['osfinger']
2016-07-11 15:29:11 -05:00

23 lines
712 B
YAML

{%- macro ubuntu_block(name, version) %}
{{ name }}:
pkg_repo: deb http://apt.postgresql.org/pub/repos/apt/ {{ name }}-pgdg main
conf_dir: /etc/postgresql/{{ version }}/main
prepare_cluster:
command: pg_createcluster {{ version }} main
test: test -f /var/lib/postgresql/{{ version }}/main/PG_VERSION && test -f /etc/postgresql/{{ version }}/main/postgresql.conf
user: root
env:
LC_ALL: C.UTF-8
{%- endmacro %}
{{ ubuntu_block('wheezy', 9.1) }}
{{ ubuntu_block('trusty', 9.3) }}
{{ ubuntu_block('precise', 9.4) }}
{{ ubuntu_block('jessie', 9.4) }}
{{ ubuntu_block('utopic', 9.4) }}
{{ ubuntu_block('vivid', 9.4) }}
{{ ubuntu_block('wily', 9.4) }}
{{ ubuntu_block('xenial', 9.5) }}