issue #36 - env variables: now a default value is set at .env.sample if the user wants to add custom config they can create a .env file

This commit is contained in:
SovereigntyIsNotFreedom 2025-03-23 18:28:52 +00:00
parent 4dd9ed0c80
commit 31037597ad
4 changed files with 16 additions and 4 deletions

View file

@ -5,7 +5,10 @@ import json
import random
import os
load_dotenv()
if os.path.exists('.env'):
load_dotenv(".env")
else:
load_dotenv(".env.sample")
websocket_port = os.environ.get("WEBSOCKET_PORT")