summaryrefslogtreecommitdiffstats
path: root/config.py
diff options
context:
space:
mode:
authorsyn <isaqtm@gmail.com>2020-03-16 22:17:48 +0300
committersyn <isaqtm@gmail.com>2020-03-16 22:17:48 +0300
commit977c7c38ff4196f43c4784308d81fd7e6a471511 (patch)
tree3e53843c181a60ec7d2b3b1d4dfdf4868859c3a7 /config.py
downloadblure-977c7c38ff4196f43c4784308d81fd7e6a471511.tar.gz
Init commit
Diffstat (limited to 'config.py')
-rw-r--r--config.py23
1 files changed, 23 insertions, 0 deletions
diff --git a/config.py b/config.py
new file mode 100644
index 0000000..ef895ba
--- /dev/null
+++ b/config.py
@@ -0,0 +1,23 @@
+from uuid import UUID
+
+host = '0.0.0.0'
+port = 80
+debug = True
+
+PG_URI = 'postgres://postgres:secure@pg'
+
+APP_SECRET = UUID('8036587d-11ea-4c59-af9b-9da52eded1bc').bytes
+
+NGX_IMAGE_PATH = '/var/ngx_img/{}'
+NGX_IMAGE_URL = '/ngx_img/{}'
+CUT_SIZES = [
+ (256, 256),
+ (512, 512),
+ (1024, 1024),
+ (2048, 2048),
+]
+DELETE_FILE_ON_DELETE = False
+
+NOT_FOUND_IMAGE_CONTENT_TYPE = 'image/jpeg'
+with open('not-found.jpg', 'rb') as f:
+ NOT_FOUND_IMAGE = f.read()