[DO-1046] Add new container template (#30)
Reviewed-on: https://git.avroid.tech/DevOps/jenkins-shared-lib/pulls/30 Co-authored-by: aleksandr.vodyanov <aleksandr.vodyanov@avroid.tech> Co-committed-by: aleksandr.vodyanov <aleksandr.vodyanov@avroid.tech>
This commit is contained in:
committed by
Aleksandr Vodyanov
parent
b614bce24b
commit
9075cba03f
@@ -116,6 +116,38 @@ Object containerAuroraTemplate = """
|
|||||||
- name: ${env.JENKINS_K8S_HARBOR_SECRET}
|
- name: ${env.JENKINS_K8S_HARBOR_SECRET}
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
Object containerAuroraTestTemplate = """
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Pod
|
||||||
|
metadata:
|
||||||
|
annotations:
|
||||||
|
container.apparmor.security.beta.kubernetes.io/aurora: unconfined
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: aurora
|
||||||
|
image: ${env.JENKINS_DOCKER_REGISTRY}/container/container-build-aurora:5.1.1.60
|
||||||
|
securityContext:
|
||||||
|
runAsUser: 1000
|
||||||
|
runAsGroup: 1000
|
||||||
|
capabilities:
|
||||||
|
add:
|
||||||
|
- SYS_ADMIN
|
||||||
|
tty: true
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: 15
|
||||||
|
memory: 128Gi
|
||||||
|
requests:
|
||||||
|
cpu: 15
|
||||||
|
memory: 32Gi
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: ${global.AURORA_CUSTOM_WORKSPACE} # Because home path removed within chroot
|
||||||
|
name: "workspace-volume"
|
||||||
|
ttyEnabled: true
|
||||||
|
imagePullSecrets:
|
||||||
|
- name: ${env.JENKINS_K8S_HARBOR_SECRET}
|
||||||
|
"""
|
||||||
|
|
||||||
Object containerLinuxTemplate = """
|
Object containerLinuxTemplate = """
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Pod
|
kind: Pod
|
||||||
@@ -207,6 +239,8 @@ Object tavroLinuxTemplate = """
|
|||||||
return tavroAuroraV5Template
|
return tavroAuroraV5Template
|
||||||
case 'containerAurora':
|
case 'containerAurora':
|
||||||
return containerAuroraTemplate
|
return containerAuroraTemplate
|
||||||
|
case 'containerAuroraTest':
|
||||||
|
return containerAuroraTestTemplate
|
||||||
case 'containerLinux':
|
case 'containerLinux':
|
||||||
return containerLinuxTemplate
|
return containerLinuxTemplate
|
||||||
case "sonarCubeScanner":
|
case "sonarCubeScanner":
|
||||||
|
|||||||
Reference in New Issue
Block a user