1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-02 01:21:21 +03:00

Fix up tower warning log to work with unit tests, local testing, and production

This commit is contained in:
Matthew Jones 2014-04-04 23:10:48 -04:00
parent c60f89f884
commit 221db9b296
2 changed files with 12 additions and 1 deletions

View File

@ -408,7 +408,7 @@ LOGGING = {
'level': 'WARNING',
'class':'logging.handlers.RotatingFileHandler',
'filters': ['require_debug_false'],
'filename': '/var/log/awx/tower_warnings.log',
'filename': os.path.join(BASE_DIR, 'tower_warnings.log'),
'maxBytes': 1024*1024*5, # 5 MB
'backupCount': 5,
'formatter':'simple',

View File

@ -40,6 +40,17 @@ INTERNAL_API_URL = 'http://127.0.0.1:80'
# This directory should not be web-accessible
JOBOUTPUT_ROOT = '/var/lib/awx/job_status/'
LOGGING['handlers']['rotating_file'] = {
'level': 'WARNING',
'class':'logging.handlers.RotatingFileHandler',
'filters': ['require_debug_false'],
'filename': '/var/log/awx/tower_warnings.log',
'maxBytes': 1024*1024*5, # 5 MB
'backupCount': 5,
'formatter':'simple',
}
# Load settings from any .py files in the global conf.d directory specified in
# the environment, defaulting to /etc/awx/conf.d/.
settings_dir = os.environ.get('AWX_SETTINGS_DIR', '/etc/awx/conf.d/')