-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsettings.py
More file actions
32 lines (25 loc) · 1.33 KB
/
settings.py
File metadata and controls
32 lines (25 loc) · 1.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
from flask_pymongo import PyMongo
from __main__ import app
import json
# global definitions across the application
# just a class used to store static variables
class settings():
# load secrets from file
secrets = open("../secrets/misc.json")
SECRETS = json.load(secrets)
secrets.close()
# DISCORD_ENDPOINT=f"https://discord.com/api/oauth2/authorize?client_id={SECRETS['DISCORD_CLIENT_ID']}&redirect_uri=https%3A%2F%2Fhelios.c3t.eecs.net%2Fauth&response_type=code&scope=identify%20guilds"
DISCORD_ENDPOINT = f"https://discord.com/api/oauth2/authorize?client_id={SECRETS['DISCORD_CLIENT_ID']}&redirect_uri=https%3A%2F%2Fhelios.bfe.one%2Fauth&response_type=code&scope=identify%20guilds"
DISCORD_REQUESTS = []
DISCORD_API = "https://discordapp.com/api"
C3T_DISCORD_ID = "675737159717617666"
# TODO: Make this organic through discord bot
# TODO: Make roles configurable through admin panel
ADMIN_ROLES=["675737925555716117","675738214064980017"]
ADMIN_USERS=["218404015640281088"]
BOT_ENDPOINT="http://127.0.0.1:8081/{}"
NAME_FORMAT="[{title}] {handle}"
# database connections
mongoArtemis = PyMongo(app, uri="mongodb://localhost:27017/artemis")
# define DB connection #TODO: shared file
mongoHelios = PyMongo(app, uri="mongodb://localhost:27017/helios")