-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpiccolo_conf.py
More file actions
33 lines (24 loc) · 808 Bytes
/
piccolo_conf.py
File metadata and controls
33 lines (24 loc) · 808 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
"""Piccolo_conf file is just here so migrations can be made for Piccolo's own internal apps.
For example:
python -m piccolo.main migration new user --auto
"""
import os
from piccolo.conf.apps import AppRegistry
from psqlpy_piccolo import PSQLPyEngine
DB = PSQLPyEngine(
config={
"host": os.environ.get("PG_HOST", "127.0.0.1"),
"port": os.environ.get("PG_PORT", 5432),
"user": os.environ.get("PG_USER", "postgres"),
"password": os.environ.get("PG_PASSWORD", "postgres"),
"database": os.environ.get("PG_DATABASE", "piccolo"),
},
)
# from piccolo.apps.migrations.tables
APP_REGISTRY = AppRegistry(
apps=[
"piccolo.apps.migrations.piccolo_app",
"tests.test_apps.mega.piccolo_app",
"tests.test_apps.music.piccolo_app",
],
)