Page MenuHomeDevCentral

D1728.diff
No OneTemporary

D1728.diff

diff --git a/pillar/paas/docker.sls b/pillar/paas/docker.sls
--- a/pillar/paas/docker.sls
+++ b/pillar/paas/docker.sls
@@ -107,10 +107,10 @@
jenkins_slave:
# Slaves for CD
- apsile:
- realm: cd
- elapsi:
+ apsile: &php_for_cd
+ image: php
realm: cd
+ elapsi: *php_for_cd
# Infrastructure and development services
diff --git a/pillar/saas/jenkins.sls b/pillar/saas/jenkins.sls
--- a/pillar/saas/jenkins.sls
+++ b/pillar/saas/jenkins.sls
@@ -14,3 +14,16 @@
cd:
ssh_key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICiWLxPzS8X6NraVwsK95gFGe1pIuz+K0n7aw81nabcf jenkins-master-equatower-cd
network: cd
+
+# -------------------------------------------------------------
+# Jenkins images
+#
+# Each slave uses one Jenkins image.
+#
+# An image can be used by several slaves, so we've more nodes
+# available for parallel builds.
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+jenkins_images:
+ barebone: nasqueron/jenkins-slave-barebone
+ php: nasqueron/jenkins-slave-php
diff --git a/roles/paas-docker/containers/jenkins_slave.sls b/roles/paas-docker/containers/jenkins_slave.sls
--- a/roles/paas-docker/containers/jenkins_slave.sls
+++ b/roles/paas-docker/containers/jenkins_slave.sls
@@ -13,6 +13,7 @@
{% set realm = pillar['jenkins_realms'][container['realm']] %}
{% set home = "/srv/jenkins/" + container['realm'] + "/slaves_homes/" + instance %}
+{% set image = pillar['jenkins_images'][container['image']] %}
# -------------------------------------------------------------
# Home directory
@@ -54,7 +55,7 @@
docker_container.running:
- detach: True
- interactive: True
- - image: nasqueron/jenkins-slave-php
+ - image: {{ image }}
- binds: {{ home }}:/home/app
- networks:
- {{ realm['network'] }}

File Metadata

Mime Type
text/plain
Expires
Mon, Nov 25, 08:53 (21 h, 3 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2260203
Default Alt Text
D1728.diff (1 KB)

Event Timeline