mirror of
https://github.com/spiral-project/ihatemoney.git
synced 2025-04-29 01:42:37 +02:00
Enhance postgresql installation docs.
This commit is contained in:
parent
4dd9da8e7c
commit
9fe84bc1a2
2 changed files with 12 additions and 2 deletions
|
@ -27,7 +27,10 @@ format used can be found on `the SQLAlchemy documentation`_.
|
||||||
If you're using PostgreSQL, Your client must use utf8. Unfortunately,
|
If you're using PostgreSQL, Your client must use utf8. Unfortunately,
|
||||||
PostgreSQL default is to use ASCII. Either change your client settings,
|
PostgreSQL default is to use ASCII. Either change your client settings,
|
||||||
or specify the encoding by appending ``?client_encoding=utf8`` to the
|
or specify the encoding by appending ``?client_encoding=utf8`` to the
|
||||||
connection string.
|
connection string. This will look like::
|
||||||
|
|
||||||
|
SQLALCHEMY_DATABASE_URI = 'postgresql://myuser:mypass@localhost/dbname?client_encoding=utf8'
|
||||||
|
|
||||||
|
|
||||||
`SECRET_KEY`
|
`SECRET_KEY`
|
||||||
------------
|
------------
|
||||||
|
|
|
@ -89,7 +89,14 @@ Configure database with PostgreSQL (optional)
|
||||||
|
|
||||||
pip install psycopg2
|
pip install psycopg2
|
||||||
|
|
||||||
2. Configure :ref:`SQLALCHEMY_DATABASE_URI <configuration>` accordingly
|
2. Create the users and tables. On the command line, this looks like::
|
||||||
|
|
||||||
|
sudo -u postgres psql
|
||||||
|
postgres=# create database mydb;
|
||||||
|
postgres=# create user myuser with encrypted password 'mypass';
|
||||||
|
postgres=# grant all privileges on database mydb to myuser;
|
||||||
|
|
||||||
|
3. Configure :ref:`SQLALCHEMY_DATABASE_URI <configuration>` accordingly.
|
||||||
|
|
||||||
|
|
||||||
Deploy it
|
Deploy it
|
||||||
|
|
Loading…
Reference in a new issue