[Django]-Django: Peer authentication failed for user

4👍

Looks like you’re missing the host field in your config:

DATABASES = {
    'default': {
        'ENGINE': 'django.contrib.gis.db.backends.postgis',
        'NAME': 'my_project_name',
        'USER': 'db_user',
        'PASSWORD': 'password_of_db_user',
        'HOST': 'localhost' # missing part
    }
}

Leave a comment