blob: a9643acd98a40ad0b251b4702eaa380857d7ad58 [file] [log] [blame]
Pavel Cizinskyd8d8a5a2018-11-06 14:07:40 +01001classes:
Pavel Cizinskyd8d8a5a2018-11-06 14:07:40 +01002- system.docker.swarm.stack.jenkins.slave_base
3parameters:
4 _param:
5 jenkins_slave01_node_name: ${_param:cluster_node01_name}
6 docker:
7 client:
8 stack:
9 jenkins:
10 service:
11 slave01:
12 environment:
13 JENKINS_URL: ${_param:jenkins_master_url}
14 JENKINS_AGENT_NAME: slave01
15 JENKINS_UPDATE_SLAVE: 'true'
Ivan Berezovskiy883d27b2019-02-12 14:10:03 +040016 JENKINS_LOGIN: ${_param:jenkins_client_user}
17 JENKINS_PASSWORD: ${_param:jenkins_client_password}
18 JAVA_OPTS: "-Dhttp.proxyHost=${_param:docker_http_proxy} -Dhttp.nonProxyHosts=|jenkins_master ${_param:jenkins_slave_extra_opts}"
Pavel Cizinskyd8d8a5a2018-11-06 14:07:40 +010019 https_proxy: ${_param:docker_https_proxy}
20 http_proxy: ${_param:docker_http_proxy}
Ivan Berezovskiy883d27b2019-02-12 14:10:03 +040021 no_proxy: "jenkins_master,${_param:docker_no_proxy}"
Pavel Cizinskyd8d8a5a2018-11-06 14:07:40 +010022 deploy:
23 restart_policy:
24 condition: any
25 placement:
26 constraints:
27 - "node.hostname == ${_param:jenkins_slave01_node_name}"
28 image: ${_param:docker_image_jenkins_slave}
29 volumes:
30 - /etc/ssl/certs/java/cacerts:/etc/ssl/certs/java/cacerts:ro
31 - /var/run/docker.sock:/var/run/docker.sock
32 - /usr/bin/docker:/usr/bin/docker:ro
33 - /var/lib/jenkins:/var/lib/jenkins