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 # We will place any config files in the same directory as the config file
config_dir = os.path.dirname(cfg_filename) 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 # Default action is to run the system in Debug mode
# SECURITY WARNING: don't run with debug turned on in production! # SECURITY WARNING: don't run with debug turned on in production!
DEBUG = _is_true(get_setting( DEBUG = _is_true(get_setting(

View File

@ -33,6 +33,7 @@ flake8==3.8.3 # PEP checking
gunicorn>=20.1.0 # Gunicorn web server gunicorn>=20.1.0 # Gunicorn web server
importlib_metadata # Backport for importlib.metadata importlib_metadata # Backport for importlib.metadata
inventree # Install the latest version of the InvenTree API python library inventree # Install the latest version of the InvenTree API python library
invoke>=1.6.0 # Invoke management tool (must be installed in venv)
markdown==3.3.4 # Force particular version of markdown markdown==3.3.4 # Force particular version of markdown
pep8-naming==0.11.1 # PEP naming convention extension pep8-naming==0.11.1 # PEP naming convention extension
pillow==8.3.2 # Image manipulation pillow==8.3.2 # Image manipulation