customize
This commit is contained in:
parent
79c0838d9c
commit
6c7f961674
13
master.cfg
13
master.cfg
@ -4,6 +4,7 @@
|
||||
import os
|
||||
|
||||
from buildbot.plugins import *
|
||||
from buildbot.www.oauth2 import OAuth2Auth
|
||||
|
||||
# This is a sample buildmaster config file. It must be installed as
|
||||
# 'master.cfg' in your buildmaster's base directory.
|
||||
@ -15,6 +16,11 @@ c = BuildmasterConfig = {}
|
||||
GITEA_SECRET = os.environ.get("GITEA_SECRET")
|
||||
GITEA_TOKEN = os.environ.get("GITEA_TOKEN")
|
||||
|
||||
CLIENT_ID = os.environ.get("GITEA_CLIENT_ID")
|
||||
assert CLIENT_ID
|
||||
CLIENT_SECRET = os.environ.get("GITEA_CLIENT_SECRET")
|
||||
assert CLIENT_SECRET
|
||||
|
||||
####### WORKERS
|
||||
|
||||
# The 'workers' list defines the set of recognized workers. Each element is
|
||||
@ -174,6 +180,13 @@ c["www"] = {
|
||||
"console_view": {},
|
||||
},
|
||||
"change_hook_dialects": {},
|
||||
"auth": OAuth2Auth(
|
||||
CLIENT_ID,
|
||||
CLIENT_SECRET,
|
||||
name="Gitea",
|
||||
authUri="https://gitea.parrrate.ru/login/oauth/authorize",
|
||||
tokenUri="https://gitea.parrrate.ru/login/oauth/access_token",
|
||||
),
|
||||
}
|
||||
if GITEA_SECRET:
|
||||
c["www"]["change_hook_dialects"]["gitea"] = {
|
||||
|
@ -4,4 +4,5 @@ RUN bash worker-setup.sh
|
||||
USER buildbot
|
||||
WORKDIR /buildbot
|
||||
COPY buildbot.tac /buildbot/buildbot.tac
|
||||
RUN rustup component add clippy
|
||||
CMD ["/usr/bin/dumb-init", "twistd", "--pidfile=", "-ny", "buildbot.tac"]
|
||||
|
Loading…
Reference in New Issue
Block a user