mirror of
https://github.com/zulip/zulip.git
synced 2025-11-22 15:31:20 +00:00
settings: Clean up ZULIP_PATHS conditionals.
This replaces the ugly fixed list of things that don't go into var/log with a reasonable test based on the actual path.
This commit is contained in:
@@ -1132,9 +1132,9 @@ else:
|
|||||||
for (var, path) in ZULIP_PATHS:
|
for (var, path) in ZULIP_PATHS:
|
||||||
if DEVELOPMENT:
|
if DEVELOPMENT:
|
||||||
# if DEVELOPMENT, store these files in the Zulip checkout
|
# if DEVELOPMENT, store these files in the Zulip checkout
|
||||||
path = os.path.join(DEVELOPMENT_LOG_DIRECTORY, os.path.basename(path))
|
if path.startswith("/var/log"):
|
||||||
# Some things we just want to store in var/
|
path = os.path.join(DEVELOPMENT_LOG_DIRECTORY, os.path.basename(path))
|
||||||
if var in ['JSON_PERSISTENT_QUEUE_FILENAME', 'ANALYTICS_LOCK_DIR']:
|
else:
|
||||||
path = os.path.join(os.path.join(DEPLOY_ROOT, 'var'), os.path.basename(path))
|
path = os.path.join(os.path.join(DEPLOY_ROOT, 'var'), os.path.basename(path))
|
||||||
vars()[var] = path
|
vars()[var] = path
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user