Get validation log path if exist

If user has export a specific validation log path, the callback
should use it.

Change-Id: I575eb9c19a1f10f624ee8016c06b8e9491cc6b4d
This commit is contained in:
Mathieu Bultel 2020-07-24 15:06:24 +02:00
parent fd81faf3f0
commit 7b1d281345
1 changed files with 3 additions and 1 deletions

View File

@ -35,7 +35,9 @@ DOCUMENTATION = '''
requirements: None
'''
VALIDATIONS_LOG_DIR = "/var/log/validations"
VALIDATIONS_LOG_DIR = (os.getenv('VALIDATIONS_LOG_DIR')
if os.getenv('VALIDATIONS_LOG_DIR') else
"/var/log/validations")
def current_time():