mirror of
https://github.com/etesync/server
synced 2024-12-26 17:28:08 +00:00
Add env variable to change configuration file path.
ETEBASE_EASY_CONFIG_PATH is optional, the server serches for the configurations files in this order: - "ETEBASE_EASY_CONFIG_PATH" - etebase-server.ini - /etc/etebase-server/etebase-server.ini
This commit is contained in:
parent
47103df48a
commit
e9de8f1adb
@ -141,7 +141,12 @@ MEDIA_URL = '/user-media/'
|
||||
|
||||
|
||||
# Define where to find configuration files
|
||||
config_locations = ['etebase-server.ini', '/etc/etebase-server/etebase-server.ini']
|
||||
config_locations = [
|
||||
os.environ.get('ETEBASE_EASY_CONFIG_PATH', ''),
|
||||
'etebase-server.ini',
|
||||
'/etc/etebase-server/etebase-server.ini',
|
||||
]
|
||||
|
||||
# Use config file if present
|
||||
if any(os.path.isfile(x) for x in config_locations):
|
||||
config = configparser.ConfigParser()
|
||||
|
Loading…
Reference in New Issue
Block a user