-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathdefault_config.py
56 lines (49 loc) · 2.42 KB
/
default_config.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# vim:fileencoding=utf-8
# Go Working - Controle das Mesas
#
# Copyright (C) 2019-2020 Fábrica do Futuro
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
## Copiar este arquivo para instance/config.py e editar lá
## Não usar objetos, definir as variáveis tão somente
##
## Por exemplo:
## DEBUG = False
##
## ao invés de:
## class Config(object):
## DEBUG = False
import os
basedir = os.path.abspath(os.path.dirname(__file__))
class Config(object):
DEBUG = False
TESTING = False
SECRET_KEY = "sou um seixo rolado na estrada do lado de la do sertao"
WTF_CSRF_SECRET_KEY = "e ser tao humilhado e sinal de que o diabo e que amassa o meu pao"
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or 'sqlite:///' + os.path.join(basedir, 'instance', 'app.db')
## The SQLALCHEMY_TRACK_MODIFICATIONS configuration option is set to False to disable a feature of Flask-SQLAlchemy that I do not need, which is to signal the application every time a change is about to be made in the database.
SQLALCHEMY_TRACK_MODIFICATIONS = False
class ProductionConfig(Config):
SECRET_KEY = "mas meu corpo e discente e civilizada a mente toca cheira ouve e ve"
WTF_CSRF_SECRET_KEY = "e com amor e anarquia goza que rosca e arrepia rock en rolando em voce"
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or 'mysql+pymysql://goworking:goworking@localhost/goworking'
class DevelopmentConfig(Config):
DEBUG = True
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or 'sqlite:///' + os.path.join(basedir, 'instance', 'goworking.db')
class TestingConfig(Config):
TESTING = True
SECRET_KEY = "no corpo rosa dos ventos tudo e norte tudo e sul"
WTF_CSRF_SECRET_KEY = "se oriente se ocidente toda cor corre pro azul"
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or 'mysql+pymysql://gotesting:gotesting@localhost/gotesting'