From f61bcb4791c2a90ec3cbf23a919f7ad81e475dfb Mon Sep 17 00:00:00 2001 From: SeanChenTaipei Date: Thu, 2 Mar 2023 20:06:38 +0800 Subject: [PATCH] hide config --- main.py | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/main.py b/main.py index 6d5dd4c..81a742e 100644 --- a/main.py +++ b/main.py @@ -26,12 +26,19 @@ CONFIGS = { "PERMANENT_SESSION_LIFETIME": timedelta(minutes=60) } SQL_CONFIG = dict( - database="railway", - user="postgres", - host="containers-us-west-103.railway.app", - port="5913", - password="gv5Mh7cPjCm9YTjAmsYD" + database= os.getenv("PGDATABASE"), + user=os.getenv("PGUSER"), + host=os.getenv("PGHOST"), + port=os.getenv("PGPORT"), + password=os.getenv("PGPASSWORD") ) +# SQL_CONFIG = dict( +# database="railway", +# user="postgres", +# host="containers-us-west-103.railway.app", +# port="5913", +# password="gv5Mh7cPjCm9YTjAmsYD" +# ) # SQL_CONFIG = { # 'database': "tpm", # 'user': "hsienchen",