Alanny Lopez | f7799d0 | 2018-02-24 23:29:35 -0600 | [diff] [blame] | 1 | apiVersion: extensions/v1beta1 |
| 2 | kind: Deployment |
| 3 | metadata: |
| 4 | name: ${deploy_name} |
| 5 | namespace: openbmc |
| 6 | labels: |
| 7 | app: ${deploy_name} |
| 8 | spec: |
| 9 | replicas: 1 |
| 10 | selector: |
| 11 | matchLabels: |
| 12 | app: ${deploy_name} |
| 13 | template: |
| 14 | metadata: |
| 15 | labels: |
| 16 | app: ${deploy_name} |
| 17 | spec: |
| 18 | volumes: |
| 19 | - name: config |
| 20 | persistentVolumeClaim: |
| 21 | claimName: ${h_claim} |
| 22 | containers: |
| 23 | - env: |
| 24 | - name: JAVA_OPTS |
| 25 | value: ${java_options} |
| 26 | - name: JENKINS_OPTS |
| 27 | value: ${jenkins_options} |
| 28 | name: ${pod_name} |
| 29 | image: ${img_name} |
| 30 | ports: |
| 31 | - containerPort: ${http_port} |
| 32 | protocol: TCP |
| 33 | name: ui |
| 34 | - containerPort: ${agent_port} |
| 35 | protocol: TCP |
| 36 | name: slave-listener |
| 37 | resources: {} |
| 38 | volumeMounts: |
| 39 | - name: config |
| 40 | mountPath: ${j_home} |
| 41 | nodeSelector: |
| 42 | beta.kubernetes.io/arch: ${ARCH} |
| 43 | --- |
| 44 | apiVersion: v1 |
| 45 | kind: Service |
| 46 | metadata: |
| 47 | labels: |
| 48 | app: jenkins-master |
| 49 | name: jenkins-master |
| 50 | namespace: openbmc |
| 51 | spec: |
| 52 | clusterIP: ${cluster_ip} |
| 53 | ports: |
| 54 | - name: ui |
| 55 | port: ${http_port} |
| 56 | nodePort: ${http_nodeport} |
| 57 | protocol: TCP |
| 58 | - name: slave-listener |
| 59 | port: ${agent_port} |
| 60 | nodePort: ${agent_nodeport} |
| 61 | protocol: TCP |
| 62 | selector: |
| 63 | app: jenkins-master |
| 64 | sessionAffinity: None |
| 65 | type: NodePort |