customize

This commit is contained in:
AF 2023-08-05 11:33:12 +00:00
parent 055404504c
commit e02119c15c

View File

@ -173,13 +173,6 @@ c["titleURL"] = "https://gitea.parrrate.ru/PTV/radn-rs"
c["buildbotURL"] = os.environ.get("BUILDBOT_WEB_URL", "http://localhost:8010/")
class GiteaAuth(OAuth2Auth):
name = "Gitea"
authUri = "https://gitea.parrrate.ru/login/oauth/authorize"
tokenUri = "https://gitea.parrrate.ru/login/oauth/access_token"
faIcon = "https://gitea.parrrate.ru/assets/img/logo.svg"
# minimalistic config to activate new web UI
c["www"] = {
"port": os.environ.get("BUILDBOT_WEB_PORT", 8010),
@ -188,7 +181,11 @@ c["www"] = {
"console_view": {},
},
"change_hook_dialects": {},
"auth": GiteaAuth(CLIENT_ID, CLIENT_SECRET),
"auth": util.GiteaAuth(
endpoint="https://gitea.parrrate.ru",
client_id=CLIENT_ID,
client_secret=CLIENT_SECRET,
),
"authz": util.Authz(
allowRules=[util.AnyControlEndpointMatcher(role="admins")], roleMatchers=[]
),