Merge pull request #140 from dod-ccpo/prod-env

Prod env
This commit is contained in:
dandds 2018-08-08 09:57:29 -04:00 committed by GitHub
commit 3b601af848
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 17 additions and 16 deletions

View File

@ -48,7 +48,7 @@ def make_app(config):
app.register_blueprint(bp)
app.register_blueprint(workspace_routes)
app.register_blueprint(requests_bp)
if ENV != "production":
if ENV != "prod":
app.register_blueprint(dev_routes)
apply_authentication(app)

View File

@ -1,23 +1,23 @@
[default]
PORT=8000
ENVIRONMENT = dev
DEBUG = true
COOKIE_SECRET = some-secret-please-replace
SECRET = change_me_into_something_secret
SECRET_KEY = change_me_into_something_secret
CAC_URL = http://localhost:8000/login-redirect
CA_CHAIN = ssl/server-certs/ca-chain.pem
COOKIE_SECRET = some-secret-please-replace
CRL_DIRECTORY = crl
DEBUG = true
ENVIRONMENT = dev
PERMANENT_SESSION_LIFETIME = 600
PE_NUMBER_CSV_URL = http://c95e1ebb198426ee57b8-174bb05a294821bedbf46b6384fe9b1f.r31.cf5.rackcdn.com/penumbers.csv
REDIS_URI = redis://localhost:6379
PGAPPNAME = atst
PGDATABASE = atat
PGHOST = localhost
PGPASSWORD = postgres
PGPORT = 5432
PGUSER = postgres
PGPASSWORD = postgres
PGDATABASE = atat
SESSION_TYPE = redis
PORT=8000
REDIS_URI = redis://localhost:6379
SECRET = change_me_into_something_secret
SECRET_KEY = change_me_into_something_secret
SESSION_COOKIE_NAME=atat
SESSION_TYPE = redis
SESSION_USE_SIGNER = True
PERMANENT_SESSION_LIFETIME = 600
CRL_DIRECTORY = crl
CA_CHAIN = ssl/server-certs/ca-chain.pem
WTF_CSRF_ENABLED = true

View File

@ -1,2 +1,3 @@
[default]
SESSION_COOKIE_SECURE=True
SESSION_COOKIE_DOMAIN=atat.codes

View File

@ -10,7 +10,7 @@ mkdir -p crl
rsync -rq crl-tmp/. crl/.
rm -rf crl-tmp
if [[ $FLASK_ENV != "production" ]]; then
if [[ $FLASK_ENV != "prod" ]]; then
# place our test CRL there
cp ssl/client-certs/client-ca.der.crl crl/
fi

View File

@ -9,7 +9,7 @@ echo "Resetting CA bundle..."
rm ssl/server-certs/ca-chain.pem &> /dev/null || true
touch $CA_CHAIN
if [[ $FLASK_ENV != "production" ]]; then
if [[ $FLASK_ENV != "prod" ]]; then
# only for testing and development
echo "Copy in testing client CA..."
cat ssl/client-certs/client-ca.crt >> $CA_CHAIN