aboutsummaryrefslogtreecommitdiff
path: root/modules/private/buildbot/projects/denise/__init__.py
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2021-06-26 10:07:40 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2021-06-26 10:07:40 +0200
commitecd9a3060bdcc4309e4fad6c046b72b880618774 (patch)
tree9e0771cb91b52a90e250a518e1efafcba0493d03 /modules/private/buildbot/projects/denise/__init__.py
parentc20a589de267dded1c096e1c1339b5efe5156f1f (diff)
downloadNix-ecd9a3060bdcc4309e4fad6c046b72b880618774.tar.gz
Nix-ecd9a3060bdcc4309e4fad6c046b72b880618774.tar.zst
Nix-ecd9a3060bdcc4309e4fad6c046b72b880618774.zip
Make wwwrun run the python application
Diffstat (limited to 'modules/private/buildbot/projects/denise/__init__.py')
-rw-r--r--modules/private/buildbot/projects/denise/__init__.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/modules/private/buildbot/projects/denise/__init__.py b/modules/private/buildbot/projects/denise/__init__.py
index 20ba913..2a19ef5 100644
--- a/modules/private/buildbot/projects/denise/__init__.py
+++ b/modules/private/buildbot/projects/denise/__init__.py
@@ -72,6 +72,13 @@ def denise_oms_factory():
72 return "/run/denise_oms_beta/gunicorn.pid" 72 return "/run/denise_oms_beta/gunicorn.pid"
73 73
74 @util.renderer 74 @util.renderer
75 def oms_systemd_service(props):
76 if props.hasProperty("branch") and len(props["branch"]) > 0 and props["branch"] == "master":
77 return "denise-oms"
78 else:
79 return "denise-oms-beta"
80
81 @util.renderer
75 def oms_url(props): 82 def oms_url(props):
76 if props.hasProperty("branch") and len(props["branch"]) > 0 and props["branch"] == "master": 83 if props.hasProperty("branch") and len(props["branch"]) > 0 and props["branch"] == "master":
77 return "https://oms.syanni.eu" 84 return "https://oms.syanni.eu"
@@ -94,7 +101,7 @@ def denise_oms_factory():
94 masterdest=oms_path, 101 masterdest=oms_path,
95 url=oms_url)) 102 url=oms_url))
96 factory.addStep(steps.MasterShellCommand(command=util.Interpolate("chmod -R a+rX %(kw:oms_path)s", oms_path=oms_path))) 103 factory.addStep(steps.MasterShellCommand(command=util.Interpolate("chmod -R a+rX %(kw:oms_path)s", oms_path=oms_path)))
97 factory.addStep(steps.MasterShellCommand(command=util.Interpolate("kill $(cat %(kw:oms_run_path)s)", oms_run_path=oms_run_path))) 104 factory.addStep(steps.MasterShellCommand(command=util.Interpolate("/run/wrappers/bin/sudo systemctl restart %(kw:oms_service)s.service", oms_service=oms_systemd_service)))
98 105
99 return util.BuilderConfig(name="DeniseOMS_build", workernames=["generic-worker-denise"], factory=factory) 106 return util.BuilderConfig(name="DeniseOMS_build", workernames=["generic-worker-denise"], factory=factory)
100 107