Add PATRONICTL_CONFIG_FILE Environment Variable (#1150)

add a `PATRONICTL_CONFIG_FILE` environment variable, which allows configuring the --config-file flag from the environment.
This commit is contained in:
msvechla
2019-08-26 08:42:24 +02:00
committed by Alexander Kukushkin
parent e9a5d25ef3
commit 0d0c4c0a30
+2 -1
View File
@@ -111,7 +111,8 @@ option_insecure = click.option('-k', '--insecure', is_flag=True, help='Allow con
@click.group()
@click.option('--config-file', '-c', help='Configuration file', default=CONFIG_FILE_PATH)
@click.option('--config-file', '-c', help='Configuration file',
envvar='PATRONICTL_CONFIG_FILE', default=CONFIG_FILE_PATH)
@click.option('--dcs', '-d', help='Use this DCS', envvar='DCS')
@option_insecure
@click.pass_context