mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-03-11 09:04:54 +00:00
cfg: Don't fallback to develop config if main is not found
This was needed when our behavior for reading production vs. development configuration depended on the presence of configuration files in expected locations. The current behavior is based on whether --develop option is given or not. This behavior is safer and more predictable. So, remove the option to fallback to develop configuration if the production configuration is not found. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
6230f8e6ce
commit
64b1c21fe0
@ -39,13 +39,8 @@ def get_fallback_config_paths():
|
||||
|
||||
|
||||
def get_config_paths():
|
||||
"""Get config paths.
|
||||
Return the fallback plinth config if the default one does not exist"""
|
||||
root_directory = DEFAULT_ROOT
|
||||
config_path = DEFAULT_CONFIG_FILE
|
||||
if not os.path.isfile(config_path):
|
||||
config_path, root_directory = get_fallback_config_paths()
|
||||
return config_path, root_directory
|
||||
"""Get default config paths."""
|
||||
return '/etc/plinth/plinth.config', '/'
|
||||
|
||||
|
||||
def read(config_path=None, root_directory=None):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user