Skip to content

Peer authentication failed for user "postgres" #5

@teamon

Description

@teamon
TASK: [Ansibles.postgresql | PostgreSQL | Make sure the PostgreSQL databases are present] ***
failed: [server] => (item={'name': u'mydb', 'hstore': True}) => {"failed": true, "item": {"hstore": true, "name": "mydb"}}
msg: unable to connect to database: FATAL:  Peer authentication failed for user "postgres"

vars:

app_postgresql_database: mydb # this is my custom DRY var

postgresql_ext_install_contrib: yes
postgresql_ext_install_dev_headers: yes

postgresql_databases:
  - name: "{{ app_postgresql_database }}"
    hstore: yes # sane default

postgresql_users:
  - name: "{{ app_postgresql_database }}"
    pass: "{{ app_postgresql_password }}"

postgresql_user_privileges:
  - name: "{{ app_postgresql_database }}"
    db: "{{ app_postgresql_database }}"
    priv: "ALL"

This used to work with no issues but somehow now it doesn't. The server is clean ubuntu 13.10x64

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions