Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#21296 closed Cleanup/optimization (fixed)

settings: adding a the unix socket dir path in DATABASES HOST works for postgres too

Reported by: rm_ Owned by: rm_
Component: Documentation Version: dev
Severity: Normal Keywords: postgres settings host
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The host documentation [1] doesn't mention that passing a unix socket dir (unix_socket_directory in postgresql.conf) as value of HOST will have postgresql use that instead of default /var/run/postgresql/.s.PGSQL.5432 . Since there is an explicit example for MySQL i thought it wasn't supported (i've tried it though :). Tested with django 1.5.4 / postgresql_psycopg2

There are also a couple of stack overflow questions related to this:

http://stackoverflow.com/questions/12317562/trying-to-set-django-and-postgresql-on-heroku
http://stackoverflow.com/questions/10829464/postgresql-and-django-unix-domain-socket

[1] https://docs.djangoproject.com/en/dev/ref/settings/#host

Change History (7)

comment:1 by Tim Graham, 11 years ago

Triage Stage: UnreviewedAccepted
Type: UncategorizedCleanup/optimization
Version: 1.5master

comment:2 by rm_, 11 years ago

Owner: changed from nobody to rm_
Status: newassigned
Triage Stage: AcceptedUnreviewed

comment:3 by rm_, 11 years ago

Has patch: set

comment:4 by rm_, 11 years ago

Triage Stage: UnreviewedAccepted

comment:5 by Tim Graham <timograham@…>, 11 years ago

Resolution: fixed
Status: assignedclosed

In 1e39982b6ef1fd10e53392f4cb52bea3805d186f:

Fixed #21296 -- Added docs for PostgreSQL and unix domains sockets.

comment:6 by Tim Graham <timograham@…>, 11 years ago

In 15a6667a7040739a74c9bc7c83ee9435f517b284:

[1.6.x] Fixed #21296 -- Added docs for PostgreSQL and unix domains sockets.

Backport of 1e39982b6e from master

comment:7 by Tim Graham <timograham@…>, 11 years ago

In 045d192222f531948313bde8d43746dde33b522d:

[1.5.x] Fixed #21296 -- Added docs for PostgreSQL and unix domains sockets.

Backport of 1e39982b6e from master

Note: See TracTickets for help on using tickets.
Back to Top