From c4c9b226ac16030b6fd83611cafef5c3dc470b80 Mon Sep 17 00:00:00 2001 From: Thomas Renger Date: Fri, 1 Nov 2024 16:35:53 +0100 Subject: [PATCH] Make MASTODON_URL configurable --- bot/bot.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bot/bot.py b/bot/bot.py index d25ae9e..f932efd 100644 --- a/bot/bot.py +++ b/bot/bot.py @@ -1,3 +1,4 @@ +import os import moon from mastodon import Mastodon from pytz import timezone @@ -5,9 +6,8 @@ from datetime import datetime # Set up Mastodon mastodon = Mastodon( - access_token = 'testtoken.secret', - # api_base_url = 'https://fnordon.de/' - api_base_url = 'https://mastodon.wazongtest.de/' + access_token = 'token.secret', + api_base_url = os.getenv('MASTODON_URL', 'https://mastodon.wazongtest.de/') ) tz = timezone('Europe/Berlin')