remove hardcoded secret key, rely on env variable
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -11,7 +11,7 @@ from create_events import createEvents
|
||||
basedir = os.path.abspath(os.path.dirname(__file__))
|
||||
|
||||
app = Flask(__name__)
|
||||
app.config['SECRET_KEY'] = 'HwG55rpe83jcaglifXm8NuF4WEeXyJV4'
|
||||
app.config['SECRET_KEY'] = os.environ['SECRET_KEY']
|
||||
app.config['SQLALCHEMY_DATABASE_URI'] =\
|
||||
'sqlite:///' + os.path.join(basedir, os.environ['SQLITE_DB'])
|
||||
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
|
||||
|
@@ -9,7 +9,7 @@ from apscheduler.triggers.cron import CronTrigger
|
||||
basedir = os.path.abspath(os.path.dirname(__file__))
|
||||
|
||||
app = Flask(__name__)
|
||||
app.config['SECRET_KEY'] = 'HwG55rpe83jcaglifXm8NuF4WEeXyJV4'
|
||||
app.config['SECRET_KEY'] = os.environ['SECRET_KEY']
|
||||
app.config['SQLALCHEMY_DATABASE_URI'] =\
|
||||
'sqlite:///' + os.path.join(basedir, os.environ['SQLITE_DB'])
|
||||
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
|
||||
|
@@ -5,6 +5,7 @@ services:
|
||||
restart: always
|
||||
environment:
|
||||
- SQLITE_DB=database.db
|
||||
- SECRET_KEY=notasecuresecretkeyonlyuseforlocaldevelopment
|
||||
volumes:
|
||||
- ./database.db:/app/database.db
|
||||
ports:
|
||||
|
Reference in New Issue
Block a user