diff --git a/src/teams_bot/cli.py b/src/teams_bot/cli.py index 3e47981..f3528d6 100644 --- a/src/teams_bot/cli.py +++ b/src/teams_bot/cli.py @@ -39,7 +39,7 @@ def teams_bot(ctx): "--password", type=str, default=None, help="the password of the email account" ) @click.option( - "--db_dir", type=str, default="teams_bot_data", help="path to the bot's database" + "--dbdir", type=str, default="teams_bot_data", help="path to the bot's database", envvar="TEAMS_DBDIR" ) @click.option( "-v", "--verbose", count=True, help="show low level delta chat ffi events" @@ -121,7 +121,7 @@ def init(ctx, email: str, password: str, db_dir: str, verbose: int): @teams_bot.command() @click.option( - "--db_dir", type=str, default="teams_bot_data", help="path to the bot's database" + "--dbdir", type=str, default="teams_bot_data", help="path to the bot's database", envvar="TEAMS_DBDIR" ) @click.option( "-v", "--verbose", count=True, help="show low level delta chat ffi events" diff --git a/src/teams_bot/pyinfra.py b/src/teams_bot/pyinfra.py index 69eda69..8c6fc09 100644 --- a/src/teams_bot/pyinfra.py +++ b/src/teams_bot/pyinfra.py @@ -43,8 +43,7 @@ def deploy_teams_bot(unix_user: str, bot_email: str, bot_passwd: str, dbdir: str secrets = [ f"TEAMS_INIT_EMAIL={bot_email}", f"TEAMS_INIT_PASSWORD={bot_passwd}", - f'TEAMS_INIT_DBDIR={dbdir}', - f'TEAMS_RUN_DBDIR={dbdir}', + f'TEAMS_DBDIR={dbdir}', ] env = "\n".join(secrets) files.put(