forked from mirrors/bookwyrm
Adds email config
This commit is contained in:
parent
23b045d7f7
commit
74de2b5cd3
2 changed files with 13 additions and 2 deletions
|
@ -25,4 +25,8 @@ POSTGRES_HOST=db
|
|||
CELERY_BROKER=redis://redis:6379/0
|
||||
CELERY_RESULT_BACKEND=redis://redis:6379/0
|
||||
|
||||
FLOWER_PORT=5555
|
||||
EMAIL_HOST='smtp.mailgun.org'
|
||||
EMAIL_PORT=587
|
||||
EMAIL_HOST_USER=mail@your.domain.here
|
||||
EMAIL_HOST_PASSWORD=emailpassword123
|
||||
EMAIL_USE_TLS=true
|
||||
|
|
|
@ -4,6 +4,7 @@ import os
|
|||
from environs import Env
|
||||
|
||||
env = Env()
|
||||
DOMAIN = env('DOMAIN')
|
||||
|
||||
# celery
|
||||
CELERY_BROKER = env('CELERY_BROKER')
|
||||
|
@ -12,6 +13,13 @@ CELERY_ACCEPT_CONTENT = ['application/json']
|
|||
CELERY_TASK_SERIALIZER = 'json'
|
||||
CELERY_RESULT_SERIALIZER = 'json'
|
||||
|
||||
# emailing
|
||||
EMAIL_HOST = env('EMAIL_HOST')
|
||||
EMAIL_PORT = env('EMAIL_PORT')
|
||||
EMAIL_HOST_USER = env('EMAIL_HOST_USER')
|
||||
EMAIL_HOST_PASSWORD = env('EMAIL_HOST_PASSWORD')
|
||||
EMAIL_USE_TLS = env('EMAIL_USE_TLS')
|
||||
|
||||
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
|
||||
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
|
||||
|
||||
|
@ -24,7 +32,6 @@ SECRET_KEY = env('SECRET_KEY')
|
|||
# SECURITY WARNING: don't run with debug turned on in production!
|
||||
DEBUG = env.bool('DEBUG', True)
|
||||
|
||||
DOMAIN = env('DOMAIN')
|
||||
ALLOWED_HOSTS = env.list('ALLOWED_HOSTS', ['*'])
|
||||
OL_URL = env('OL_URL')
|
||||
|
||||
|
|
Loading…
Reference in a new issue