Skip to content

Instantly share code, notes, and snippets.

@mpolden
Created August 30, 2014 19:19
Show Gist options
  • Save mpolden/3b94b13e4c0319d439c7 to your computer and use it in GitHub Desktop.
Save mpolden/3b94b13e4c0319d439c7 to your computer and use it in GitHub Desktop.
postgresql:
pkg:
- installed
- env:
- LC_ALL: en_US.UTF-8
service:
- running
- enable: true
- require:
- pkg: postgresql
- watch:
- file: /etc/postgresql/9.3/main/pg_hba.conf
- file: /etc/postgresql/9.3/main/postgresql.conf
/etc/postgresql/9.3/main/pg_hba.conf:
file.managed:
- source: salt://files/pg_hba.conf
- user: postgres
- group: postgres
- mode: 0640
- require:
- pkg: postgresql
/etc/postgresql/9.3/main/postgresql.conf:
file.managed:
- source: salt://files/postgresql.conf
- user: postgres
- group: postgres
- mode: 0644
- require:
- pkg: postgresql
postgresql-user-dev:
postgres_user.present:
- name: dev
- password: dev
- require:
- service: postgresql
postgresql-db-dev:
postgres_database.present:
- name: dev
- encoding: UTF-8
- lc_ctype: en_US.UTF-8
- lc_collate: en_US.UTF-8
- template: template0
- owner: dev
- require:
- postgres_user: postgresql-user-dev
@dharmab
Copy link

dharmab commented Oct 20, 2015

An IRC log pointing to this Gist was the third result in Google for this error.

Thanks and keep being awesome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment