2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-19 13:35:40 +00:00

Add PLUGIN_FILE to settings.py

This commit is contained in:
Oliver
2022-01-06 12:15:33 +11:00
parent c932597459
commit e0e6dbac94
2 changed files with 8 additions and 0 deletions

View File

@ -89,6 +89,13 @@ with open(cfg_filename, 'r') as cfg:
# We will place any config files in the same directory as the config file
config_dir = os.path.dirname(cfg_filename)
# Check if the plugin.txt file (specifying required plugins) is specified
PLUGIN_FILE = os.getenv('INVENTREE_PLUGIN_FILE')
if not PLUGIN_FILE:
# If not specified, look in the same directory as the configuration file
PLUGIN_FILE = os.path.join(config_dir, 'plugins.txt')
# Default action is to run the system in Debug mode
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = _is_true(get_setting(