Commit a8cff546 by Calen Pennington

Cleaning up the envs/* files so that they will work with gunicorn_django

parent 47f502d8
...@@ -8,7 +8,8 @@ Common traits: ...@@ -8,7 +8,8 @@ Common traits:
""" """
import json import json
from common import * from envs.logsettings import get_logger_config
from envs.common import *
############################### ALWAYS THE SAME ################################ ############################### ALWAYS THE SAME ################################
DEBUG = False DEBUG = False
...@@ -31,10 +32,10 @@ LOG_DIR = ENV_TOKENS['LOG_DIR'] ...@@ -31,10 +32,10 @@ LOG_DIR = ENV_TOKENS['LOG_DIR']
CACHES = ENV_TOKENS['CACHES'] CACHES = ENV_TOKENS['CACHES']
LOGGING = logsettings.get_logger_config(LOG_DIR, LOGGING = get_logger_config(LOG_DIR,
logging_env=ENV_TOKENS['LOGGING_ENV'], logging_env=ENV_TOKENS['LOGGING_ENV'],
syslog_addr=(ENV_TOKENS['SYSLOG_SERVER'], 514), syslog_addr=(ENV_TOKENS['SYSLOG_SERVER'], 514),
debug=False) debug=False)
############################## SECURE AUTH ITEMS ############################### ############################## SECURE AUTH ITEMS ###############################
# Secret things: passwords, access keys, etc. # Secret things: passwords, access keys, etc.
......
...@@ -24,8 +24,7 @@ import tempfile ...@@ -24,8 +24,7 @@ import tempfile
import djcelery import djcelery
from path import path from path import path
from askbotsettings import * # this is where LIVESETTINGS_OPTIONS comes from from envs.askbotsettings import * # this is where LIVESETTINGS_OPTIONS comes from
import logsettings
################################### FEATURES ################################### ################################### FEATURES ###################################
COURSEWARE_ENABLED = True COURSEWARE_ENABLED = True
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
These are debug machines used for content creators, so they're kind of a cross These are debug machines used for content creators, so they're kind of a cross
between dev machines and AWS machines. between dev machines and AWS machines.
""" """
from aws import * from envs.aws import *
DEBUG = True DEBUG = True
TEMPLATE_DEBUG = True TEMPLATE_DEBUG = True
......
...@@ -7,15 +7,16 @@ sessions. Assumes structure: ...@@ -7,15 +7,16 @@ sessions. Assumes structure:
/mitx # The location of this repo /mitx # The location of this repo
/log # Where we're going to write log files /log # Where we're going to write log files
""" """
from common import * from envs.common import *
from envs.logsettings import get_logger_config
DEBUG = True DEBUG = True
TEMPLATE_DEBUG = True TEMPLATE_DEBUG = True
LOGGING = logsettings.get_logger_config(ENV_ROOT / "log", LOGGING = get_logger_config(ENV_ROOT / "log",
logging_env="dev", logging_env="dev",
tracking_filename="tracking.log", tracking_filename="tracking.log",
debug=True) debug=True)
DATABASES = { DATABASES = {
'default': { 'default': {
......
...@@ -13,7 +13,7 @@ Dir structure: ...@@ -13,7 +13,7 @@ Dir structure:
/log # Where we're going to write log files /log # Where we're going to write log files
""" """
from dev import * from envs.dev import *
DATABASES = { DATABASES = {
'default': { 'default': {
......
...@@ -7,14 +7,15 @@ sessions. Assumes structure: ...@@ -7,14 +7,15 @@ sessions. Assumes structure:
/mitx # The location of this repo /mitx # The location of this repo
/log # Where we're going to write log files /log # Where we're going to write log files
""" """
from common import * from envs.common import *
from envs.logsettings import get_logger_config
STATIC_GRAB = True STATIC_GRAB = True
LOGGING = logsettings.get_logger_config(ENV_ROOT / "log", LOGGING = get_logger_config(ENV_ROOT / "log",
logging_env="dev", logging_env="dev",
tracking_filename="tracking.log", tracking_filename="tracking.log",
debug=False) debug=False)
DATABASES = { DATABASES = {
'default': { 'default': {
......
...@@ -7,7 +7,8 @@ sessions. Assumes structure: ...@@ -7,7 +7,8 @@ sessions. Assumes structure:
/mitx # The location of this repo /mitx # The location of this repo
/log # Where we're going to write log files /log # Where we're going to write log files
""" """
from common import * from envs.common import *
from envs.logsettings import get_logger_config
import os import os
INSTALLED_APPS = [ INSTALLED_APPS = [
...@@ -35,10 +36,10 @@ MAKO_TEMPLATES['main'] = [PROJECT_ROOT / 'templates', ...@@ -35,10 +36,10 @@ MAKO_TEMPLATES['main'] = [PROJECT_ROOT / 'templates',
DATA_DIR / 'info', DATA_DIR / 'info',
DATA_DIR / 'problems'] DATA_DIR / 'problems']
LOGGING = logsettings.get_logger_config(TEST_ROOT / "log", LOGGING = get_logger_config(TEST_ROOT / "log",
logging_env="dev", logging_env="dev",
tracking_filename="tracking.log", tracking_filename="tracking.log",
debug=True) debug=True)
DATABASES = { DATABASES = {
'default': { 'default': {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment