From 7777e637fdf6d41a0dd6a435a96d591722c9ecff Mon Sep 17 00:00:00 2001 From: Georg Date: Sat, 4 Sep 2021 08:17:06 +0200 Subject: [PATCH] Admin interface group query, join and unjoin. Signed-off-by: Georg --- config.py | 7 +++++ plugin.py | 90 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 96 insertions(+), 1 deletion(-) diff --git a/config.py b/config.py index 9704ca6..74ef8a5 100644 --- a/config.py +++ b/config.py @@ -122,5 +122,12 @@ conf.registerGlobalValue(Keycloak.options, 'ircgroup', """ , private=True )) +conf.registerGlobalValue(Keycloak.options, 'confluencegroup', + registry.String('', + """ + Keycloak: Group ID for admin grant: confluencegroup + """, + private=True +)) # vim:set shiftwidth=4 tabstop=4 expandtab textwidth=79: diff --git a/plugin.py b/plugin.py index 23a7f82..cf56129 100644 --- a/plugin.py +++ b/plugin.py @@ -32,7 +32,6 @@ import re import requests import secrets import string -import json from supybot import utils, plugins, ircutils, callbacks, ircmsgs from supybot.commands import * from supybot.ircmsgs import nick @@ -260,6 +259,95 @@ class Keycloak(callbacks.Plugin): user = wrap(user, ['anything']) + def admin(self, irc, msg, args, name, option1, option2, option3): + """