diff --git a/Dockerfile b/Dockerfile index aa7fcf9..ccfb4b0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,6 +10,8 @@ RUN \ /config \ /app +ENV DEBUG="False" + CMD cp /app/data/varken.example.ini /config/varken.example.ini && python3 /app/Varken.py --data-folder /config -VOLUME /config \ No newline at end of file +VOLUME /config diff --git a/Varken.py b/Varken.py index 8d6e5eb..a37b494 100644 --- a/Varken.py +++ b/Varken.py @@ -8,6 +8,7 @@ import schedule import threading import platform import distro +import os from sys import exit from time import sleep @@ -54,6 +55,9 @@ if __name__ == "__main__": else: exit("{} does not exist".format(ARG_FOLDER)) + if os.getenv('DEBUG', False) == 'True': + opts.debug = True + # Initiate the logger vl = VarkenLogger(data_folder=DATA_FOLDER, debug=opts.debug) vl.logger.info('Starting Varken...')