@@ -24,16 +24,13 @@ spec:
2424 tasks :
2525 - name : prepare
2626 template : prepare-workspace
27- - name : warm-cache
28- template : cache-warmer
29- dependencies : [prepare]
3027 - name : build
3128 template : build-container
3229 arguments :
3330 parameters :
3431 - name : sha
3532 value : " {{`{{tasks.prepare.outputs.parameters.sha}}`}}"
36- dependencies : [warm-cache ]
33+ dependencies : [prepare ]
3734 - name : update-config
3835 template : update-config
3936 dependencies : [build]
5451 args :
5552 - |
5653 echo "[PREPARE] Setting up workspace..."
57- mkdir -p /workspace/source /workspace/cache
58- chmod -R 777 /workspace/cache
54+ mkdir -p /workspace/source
5955 cd /workspace/source
6056 echo "[PREPARE] Current source directory contents:"
6157 ls -la
7672 git rev-parse HEAD > /workspace/sha.txt
7773 echo "[PREPARE] Process completed with SHA:"
7874 cat /workspace/sha.txt
79- echo "[PREPARE] Cache directory contents:"
80- ls -la /workspace/cache
8175 env :
8276 - name : GIT_USERNAME
8377 valueFrom :
9387 - name : workspace
9488 mountPath : /workspace
9589
96- - name : cache-warmer
97- container :
98- image : gcr.io/kaniko-project/warmer:latest
99- args :
100- - " --cache-dir=/workspace/cache"
101- - " --dockerfile=/workspace/source/Dockerfile"
102- volumeMounts :
103- - name : workspace
104- mountPath : /workspace
105-
10690 - name : build-container
10791 inputs :
10892 parameters :
@@ -116,9 +100,6 @@ spec:
116100 args :
117101 - " --context=/workspace/source"
118102 - " --dockerfile=/workspace/source/Dockerfile"
119- - " --cache=true"
120- - " --cache-dir=/workspace/cache"
121- - " --no-push-cache"
122103 - " --destination=harbor.injunweb.com/injunweb/{{ $.Values.project }}-{{ $app.name }}:{{`{{inputs.parameters.sha}}`}}"
123104 - " --destination=harbor.injunweb.com/injunweb/{{ $.Values.project }}-{{ $app.name }}:latest"
124105 volumeMounts :
0 commit comments