File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change 198
198
}
199
199
200
200
201
+ elif DJANGO_ENV == "prod" :
202
+ DEBUG = False
203
+ SECRET_KEY = os .environ ["SECRET_KEY" ]
204
+
205
+ ALLOWED_HOSTS = [
206
+ "127.0.0.1" ,
207
+ "localhost" ,
208
+ "internal.europython.eu" ,
209
+ ]
210
+
211
+ DATABASES = {
212
+ "default" : {
213
+ "ENGINE" : "django.db.backends.postgresql" ,
214
+ "NAME" : os .environ ["POSTGRES_DB" ],
215
+ "USER" : os .environ ["POSTGRES_USER" ],
216
+ "PASSWORD" : os .environ ["POSTGRES_PASSWORD" ],
217
+ "HOST" : "db" ,
218
+ "PORT" : "5432" , # internal port
219
+ }
220
+ }
221
+
222
+ # For 500 errors to appear on stderr
223
+ # For now it's good for docker, in the future sentry/or rollabar should be
224
+ # here
225
+ LOGGING = {
226
+ "version" : 1 ,
227
+ "disable_existing_loggers" : False ,
228
+ "handlers" : {
229
+ "console" : {
230
+ "class" : "logging.StreamHandler" ,
231
+ "stream" : "ext://sys.stderr" ,
232
+ },
233
+ },
234
+ "loggers" : {
235
+ "django" : {
236
+ "handlers" : ["console" ],
237
+ "level" : "WARNING" ,
238
+ "propagate" : True ,
239
+ },
240
+ },
241
+ }
242
+
243
+ DISCORD_BOT_TOKEN = os .environ ["DISCORD_BOT_TOKEN" ]
244
+
245
+ CSRF_TRUSTED_ORIGINS = [
246
+ "https://internal.europython.eu" ,
247
+ ]
201
248
202
249
203
250
elif DJANGO_ENV == "build" :
You can’t perform that action at this time.
0 commit comments