@@ -22,78 +22,87 @@ spec:
2222 app : drycc-builder
2323 spec :
2424 serviceAccount : drycc-builder
25+ initContainers :
26+ - name : drycc-builder-init
27+ image : docker.io/drycc/python-dev:latest
28+ imagePullPolicy : {{.Values.image_pull_policy}}
29+ command :
30+ - netcat
31+ - -v
32+ - -a
33+ - $(DRYCC_MINIO_SERVICE_HOST):$(DRYCC_MINIO_SERVICE_PORT)
2534 containers :
26- - name : drycc-builder
27- image : {{.Values.image_registry}}/{{.Values.image_org}}/builder:{{.Values.image_tag}}
28- imagePullPolicy : {{.Values.image_pull_policy}}
29- ports :
30- - containerPort : 2223
31- name : ssh
32- - containerPort : 8092
33- name : healthsrv
35+ - name : drycc-builder
36+ image : {{.Values.image_registry}}/{{.Values.image_org}}/builder:{{.Values.image_tag}}
37+ imagePullPolicy : {{.Values.image_pull_policy}}
38+ ports :
39+ - containerPort : 2223
40+ name : ssh
41+ - containerPort : 8092
42+ name : healthsrv
3443{{- if or (.Values.limits_cpu) (.Values.limits_memory)}}
35- resources :
36- limits :
44+ resources :
45+ limits :
3746{{- if (.Values.limits_cpu) }}
38- cpu : {{.Values.limits_cpu}}
47+ cpu : {{.Values.limits_cpu}}
3948{{- end}}
4049{{- if (.Values.limits_memory) }}
41- memory : {{.Values.limits_memory}}
50+ memory : {{.Values.limits_memory}}
4251{{- end}}
4352{{- end}}
44- env :
45- # NOTE(bacongobbler): use drycc/registry_proxy to work around Docker --insecure-registry requirements
46- - name : " DRYCC_REGISTRY_PROXY_HOST"
47- value : " 127.0.0.1"
48- - name : " DRYCC_REGISTRY_PROXY_PORT"
49- value : " {{ .Values.global.registry_proxy_port }}"
50- - name : " HEALTH_SERVER_PORT"
51- value : " 8092"
52- - name : " EXTERNAL_PORT"
53- value : " 2223"
54- - name : BUILDER_STORAGE
55- value : " {{ .Values.global.storage }}"
56- - name : " DRYCC_REGISTRY_LOCATION"
57- value : " {{ .Values.global.registry_location }}"
58- # Set GIT_LOCK_TIMEOUT to number of minutes you want to wait to git push again to the same repository
59- - name : " GIT_LOCK_TIMEOUT"
60- value : " 30"
61- - name : IMAGEBUILDER_IMAGE_PULL_POLICY
62- valueFrom :
63- configMapKeyRef :
64- name : imagebuilder-config
65- key : image_pull_policy
66- # This var needs to be passed so that the minio client (https://github.com/minio/mc) will work in Alpine linux
67- - name : " DOCKERIMAGE"
68- value : " 1"
69- - name : " DRYCC_DEBUG"
70- value : " false"
71- - name : " POD_NAMESPACE"
72- valueFrom :
73- fieldRef :
74- fieldPath : metadata.namespace
75- - name : DRYCC_BUILDER_KEY
76- valueFrom :
77- secretKeyRef :
78- name : builder-key-auth
79- key : builder-key
53+ env :
54+ # NOTE(bacongobbler): use drycc/registry_proxy to work around Docker --insecure-registry requirements
55+ - name : " DRYCC_REGISTRY_PROXY_HOST"
56+ value : " 127.0.0.1"
57+ - name : " DRYCC_REGISTRY_PROXY_PORT"
58+ value : " {{ .Values.global.registry_proxy_port }}"
59+ - name : " HEALTH_SERVER_PORT"
60+ value : " 8092"
61+ - name : " EXTERNAL_PORT"
62+ value : " 2223"
63+ - name : BUILDER_STORAGE
64+ value : " {{ .Values.global.storage }}"
65+ - name : " DRYCC_REGISTRY_LOCATION"
66+ value : " {{ .Values.global.registry_location }}"
67+ # Set GIT_LOCK_TIMEOUT to number of minutes you want to wait to git push again to the same repository
68+ - name : " GIT_LOCK_TIMEOUT"
69+ value : " 30"
70+ - name : IMAGEBUILDER_IMAGE_PULL_POLICY
71+ valueFrom :
72+ configMapKeyRef :
73+ name : imagebuilder-config
74+ key : image_pull_policy
75+ # This var needs to be passed so that the minio client (https://github.com/minio/mc) will work in Alpine linux
76+ - name : " DOCKERIMAGE"
77+ value : " 1"
78+ - name : " DRYCC_DEBUG"
79+ value : " false"
80+ - name : " POD_NAMESPACE"
81+ valueFrom :
82+ fieldRef :
83+ fieldPath : metadata.namespace
84+ - name : DRYCC_BUILDER_KEY
85+ valueFrom :
86+ secretKeyRef :
87+ name : builder-key-auth
88+ key : builder-key
8089{{- if (.Values.builder_pod_node_selector) }}
81- - name : BUILDER_POD_NODE_SELECTOR
82- value : {{.Values.builder_pod_node_selector}}
90+ - name : BUILDER_POD_NODE_SELECTOR
91+ value : {{.Values.builder_pod_node_selector}}
8392{{- end}}
84- livenessProbe :
85- httpGet :
86- path : /healthz
87- port : 8092
88- initialDelaySeconds : 30
89- timeoutSeconds : 1
90- readinessProbe :
91- httpGet :
92- path : /readiness
93- port : 8092
94- initialDelaySeconds : 30
95- timeoutSeconds : 1
96- volumeMounts :
93+ livenessProbe :
94+ httpGet :
95+ path : /healthz
96+ port : 8092
97+ initialDelaySeconds : 30
98+ timeoutSeconds : 1
99+ readinessProbe :
100+ httpGet :
101+ path : /readiness
102+ port : 8092
103+ initialDelaySeconds : 30
104+ timeoutSeconds : 1
105+ volumeMounts :
97106 - name : builder-key-auth
98107 mountPath : /var/run/secrets/api/auth
99108 readOnly : true
0 commit comments