This commit is contained in:
parent
5cc9d7b0e9
commit
0f45b38432
4 changed files with 13 additions and 17 deletions
|
@ -27,5 +27,5 @@ def get_worker_password(worker_name: str) -> str:
|
|||
return "localhost"
|
||||
|
||||
|
||||
def get_worker_names(ENVIRONMENT: str):
|
||||
def get_worker_names(environment: str):
|
||||
return _worker_names
|
||||
|
|
|
@ -31,7 +31,7 @@ importlib.reload(conf.worker)
|
|||
importlib.reload(gitea.blender)
|
||||
importlib.reload(pipeline)
|
||||
|
||||
ENVIRONMENT = os.environ.get("ENVIRONMENT", default="LOCAL")
|
||||
environment = os.environ.get("BUILDBOT_environment", default="LOCAL")
|
||||
|
||||
|
||||
def setup() -> Dict[str, Any]:
|
||||
|
@ -43,7 +43,7 @@ def setup() -> Dict[str, Any]:
|
|||
|
||||
# Workers
|
||||
print("*** Creating platform workers")
|
||||
platform_worker_names = conf.machines.fetch_platform_worker_names(ENVIRONMENT)
|
||||
platform_worker_names = conf.machines.fetch_platform_worker_names(environment)
|
||||
workers: List[buildbot.plugins.worker.Worker] = []
|
||||
configured_worker_names = set()
|
||||
for worker_names in platform_worker_names.values():
|
||||
|
@ -55,7 +55,7 @@ def setup() -> Dict[str, Any]:
|
|||
workers += [
|
||||
buildbot.plugins.worker.Worker(
|
||||
worker_name,
|
||||
conf.machines.get_worker_password(ENVIRONMENT, worker_name),
|
||||
conf.machines.get_worker_password(environment, worker_name),
|
||||
max_builds=1,
|
||||
keepalive_interval=3600,
|
||||
)
|
||||
|
@ -69,7 +69,7 @@ def setup() -> Dict[str, Any]:
|
|||
c["workers"] = workers
|
||||
|
||||
# Builders and Schedulers
|
||||
builders, schedulers = pipeline.populate(ENVIRONMENT)
|
||||
builders, schedulers = pipeline.populate(environment)
|
||||
c["builders"] = builders
|
||||
c["schedulers"] = schedulers
|
||||
|
||||
|
@ -79,7 +79,7 @@ def setup() -> Dict[str, Any]:
|
|||
# status of each build will be pushed to these targets. buildbot/reporters/*.py
|
||||
# has a variety to choose from, like IRC bots.
|
||||
|
||||
gitea_status_service = gitea.blender.setup_service(ENVIRONMENT)
|
||||
gitea_status_service = gitea.blender.setup_service(environment)
|
||||
if gitea_status_service:
|
||||
c["services"] = [gitea_status_service]
|
||||
else:
|
||||
|
@ -90,7 +90,7 @@ def setup() -> Dict[str, Any]:
|
|||
# the 'title' string will appear at the top of this buildbot installation's
|
||||
# home pages (linked to the 'titleURL').
|
||||
|
||||
c["title"] = f"Blender Buildbot - {ENVIRONMENT}"
|
||||
c["title"] = f"Blender Buildbot - {environment}"
|
||||
c["titleURL"] = "https://projects.blender.org"
|
||||
|
||||
# the 'buildbotURL' string should point to the location where the buildbot's
|
||||
|
@ -113,10 +113,10 @@ def setup() -> Dict[str, Any]:
|
|||
c["buildbotNetUsageData"] = None
|
||||
|
||||
# Authentication
|
||||
c["www"]["auth"] = conf.auth.fetch_authentication(ENVIRONMENT)
|
||||
c["www"]["auth"] = conf.auth.fetch_authentication(environment)
|
||||
|
||||
# Authorization
|
||||
c["www"]["authz"] = conf.auth.fetch_authorization(ENVIRONMENT)
|
||||
c["www"]["authz"] = conf.auth.fetch_authorization(environment)
|
||||
|
||||
# Disable UI - does not work
|
||||
c["www"]["plugins"] = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue