Pavel Cizinsky | d8d8a5a | 2018-11-06 14:07:40 +0100 | [diff] [blame] | 1 | classes: |
Pavel Cizinsky | d8d8a5a | 2018-11-06 14:07:40 +0100 | [diff] [blame] | 2 | - system.docker.swarm.stack.jenkins.slave_base |
| 3 | parameters: |
| 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 Berezovskiy | 883d27b | 2019-02-12 14:10:03 +0400 | [diff] [blame] | 16 | 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 Cizinsky | d8d8a5a | 2018-11-06 14:07:40 +0100 | [diff] [blame] | 19 | https_proxy: ${_param:docker_https_proxy} |
| 20 | http_proxy: ${_param:docker_http_proxy} |
Ivan Berezovskiy | 883d27b | 2019-02-12 14:10:03 +0400 | [diff] [blame] | 21 | no_proxy: "jenkins_master,${_param:docker_no_proxy}" |
Pavel Cizinsky | d8d8a5a | 2018-11-06 14:07:40 +0100 | [diff] [blame] | 22 | 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 |
Denis Egorenko | 4d18429 | 2019-05-16 17:14:27 +0400 | [diff] [blame^] | 31 | - /dev/urandom:/dev/random:ro |
Pavel Cizinsky | d8d8a5a | 2018-11-06 14:07:40 +0100 | [diff] [blame] | 32 | - /var/run/docker.sock:/var/run/docker.sock |
| 33 | - /usr/bin/docker:/usr/bin/docker:ro |
| 34 | - /var/lib/jenkins:/var/lib/jenkins |