Alanny Lopez | d1bb5b3 | 2017-09-20 11:32:40 -0500 | [diff] [blame] | 1 | apiVersion: batch/v1 |
| 2 | kind: Job |
| 3 | metadata: |
| 4 | name: openbmc${BUILD_ID}-${target} |
| 5 | namespace: ${namespace} |
| 6 | labels: |
| 7 | app: openbmc |
| 8 | stage: build |
| 9 | spec: |
| 10 | template: |
| 11 | metadata: |
| 12 | name: ${podname} |
| 13 | labels: |
| 14 | target: ${target} |
| 15 | spec: |
| 16 | nodeSelector: |
| 17 | beta.kubernetes.io/arch: ${ARCH} |
| 18 | volumes: |
Alanny Lopez | a6b7d4b | 2017-10-19 09:58:25 -0500 | [diff] [blame^] | 19 | - name: workspace |
Alanny Lopez | d1bb5b3 | 2017-09-20 11:32:40 -0500 | [diff] [blame] | 20 | persistentVolumeClaim: |
Alanny Lopez | a6b7d4b | 2017-10-19 09:58:25 -0500 | [diff] [blame^] | 21 | claimName: ${wclaim} |
Alanny Lopez | d1bb5b3 | 2017-09-20 11:32:40 -0500 | [diff] [blame] | 22 | - name: sscdir |
| 23 | persistentVolumeClaim: |
| 24 | claimName: ${sclaim} |
| 25 | restartPolicy: Never |
| 26 | hostNetwork: True |
| 27 | containers: |
| 28 | - image: ${imgname} |
| 29 | name: builder |
| 30 | command: ["/bin/bash","-c"] |
| 31 | args: ["sleep 2h"] |
| 32 | workingDir: ${HOME} |
| 33 | env: |
| 34 | - name: WORKSPACE |
| 35 | value: ${WORKSPACE} |
| 36 | - name: builddir |
| 37 | value: ${builddir} |
| 38 | securityContext: |
| 39 | capabilities: |
| 40 | add: |
| 41 | - SYS_ADMIN |
| 42 | volumeMounts: |
Alanny Lopez | a6b7d4b | 2017-10-19 09:58:25 -0500 | [diff] [blame^] | 43 | - name: workspace |
| 44 | mountPath: ${HOME}/workspace |
Alanny Lopez | d1bb5b3 | 2017-09-20 11:32:40 -0500 | [diff] [blame] | 45 | - name: sscdir |
| 46 | mountPath: ${sscdir} |
| 47 | imagePullSecrets: |
Alanny Lopez | a6b7d4b | 2017-10-19 09:58:25 -0500 | [diff] [blame^] | 48 | - name: ${imgplsec} |