aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Joe Banks <[email protected]>2024-07-26 14:54:29 +0100
committerGravatar Joe Banks <[email protected]>2024-07-26 14:54:29 +0100
commit79ba7ec5e648e8d699ec4ba36e1a57fcdd29b6c8 (patch)
tree481ceb67d0d9275c8ad9702c19ea74550eb4a2c9
parentAdd new config options (diff)
Add LDAP enrollment constants
-rw-r--r--arthur/constants.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/arthur/constants.py b/arthur/constants.py
new file mode 100644
index 0000000..f56bb65
--- /dev/null
+++ b/arthur/constants.py
@@ -0,0 +1,13 @@
+"""Constants, primarily used for LDAP enrollment preferences."""
+
+# Users are only checked for enrollment if they have this role. This doesn't grant them any
+# permissions, it is for performance to avoid iterating roles for every other user in the guild.
+LDAP_BASE_STAFF_ROLE = 267630620367257601
+
+# This is a mapping of LDAP groups to Discord roles. It is used to determine which users should be
+# eligible for LDAP enrollment.
+LDAP_ROLE_MAPPING = {
+ "devops": 409416496733880320,
+ "administrators": 267628507062992896,
+ "moderators": 267629731250176001,
+}