build-python3-image-with-context ○ success

Duration: 29s
Queued: 0s
📁 Stage: docker-image
🖥 Runner: linux-aws-1
Average Duration
47s
This job: 29s
Failure Rate
2.3%
last 30 days

Job Execution Phases

💡 Tip: Click on any phase bar to jump to that section in the log below

Job Analysis

Job Status: Passed

Status: Job passed successfully

Full Job Log

443 lines
Match - of 0
1 22:35:32 Running with gitlab-runner 18.9.0 (07e534ba)
2 22:35:32 on gitlab-runner-linux-1-746bdd58fd-hs4pj wRxjPbsJX, system ID: r_dNAq0sdgwNWv
3 22:35:32 feature flags: FF_USE_FASTZIP:true, FF_USE_NEW_BASH_EVAL_STRATEGY:true, FF_USE_DYNAMIC_TRACE_FORCE_SEND_INTERVAL:true, FF_SCRIPT_SECTIONS:true, FF_USE_ADVANCED_POD_SPEC_CONFIGURATION:true, FF_PRINT_POD_EVENTS:true, FF_USE_DUMB_INIT_WITH_KUBERNETES_EXECUTOR:true, FF_LOG_IMAGES_CONFIGURED_FOR_JOB:true, FF_CLEAN_UP_FAILED_CACHE_EXTRACT:true, FF_GIT_URLS_WITHOUT_TOKENS:true, FF_WAIT_FOR_POD_TO_BE_REACHABLE:true, FF_USE_FLEETING_ACQUIRE_HEARTBEATS:true, FF_USE_JOB_ROUTER:true
4 22:35:32 Resolving secrets
5 22:35:32 section_start:1778106932:prepare_executor
6 22:35:32 +Preparing the "kubernetes" executor
7 22:35:32 "CPURequest" overwritten with "2"
8 22:35:32 "MemoryRequest" overwritten with "4G"
9 22:35:32 Using Kubernetes namespace: gitlab-runner
10 22:35:32 Using Kubernetes executor with image registry.scandit.com/dockerfiles/kaniko:v1.27.3-crane@sha256:72bdc063db14f38a45910d33ccf066ecb088d4833fb2437fef336e49b81fd4ac ...
11 22:35:32 Using attach strategy to execute scripts...
12 22:35:32 Using effective pull policy of [Always] for container build
13 22:35:32 Using effective pull policy of [Always] for container helper
14 22:35:32 Using effective pull policy of [Always] for container init-permissions
15 22:35:32 section_end:1778106932:prepare_executor
16 22:35:32 +section_start:1778106932:prepare_script
17 22:35:32 +Preparing environment
18 22:35:32 Using FF_USE_POD_ACTIVE_DEADLINE_SECONDS, the Pod activeDeadlineSeconds will be set to the job timeout: 1h0m0s...
19 22:35:32 WARNING: Advanced Pod Spec configuration enabled, merging the provided PodSpec to the generated one. This is a beta feature and is subject to change. Feedback is collected in this issue: https://gitlab.com/gitlab-org/gitlab-runner/-/issues/29659 ...
20 22:35:33 Subscribing to Kubernetes Pod events...
21 22:35:33 Type Reason Message
22 22:35:33 Normal Scheduled Successfully assigned gitlab-runner/runner-wrxjpbsjx-project-621-concurrent-0-urg420fo to ip-10-0-24-152.eu-central-1.compute.internal
23 22:35:33 Normal Pulled Container image "gitlab/gitlab-runner-helper:x86_64-v18.8.0" already present on machine
24 22:35:33 Normal Created Created container: init-permissions
25 22:35:33 Normal Started Started container init-permissions
26 22:35:34 Normal Pulling Pulling image "498954711405.dkr.ecr.eu-central-1.amazonaws.com/dockerfiles/kaniko@sha256:72bdc063db14f38a45910d33ccf066ecb088d4833fb2437fef336e49b81fd4ac"
27 22:35:34 Normal Pulled Successfully pulled image "498954711405.dkr.ecr.eu-central-1.amazonaws.com/dockerfiles/kaniko@sha256:72bdc063db14f38a45910d33ccf066ecb088d4833fb2437fef336e49b81fd4ac" in 527ms (527ms including waiting). Image size: 49989654 bytes.
28 22:35:34 Normal Created Created container: build
29 22:35:34 Normal Started Started container build
30 22:35:34 Normal Pulled Container image "gitlab/gitlab-runner-helper:x86_64-v18.8.0" already present on machine
31 22:35:34 Normal Created Created container: helper
32 22:35:35 Normal Started Started container helper
33 22:35:36 Running on runner-wrxjpbsjx-project-621-concurrent-0-urg420fo via gitlab-runner-linux-1-746bdd58fd-hs4pj...
34 22:35:36
35 22:35:36 section_end:1778106936:prepare_script
36 22:35:36 +section_start:1778106936:get_sources
37 22:35:36 +Getting source from Git repository
38 22:35:37 Gitaly correlation ID: 01KQZPX6F72PVK1B54H4S4V0X6
39 22:35:37 Fetching changes with git depth set to 1...
40 22:35:37 Initialized empty Git repository in /build/internal/gitlab-templates/.git/
41 22:35:37 Created fresh repository.
42 22:35:37 Checking out 7f6b32cc as detached HEAD (ref is refs/merge-requests/640/merge)...
43 22:35:37
44 22:35:37 Skipping Git submodules setup
45 22:35:37
46 22:35:37 section_end:1778106937:get_sources
47 22:35:37 +section_start:1778106937:step_script
48 22:35:37 +Executing "step_script" stage of the job script
49 22:35:38 section_start:1778106937:section_pre_build_script_0[hide_duration=true,collapsed=true] $ function cleanup {
50 22:35:38 rv=$?
51 22:35:38 if [ $rv -ne 0 ]; then
52 22:35:38 echo ""
53 22:35:38 echo " Failure Cause Analysis might help, please open this link:"
54 22:35:38 echo " https://scout.scandit.io/analysis/projects/${CI_PROJECT_ID}/jobs/${CI_JOB_ID}"
55 22:35:38 echo ""
56 22:35:38 fi
57 22:35:38 echo ""
58 22:35:38 echo "Scout Analysis: https://scout.scandit.io/analysis/projects/${CI_PROJECT_ID}/jobs/${CI_JOB_ID}"
59 22:35:38 echo ""
60 22:35:38 echo ""
61 22:35:38 echo "Grafana Pod-View: https://grafana.scandit.com/d/k8s_views_pods/kubernetes-views-pods?orgId=1&refresh=1m&var-datasource=${GRAFANA_DATASOURCE}&var-host=${SC_K8S_NODE_NAME}&var-namespace=${SC_K8S_NAMESPACE}&var-pod=${HOSTNAME}&var-resolution=15&from=${__start_time}000&to=${EPOCHSECONDS}000"
62 22:35:38 echo "Grafana Node-View: https://grafana.scandit.com/d/k8s_views_nodes/kubernetes-views-nodes?orgId=1&refresh=1m&var-datasource=${GRAFANA_DATASOURCE}&var-node=${SC_K8S_NODE_NAME}&var-resolution=15s&from=${__start_time}000&to=${EPOCHSECONDS}000"
63 22:35:38 echo "Loki Logs: https://grafana.scandit.com/a/grafana-lokiexplore-app/explore/log_group/gitlab-runner/logs?var-ds=${LOKI_DATASOURCE}&var-filters=log_group|=|gitlab-runner&var-filters=source|=|${LOKI_LOGSOURCE}&var-filters=namespace|=|${SC_K8S_NAMESPACE}&var-filters=CI_PROJECT_ID|=|${CI_PROJECT_ID}&var-filters=CI_PIPELINE_ID|=|${CI_PIPELINE_ID}&var-filters=CI_JOB_ID|=|${CI_JOB_ID}&sortOrder=Ascending&from=${__start_time}000&to=${EPOCHSECONDS}000"
64 22:35:38 echo "Lilibet Statistics: https://lilibet.scandit.io/dashboard/204-job-drill-down?date_range=$(date -d '-7 days' +%Y-%m-%d)~$(date -d '+7 days' +%Y-%m-%d)&job_name=${CI_JOB_NAME}&project=${CI_PROJECT_PATH}"
65 22:35:38 echo ""
66 22:35:38 exit $rv
67 22:35:38 }
68 22:35:38 trap cleanup EXIT
69 22:35:38 echo "INFO: This is the CI job pre_build_script"
70 22:35:38 echo "INFO: It's defined in the backend/infra/aws repo."
71 22:35:38 echo "INFO: These additional Scandit variables are available to you:"
72 22:35:38 echo " SC_K8S_NODE_NAME: $SC_K8S_NODE_NAME"
73 22:35:38 echo " SC_K8S_IMAGE_ID: $SC_K8S_IMAGE_ID"
74 22:35:38 echo " SC_K8S_KYVERNO_PATCHES: |"
75 22:35:38 echo "$SC_K8S_KYVERNO_PATCHES" | sed 's/^/ /'
76 22:35:38 echo "cpu (r/l): ${SC_K8S_REQUESTS_CPU}/${SC_K8S_LIMITS_CPU}"
77 22:35:38 if command -v numfmt >/dev/null 2>&1; then
78 22:35:38 echo "memory (r/l): $(numfmt --to=iec --suffix=B $SC_K8S_REQUESTS_MEMORY)/$(numfmt --to=iec --suffix=B $SC_K8S_LIMITS_MEMORY)"
79 22:35:38 else
80 22:35:38 echo "memory (r/l): ${SC_K8S_REQUESTS_MEMORY}/${SC_K8S_LIMITS_MEMORY}"
81 22:35:38 fi
82 22:35:38 __start_time=${EPOCHSECONDS}
83 22:35:38 echo ""
84 22:35:38 echo "Grafana Pod-View: https://grafana.scandit.com/d/k8s_views_pods/kubernetes-views-pods?orgId=1&refresh=1m&var-datasource=${GRAFANA_DATASOURCE}&var-host=${SC_K8S_NODE_NAME}&var-namespace=${SC_K8S_NAMESPACE}&var-pod=${HOSTNAME}&var-resolution=15&from=${__start_time}000&to=now"
85 22:35:38 echo "Grafana Node-View: https://grafana.scandit.com/d/k8s_views_nodes/kubernetes-views-nodes?orgId=1&refresh=1m&var-datasource=${GRAFANA_DATASOURCE}&var-node=${SC_K8S_NODE_NAME}&var-resolution=15s&from=${__start_time}000&to=now"
86 22:35:38 echo "Loki Logs: https://grafana.scandit.com/a/grafana-lokiexplore-app/explore/log_group/gitlab-runner/logs?var-ds=${LOKI_DATASOURCE}&var-filters=log_group|=|gitlab-runner&var-filters=source|=|${LOKI_LOGSOURCE}&var-filters=namespace|=|${SC_K8S_NAMESPACE}&var-filters=CI_PROJECT_ID|=|${CI_PROJECT_ID}&var-filters=CI_PIPELINE_ID|=|${CI_PIPELINE_ID}&var-filters=CI_JOB_ID|=|${CI_JOB_ID}&sortOrder=Ascending&from=${__start_time}000&to=now"
87 22:35:38 echo "Lilibet Statistics: https://lilibet.scandit.io/dashboard/204-job-drill-down?date_range=$(date -d '-7 days' +%Y-%m-%d)~$(date -d '+7 days' +%Y-%m-%d)&job_name=${CI_JOB_NAME}&project=${CI_PROJECT_PATH}"
88 22:35:38 echo ""
89 22:35:38 echo "Setting up credentials for Gitlab Python registries"
90 22:35:38 mkdir -p ~
91 22:35:38 echo "machine gitlab.scandit.com" > ~/.netrc
92 22:35:38 echo "login gitlab-ci-token" >> ~/.netrc
93 22:35:38 echo "password ${CI_JOB_TOKEN}" >> ~/.netrc
94 22:35:38 chmod 600 ~/.netrc
95 22:35:38 if command -v git &> /dev/null && [ "$(id -u)" -ne 0 ]; then
96 22:35:38 git config --global --add safe.directory $CI_PROJECT_DIR
97 22:35:38 fi
98 22:35:38 # Sonarqube server is running on the same cluster. Use internal address
99 22:35:38 export SONAR_HOST_URL="http://sonarqube.sonarqube.svc.cluster.local:9000"
100 22:35:38 section_end:1778106937:section_pre_build_script_0
101 22:35:38 INFO: This is the CI job pre_build_script
102 22:35:38 INFO: It's defined in the backend/infra/aws repo.
103 22:35:38 INFO: These additional Scandit variables are available to you:
104 22:35:38 SC_K8S_NODE_NAME: ip-10-0-24-152.eu-central-1.compute.internal
105 22:35:38 SC_K8S_IMAGE_ID:
106 22:35:38 SC_K8S_KYVERNO_PATCHES: |
107 22:35:38
108 22:35:38 cpu (r/l): 2/4
109 22:35:38 memory (r/l): 4000000000/17179869184
110 22:35:38
111 22:35:38 Grafana Pod-View: https://grafana.scandit.com/d/k8s_views_pods/kubernetes-views-pods?orgId=1&refresh=1m&var-datasource=lu1rmx27z&var-host=ip-10-0-24-152.eu-central-1.compute.internal&var-namespace=gitlab-runner&var-pod=runner-wrxjpbsjx-project-621-concurrent-0-urg420fo&var-resolution=15&from=1778106937000&to=now
112 22:35:38 Grafana Node-View: https://grafana.scandit.com/d/k8s_views_nodes/kubernetes-views-nodes?orgId=1&refresh=1m&var-datasource=lu1rmx27z&var-node=ip-10-0-24-152.eu-central-1.compute.internal&var-resolution=15s&from=1778106937000&to=now
113 22:35:38 Loki Logs: https://grafana.scandit.com/a/grafana-lokiexplore-app/explore/log_group/gitlab-runner/logs?var-ds=nVsAo7UVk&var-filters=log_group|=|gitlab-runner&var-filters=source|=|k8s-ci.aws.scandit.io&var-filters=namespace|=|gitlab-runner&var-filters=CI_PROJECT_ID|=|621&var-filters=CI_PIPELINE_ID|=|1582483&var-filters=CI_JOB_ID|=|54539144&sortOrder=Ascending&from=1778106937000&to=now
114 22:35:38 date: invalid date '-7 days'
115 22:35:38 date: invalid date '+7 days'
116 22:35:38 Lilibet Statistics: https://lilibet.scandit.io/dashboard/204-job-drill-down?date_range=~&job_name=build-python3-image-with-context&project=internal/gitlab-templates
117 22:35:38
118 22:35:38 Setting up credentials for Gitlab Python registries
119 22:35:38 $ mkdir -p arbitrary_path
120 22:35:38 $ mv Dockerfile.python-3 arbitrary_path
121 22:35:38 $ mv requirements.txt arbitrary_path
122 22:35:38 $ mv .python-version arbitrary_path
123 22:35:38 $ mv .pip-version arbitrary_path
124 22:35:38 $ echo $DOCKER_CONFIG_JSON > /kaniko/.docker/config.json
125 22:35:38 $ mv /root/.netrc /kaniko/.netrc
126 22:35:38 section_start:1778106937:section_script_step_7[hide_duration=true,collapsed=true] $ function copy_files() {
127 22:35:38 local src="$1"
128 22:35:38 local trg="$2"
129 22:35:38 for f in $src; do
130 22:35:38 t="$trg/`dirname $f`"
131 22:35:38 mkdir -p $t || true
132 22:35:38 echo "Copy $f"
133 22:35:38 cp -pr $f $trg/$f
134 22:35:38 done
135 22:35:38 }
136 22:35:38 function recursive_hash() {
137 22:35:38 local dir="$1"
138 22:35:38 find "$dir" -exec stat -c '%F|%a|%u:%g|%n' {} + -type f -exec sha256sum {} + | sort | sha256sum | cut -d ' ' -f1
139 22:35:38 }
140 22:35:38 function remote_docker_digest() {
141 22:35:38 local images="$1"
142 22:35:38 echo $images | xargs -n 1 crane digest
143 22:35:38 }
144 22:35:38 function remote_image_exists() {
145 22:35:38 local image="$1"
146 22:35:38 crane manifest $image > /dev/null 2>&1
147 22:35:38 }
148 22:35:38 function remote_images_are_identical() {
149 22:35:38 local imageA="$1"
150 22:35:38 local imageB="$2"
151 22:35:38 if [[ $(remote_docker_digest "$imageA") == $(remote_docker_digest "$imageB") ]]; then
152 22:35:38 return 0
153 22:35:38 else
154 22:35:38 return 1
155 22:35:38 fi
156 22:35:38 }
157 22:35:38 function copy_image() {
158 22:35:38 local image="$1"
159 22:35:38 local remotes="$2"
160 22:35:38 local backup_ext="$3"
161 22:35:38 echo "$image"
162 22:35:38 local source_digest=$(remote_docker_digest $image)
163 22:35:38 local target_digest
164 22:35:38 for registry in $remotes; do
165 22:35:38 if target_digest=$(remote_docker_digest $registry); then
166 22:35:38 if [ "$target_digest" != "$source_digest" ]; then
167 22:35:38 echo "image outdated, overwriting with newest version"
168 22:35:38 crane copy $image $registry
169 22:35:38 crane copy $image ${registry}${backup_ext}
170 22:35:38 fi
171 22:35:38 else
172 22:35:38 echo "image does not exist, writing newest version"
173 22:35:38 crane copy $image $registry
174 22:35:38 crane copy $image ${registry}${backup_ext}
175 22:35:38 fi
176 22:35:38 done
177 22:35:38 }
178 22:35:38 section_end:1778106937:section_script_step_7
179 22:35:38 section_start:1778106937:section_script_step_8[hide_duration=true,collapsed=true] $ if [ "$CONTAINER_SUBDIR" != "" ]; then
180 22:35:38 echo "Entering subpath $CONTAINER_SUBDIR"
181 22:35:38 cd $CONTAINER_SUBDIR
182 22:35:38 fi
183 22:35:38 section_end:1778106937:section_script_step_8
184 22:35:38 Entering subpath arbitrary_path
185 22:35:38 $ copy_files "$CONTAINER_IMPLICIT_REQUIREMENTS $CONTAINER_REQUIREMENTS" "$CONTAINER_CONTEXT_PATH"
186 22:35:38 Copy Dockerfile.python-3
187 22:35:38 Copy .pip-version
188 22:35:38 Copy .python-version
189 22:35:38 Copy requirements.txt
190 22:35:38 $ echo "$CONTAINER_BUILD_ENVIRONMENT" > $CONTAINER_CONTEXT_PATH/.docker-build-env
191 22:35:38 $ docker_checksum=$(recursive_hash $CONTAINER_CONTEXT_PATH)
192 22:35:38 section_start:1778106937:section_script_step_12[hide_duration=true,collapsed=true] $ if [ "$CONTAINER_IMAGE_NAME" == "" ]; then
193 22:35:38 final_image_name=${CONTAINER_IMAGE_URL}
194 22:35:38 else
195 22:35:38 final_image_name=${CONTAINER_IMAGE_URL}/${CONTAINER_IMAGE_NAME}
196 22:35:38 fi
197 22:35:38 section_end:1778106937:section_script_step_12
198 22:35:38 $ final_image_url=${final_image_name}:${docker_checksum}
199 22:35:38 section_start:1778106937:section_script_step_14[hide_duration=true,collapsed=true] $ if [ "${PIPELINE_IMAGE_REFS}" == "1" ]; then
200 22:35:38 echo $CONTAINER_IMAGE_VARIABLE=${final_image_url}-P${CI_PROJECT_ID}-${CI_PIPELINE_ID} > $CI_PROJECT_DIR/docker_image_build.env
201 22:35:38 else
202 22:35:38 echo $CONTAINER_IMAGE_VARIABLE=$final_image_url > $CI_PROJECT_DIR/docker_image_build.env
203 22:35:38 fi
204 22:35:38 section_end:1778106937:section_script_step_14
205 22:35:38 $ echo ${CONTAINER_IMAGE_VARIABLE}_HASH=$docker_checksum >> $CI_PROJECT_DIR/docker_image_build.env
206 22:35:38 section_start:1778106937:section_script_step_16[hide_duration=true,collapsed=true] $ if [ "${FORCE_BUILD}" != "true" ] || command -v crane &> /dev/null; then
207 22:35:38 echo $REGISTRY_PASSWORD | crane auth login $REGISTRY -u $REGISTRY_USER --password-stdin
208 22:35:38 fi
209 22:35:38 section_end:1778106937:section_script_step_16
210 22:35:38
211 22:35:38 WARNING! Your credentials are stored unencrypted in '/kaniko/.docker/config.json'.
212 22:35:38 Configure a credential helper to remove this warning. See
213 22:35:38 https://docs.docker.com/go/credential-store/
214 22:35:38
215 22:35:38 2026/05/06 22:35:37 logged in via /kaniko/.docker/config.json
216 22:35:38 section_start:1778106937:section_script_step_17[hide_duration=true,collapsed=true] $ if [ "${FORCE_BUILD}" != "true" ] && remote_image_exists "$final_image_url"; then
217 22:35:38 echo "Image already exists, skip the build."
218 22:35:38 echo "$final_image_url"
219 22:35:38 if [[ "$CI_COMMIT_BRANCH" == "$CI_DEFAULT_BRANCH" ]]; then
220 22:35:38 _EXT=""
221 22:35:38 _BACKUP_EXT="-CI${CI_JOB_ID}-$(date '+%Y%m%d')"
222 22:35:38 elif [[ -n "$CI_MERGE_REQUEST_ID" ]]; then
223 22:35:38 _EXT="-MR${CI_MERGE_REQUEST_IID}"
224 22:35:38 _BACKUP_EXT=""
225 22:35:38 elif [[ "$CI_COMMIT_REF_PROTECTED" == "true" ]]; then
226 22:35:38 _EXT="-${CI_COMMIT_REF_SLUG}"
227 22:35:38 _BACKUP_EXT="-CI${CI_JOB_ID}-$(date '+%Y%m%d')"
228 22:35:38 fi
229 22:35:38 for _TAG in $CONTAINER_IMAGE_TAG; do
230 22:35:38 echo "Copying ${final_image_url} to ${final_image_name}:${_TAG}${_EXT}"
231 22:35:38 copy_image "${final_image_url}" "${final_image_name}:${_TAG}${_EXT}" "${_BACKUP_EXT}"
232 22:35:38 done
233 22:35:38 if [ "${PIPELINE_IMAGE_REFS}" == "1" ]; then
234 22:35:38 _EXT="-P${CI_PROJECT_ID}-${CI_PIPELINE_ID}"
235 22:35:38 echo "Copying ${final_image_url} to ${final_image_url}${_EXT}"
236 22:35:38 copy_image "${final_image_url}" "${final_image_url}${_EXT}"
237 22:35:38 for _TAG in $CONTAINER_IMAGE_TAG; do
238 22:35:38 echo "Copying ${final_image_url} to ${final_image_name}:${_TAG}${_EXT}"
239 22:35:38 copy_image "${final_image_url}" "${final_image_name}:${_TAG}${_EXT}"
240 22:35:38 done
241 22:35:38 fi
242 22:35:38 exit 0
243 22:35:38 fi
244 22:35:38 section_end:1778106937:section_script_step_17
245 22:35:38 $ DESTINATIONS="--destination=$final_image_url"
246 22:35:38 section_start:1778106937:section_script_step_19[hide_duration=true,collapsed=true] $ if [[ "$CI_COMMIT_BRANCH" == "$CI_DEFAULT_BRANCH" ]]; then
247 22:35:38 _EXT=""
248 22:35:38 TIMESTAMP_TAGS=$CONTAINER_IMAGE_TAG
249 22:35:38 elif [[ -n "$CI_MERGE_REQUEST_ID" ]]; then
250 22:35:38 _EXT="-MR${CI_MERGE_REQUEST_IID}"
251 22:35:38 TIMESTAMP_TAGS=""
252 22:35:38 elif [[ "$CI_COMMIT_REF_PROTECTED" == "true" ]]; then
253 22:35:38 _EXT="-${CI_COMMIT_REF_SLUG}"
254 22:35:38 TIMESTAMP_TAGS=$CONTAINER_IMAGE_TAG
255 22:35:38 fi
256 22:35:38 section_end:1778106937:section_script_step_19
257 22:35:38 section_start:1778106937:section_script_step_20[hide_duration=true,collapsed=true] $ for _TAG in $CONTAINER_IMAGE_TAG; do
258 22:35:38 DESTINATIONS="${DESTINATIONS} --destination=${final_image_name}:${_TAG}${_EXT}"
259 22:35:38 done
260 22:35:38 section_end:1778106937:section_script_step_20
261 22:35:38 section_start:1778106937:section_script_step_21[hide_duration=true,collapsed=true] $ if [ "${PIPELINE_IMAGE_REFS}" == "1" ]; then
262 22:35:38 _EXT="-P${CI_PROJECT_ID}-${CI_PIPELINE_ID}"
263 22:35:38 DESTINATIONS="${DESTINATIONS} --destination=${final_image_url}${_EXT}"
264 22:35:38 for _TAG in $CONTAINER_IMAGE_TAG; do
265 22:35:38 DESTINATIONS="${DESTINATIONS} --destination=${final_image_name}:${_TAG}${_EXT}"
266 22:35:38 done
267 22:35:38 fi
268 22:35:38 section_end:1778106937:section_script_step_21
269 22:35:38 section_start:1778106937:section_script_step_22[hide_duration=true,collapsed=true] $ DATE=$(date '+%Y%m%d')
270 22:35:38 for _TAG in $TIMESTAMP_TAGS; do
271 22:35:38 DESTINATIONS="${DESTINATIONS} --destination=${final_image_name}:${_TAG}${_EXT}-CI${CI_JOB_ID}-${DATE}"
272 22:35:38 done
273 22:35:38 section_end:1778106937:section_script_step_22
274 22:35:38 section_start:1778106937:section_script_step_23[hide_duration=true,collapsed=true] $ if [ -n "${CONTAINER_BUILD_ARGS}" ]; then
275 22:35:38 for _BUILD_ARG in $CONTAINER_BUILD_ARGS; do
276 22:35:38 FINAL_BUILD_ARGS="--build-arg $_BUILD_ARG $FINAL_BUILD_ARGS"
277 22:35:38 done
278 22:35:38 fi
279 22:35:38 section_end:1778106937:section_script_step_23
280 22:35:38 section_start:1778106937:section_script_step_24[hide_duration=true,collapsed=true] $ for _PATH in $CONTAINER_IGNORE_PATHS; do
281 22:35:38 FINAL_IGNORE_PATHS="--ignore-path=$_PATH $FINAL_IGNORE_PATHS"
282 22:35:38 done
283 22:35:38 section_end:1778106937:section_script_step_24
284 22:35:38 section_start:1778106937:section_script_step_25[hide_duration=true,collapsed=true] $ if [ -n "${CONTAINER_PLATFORM}" ]; then
285 22:35:38 KANIKO_PLATFORM="--custom-platform=${CONTAINER_PLATFORM}"
286 22:35:38 fi
287 22:35:38 section_end:1778106937:section_script_step_25
288 22:35:38 $ ANNOTATIONS=""
289 22:35:38 section_start:1778106937:section_script_step_27[hide_duration=true,collapsed=true] $ if [[ -n "$CI_COMMIT_REF_NAME" ]]; then
290 22:35:38 ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY org.opencontainers.image.ref.name=${CI_COMMIT_REF_NAME}"
291 22:35:38 fi
292 22:35:38 section_end:1778106937:section_script_step_27
293 22:35:38 section_start:1778106937:section_script_step_28[hide_duration=true,collapsed=true] $ if [[ -n "$CI_COMMIT_SHA" ]]; then
294 22:35:38 ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY org.opencontainers.image.revision=${CI_COMMIT_SHA}"
295 22:35:38 fi
296 22:35:38 section_end:1778106937:section_script_step_28
297 22:35:38 section_start:1778106937:section_script_step_29[hide_duration=true,collapsed=true] $ if [[ -n "$CI_JOB_URL" ]]; then
298 22:35:38 ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY org.opencontainers.image.url=${CI_JOB_URL}"
299 22:35:38 fi
300 22:35:38 section_end:1778106937:section_script_step_29
301 22:35:38 section_start:1778106937:section_script_step_30[hide_duration=true,collapsed=true] $ if [[ -n "$CI_PIPELINE_ID" ]]; then
302 22:35:38 ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY io.gitlab.ci.pipeline_id=${CI_PIPELINE_ID}"
303 22:35:38 fi
304 22:35:38 section_end:1778106937:section_script_step_30
305 22:35:38 section_start:1778106937:section_script_step_31[hide_duration=true,collapsed=true] $ if [[ -n "$CI_JOB_ID" ]]; then
306 22:35:38 ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY io.gitlab.ci.job_id=${CI_JOB_ID}"
307 22:35:38 fi
308 22:35:38 section_end:1778106937:section_script_step_31
309 22:35:38 section_start:1778106937:section_script_step_32[hide_duration=true,collapsed=true] $ if [[ -n "$CI_JOB_IMAGE" ]]; then
310 22:35:38 ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY io.gitlab.ci.job_image=${CI_JOB_IMAGE}"
311 22:35:38 fi
312 22:35:38 section_end:1778106937:section_script_step_32
313 22:35:38 $ ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY org.opencontainers.image.title=${final_image_name}:$(echo $CONTAINER_IMAGE_TAG | cut -d' ' -f1)"
314 22:35:38 $ ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY org.opencontainers.image.created=$(date -u +%Y-%m-%dT%H:%M:%SZ)"
315 22:35:38 $ ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY org.opencontainers.image.vendor=Scandit"
316 22:35:38 $ ANNOTATIONS="${ANNOTATIONS} $KANIKO_ANNOTATION_KEY io.scandit.ci.hash=${docker_checksum}"
317 22:35:38 section_start:1778106937:section_script_step_37[hide_duration=true,collapsed=true] $ if [ -n "${CONTAINER_TARGET_STAGE}" ]; then
318 22:35:38 KANIKO_TARGET="--target $CONTAINER_TARGET_STAGE"
319 22:35:38 fi
320 22:35:38 section_end:1778106937:section_script_step_37
321 22:35:38 $ set -x
322 22:35:38 + echo '$ /kaniko/executor --context $CONTAINER_CONTEXT_PATH --dockerfile $CONTAINER_DOCKERFILE $DESTINATIONS --cache=true --cache-copy-layers --cache-dir /cache/kaniko --cache-repo $CONTAINER_CACHE_REPO --cache-ttl=$CONTAINER_CACHE_TTL $FINAL_IGNORE_PATHS $KANIKO_TARGET $FINAL_BUILD_ARGS $KANIKO_PLATFORM $ANNOTATIONS $KANIKO_DEFAULT_FLAGS $KANIKO_EXTRA_FLAGS'
323 22:35:38 $ /kaniko/executor --context $CONTAINER_CONTEXT_PATH --dockerfile $CONTAINER_DOCKERFILE $DESTINATIONS --cache=true --cache-copy-layers --cache-dir /cache/kaniko --cache-repo $CONTAINER_CACHE_REPO --cache-ttl=$CONTAINER_CACHE_TTL $FINAL_IGNORE_PATHS $KANIKO_TARGET $FINAL_BUILD_ARGS $KANIKO_PLATFORM $ANNOTATIONS $KANIKO_DEFAULT_FLAGS $KANIKO_EXTRA_FLAGS
324 22:35:38 + /kaniko/executor --context /build/internal/gitlab-templates/context/ --dockerfile Dockerfile.python-3 '--destination=registry.scandit.com/internal/gitlab-templates:97732edaa31c705ad4ba1b763f97c3d99b1b3186a2ffa1dc31568e6af8bb13ee' '--destination=registry.scandit.com/internal/gitlab-templates:latest-MR640' '--cache=true' --cache-copy-layers --cache-dir /cache/kaniko --cache-repo registry.scandit.com/internal/gitlab-templates/cache '--cache-ttl=336h' --annotation 'org.opencontainers.image.ref.name=renovate/docker-digests' --annotation 'org.opencontainers.image.revision=7f6b32cc858f497915cdbf195c3784d827544149' --annotation 'org.opencontainers.image.url=https://gitlab.scandit.com/internal/gitlab-templates/-/jobs/54539144' --annotation 'io.gitlab.ci.pipeline_id=1582483' --annotation 'io.gitlab.ci.job_id=54539144' --annotation 'io.gitlab.ci.job_image=registry.scandit.com/dockerfiles/kaniko:v1.27.3-crane@sha256:72bdc063db14f38a45910d33ccf066ecb088d4833fb2437fef336e49b81fd4ac' --annotation 'org.opencontainers.image.title=registry.scandit.com/internal/gitlab-templates:latest' --annotation 'org.opencontainers.image.created=2026-05-06T22:35:37Z' --annotation 'org.opencontainers.image.vendor=Scandit' --annotation 'io.scandit.ci.hash=97732edaa31c705ad4ba1b763f97c3d99b1b3186a2ffa1dc31568e6af8bb13ee' --preserve-context '--credential-helpers=gitlab' --secret 'id=netrc,src=/kaniko/.netrc' --secret 'id=ci_job_token,env=CI_JOB_TOKEN'
325 22:35:38 INFO[0000] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
326 22:35:38 INFO[0000] Retrieving image manifest python:3.12-bookworm
327 22:35:38 INFO[0000] Retrieving image python:3.12-bookworm from registry index.docker.io
328 22:35:38 INFO[0000] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
329 22:35:39 INFO[0000] Retrieving image manifest python:3.12-bookworm
330 22:35:39 INFO[0000] Returning cached image manifest
331 22:35:39 INFO[0001] Retrieving image manifest python:3.12-bookworm
332 22:35:39 INFO[0001] Returning cached image manifest
333 22:35:39 INFO[0001] Retrieving image manifest python:3.12-bookworm
334 22:35:39 INFO[0001] Returning cached image manifest
335 22:35:39 INFO[0001] Built cross stage deps: map[]
336 22:35:39 INFO[0001] Skipping context snapshot as no-one requires it
337 22:35:39 INFO[0001] Retrieving image manifest python:3.12-bookworm
338 22:35:39 INFO[0001] Returning cached image manifest
339 22:35:39 INFO[0001] Retrieving image manifest python:3.12-bookworm
340 22:35:39 INFO[0001] Returning cached image manifest
341 22:35:39 INFO[0001] Building stage 'python:3.12-bookworm' [idx: '0', base-idx: '-1']
342 22:35:39 INFO[0001] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:4aa82f716f80c2fc0d58cc1f7a315d65fe7859ed520e8f4629aeee5d53138656...
343 22:35:39 INFO[0001] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
344 22:35:39 INFO[0001] Using caching version of cmd: RUN git clone https://github.com/pyenv/pyenv.git $PYENV_ROOT
345 22:35:39 INFO[0001] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:ba0db3758a565d2d2e2422aa1db025dbb40e077874cd6e1e401d3c49f3fcd62c...
346 22:35:39 INFO[0001] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
347 22:35:39 INFO[0001] Using caching version of cmd: RUN cd $PYENV_ROOT && git checkout $PYENV_VER
348 22:35:39 INFO[0001] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:5e779da5602a3411aed0b06bc0e08d3c6686e7e5b74cf75ca6cb8dd28794e2e3...
349 22:35:39 INFO[0001] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
350 22:35:40 INFO[0001] Using caching version of cmd: COPY /.python-version .python-version
351 22:35:40 INFO[0001] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:0b3d4dde0819fcc2180fb45da1885c190c4f446559d871702696eea8b042e275...
352 22:35:40 INFO[0001] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
353 22:35:40 INFO[0001] Using caching version of cmd: RUN eval "$(/root/.pyenv/bin/pyenv init --path)" && pyenv install $(cat .python-version) -s && pyenv global $(cat .python-version)
354 22:35:40 INFO[0001] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:bfc242ecea63c2c15b384e6069df1a9b8b0ad16b4052294800a11fbf1791b1f7...
355 22:35:40 INFO[0001] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
356 22:35:40 INFO[0002] Using caching version of cmd: RUN echo 'eval "$(/root/.pyenv/bin/pyenv init --path)"' >> /root/.profile
357 22:35:40 INFO[0002] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:c1786d0b175d4ddb55286e63435f10707815e05ec84ea21598f1412338ca3bd0...
358 22:35:40 INFO[0002] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
359 22:35:40 INFO[0002] Using caching version of cmd: RUN pyenv version | grep $(cat .python-version)
360 22:35:40 INFO[0002] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:3fea39beb03eec55065a1ea9a20bc9eb37d747ce02dde374ed83c7bdb1dbdd4b...
361 22:35:40 INFO[0002] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
362 22:35:41 INFO[0002] Using caching version of cmd: RUN python3 -m pip install --upgrade pip wheel
363 22:35:41 INFO[0002] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:11e9f70596055c2fa501c03b19174d11ba15e7065cf19919a4870f6bfb5eb570...
364 22:35:41 INFO[0002] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
365 22:35:41 INFO[0002] Using caching version of cmd: COPY /requirements.txt requirements.txt
366 22:35:41 INFO[0002] Checking for cached layer registry.scandit.com/internal/gitlab-templates/cache:1341b5af1710055894c1053022824c20400b076b2a37d3d8dbbab26e7df26e52...
367 22:35:41 INFO[0002] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
368 22:35:41 INFO[0002] Using caching version of cmd: RUN --mount=type=secret,id=netrc,target=/root/.netrc python3 -m pip install -r requirements.txt
369 22:35:41 INFO[0002] Skipping unpacking as no commands require it.
370 22:35:41 INFO[0002] ENV PYENV_VER=v2.3.36
371 22:35:41 INFO[0002] Taking snapshot of files...
372 22:35:41 INFO[0002] ENV PYENV_ROOT /root/.pyenv
373 22:35:41 INFO[0002] Taking snapshot of files...
374 22:35:41 INFO[0002] ENV PATH $PYENV_ROOT/shims:$PYENV_ROOT/bin:$PATH
375 22:35:41 INFO[0002] Taking snapshot of files...
376 22:35:41 INFO[0002] RUN git clone https://github.com/pyenv/pyenv.git $PYENV_ROOT
377 22:35:41 INFO[0002] Found cached layer, extracting to filesystem
378 22:35:42 INFO[0003] RUN cd $PYENV_ROOT && git checkout $PYENV_VER
379 22:35:42 INFO[0003] Found cached layer, extracting to filesystem
380 22:35:42 INFO[0003] COPY /.python-version .python-version
381 22:35:42 INFO[0003] Found cached layer, extracting to filesystem
382 22:35:42 INFO[0004] RUN eval "$(/root/.pyenv/bin/pyenv init --path)" && pyenv install $(cat .python-version) -s && pyenv global $(cat .python-version)
383 22:35:42 INFO[0004] Found cached layer, extracting to filesystem
384 22:35:51 INFO[0013] RUN echo 'eval "$(/root/.pyenv/bin/pyenv init --path)"' >> /root/.profile
385 22:35:51 INFO[0013] Found cached layer, extracting to filesystem
386 22:35:51 INFO[0013] SHELL ["/bin/bash", "-c"]
387 22:35:51 INFO[0013] Taking snapshot of files...
388 22:35:51 INFO[0013] RUN pyenv version | grep $(cat .python-version)
389 22:35:51 INFO[0013] Found cached layer, extracting to filesystem
390 22:35:51 INFO[0013] RUN python3 -m pip install --upgrade pip wheel
391 22:35:51 INFO[0013] Found cached layer, extracting to filesystem
392 22:35:53 INFO[0015] COPY /requirements.txt requirements.txt
393 22:35:53 INFO[0015] Found cached layer, extracting to filesystem
394 22:35:53 INFO[0015] RUN --mount=type=secret,id=netrc,target=/root/.netrc python3 -m pip install -r requirements.txt
395 22:35:53 INFO[0015] Found cached layer, extracting to filesystem
396 22:35:54 INFO[0016] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
397 22:35:54 INFO[0016] Pushing image to registry.scandit.com/internal/gitlab-templates:97732edaa31c705ad4ba1b763f97c3d99b1b3186a2ffa1dc31568e6af8bb13ee
398 22:35:58 INFO[0019] Pushed registry.scandit.com/internal/gitlab-templates@sha256:3b186b853419100dcb06798dc833b9dc0c88d689ae1a19ecbe9bfa485bf43d6e
399 22:35:58 INFO[0019] credential providers by priority: [file:/kaniko/.docker/config.json, gitlab]
400 22:35:58 INFO[0019] Pushing image to registry.scandit.com/internal/gitlab-templates:latest-MR640
401 22:35:59 INFO[0020] Pushed registry.scandit.com/internal/gitlab-templates@sha256:3b186b853419100dcb06798dc833b9dc0c88d689ae1a19ecbe9bfa485bf43d6e
402 22:35:59 + cleanup
403 22:35:59 + rv=0
404 22:35:59 + '[' 0 -ne 0 ]
405 22:35:59 + echo
406 22:35:59
407 22:35:59 + echo 'Scout Analysis: https://scout.scandit.io/analysis/projects/621/jobs/54539144'
408 22:35:59 Scout Analysis: https://scout.scandit.io/analysis/projects/621/jobs/54539144
409 22:35:59 + echo
410 22:35:59
411 22:35:59 + echo
412 22:35:59
413 22:35:59 + echo 'Grafana Pod-View: https://grafana.scandit.com/d/k8s_views_pods/kubernetes-views-pods?orgId=1&refresh=1m&var-datasource=lu1rmx27z&var-host=ip-10-0-24-152.eu-central-1.compute.internal&var-namespace=gitlab-runner&var-pod=runner-wrxjpbsjx-project-621-concurrent-0-urg420fo&var-resolution=15&from=1778106937000&to=1778106958000'
414 22:35:59 Grafana Pod-View: https://grafana.scandit.com/d/k8s_views_pods/kubernetes-views-pods?orgId=1&refresh=1m&var-datasource=lu1rmx27z&var-host=ip-10-0-24-152.eu-central-1.compute.internal&var-namespace=gitlab-runner&var-pod=runner-wrxjpbsjx-project-621-concurrent-0-urg420fo&var-resolution=15&from=1778106937000&to=1778106958000
415 22:35:59 + echo 'Grafana Node-View: https://grafana.scandit.com/d/k8s_views_nodes/kubernetes-views-nodes?orgId=1&refresh=1m&var-datasource=lu1rmx27z&var-node=ip-10-0-24-152.eu-central-1.compute.internal&var-resolution=15s&from=1778106937000&to=1778106958000'
416 22:35:59 Grafana Node-View: https://grafana.scandit.com/d/k8s_views_nodes/kubernetes-views-nodes?orgId=1&refresh=1m&var-datasource=lu1rmx27z&var-node=ip-10-0-24-152.eu-central-1.compute.internal&var-resolution=15s&from=1778106937000&to=1778106958000
417 22:35:59 + echo 'Loki Logs: https://grafana.scandit.com/a/grafana-lokiexplore-app/explore/log_group/gitlab-runner/logs?var-ds=nVsAo7UVk&var-filters=log_group|=|gitlab-runner&var-filters=source|=|k8s-ci.aws.scandit.io&var-filters=namespace|=|gitlab-runner&var-filters=CI_PROJECT_ID|=|621&var-filters=CI_PIPELINE_ID|=|1582483&var-filters=CI_JOB_ID|=|54539144&sortOrder=Ascending&from=1778106937000&to=1778106958000'
418 22:35:59 Loki Logs: https://grafana.scandit.com/a/grafana-lokiexplore-app/explore/log_group/gitlab-runner/logs?var-ds=nVsAo7UVk&var-filters=log_group|=|gitlab-runner&var-filters=source|=|k8s-ci.aws.scandit.io&var-filters=namespace|=|gitlab-runner&var-filters=CI_PROJECT_ID|=|621&var-filters=CI_PIPELINE_ID|=|1582483&var-filters=CI_JOB_ID|=|54539144&sortOrder=Ascending&from=1778106937000&to=1778106958000
419 22:35:59 + date -d '-7 days' '+%Y-%m-%d'
420 22:35:59 date: invalid date '-7 days'
421 22:35:59 + date -d '+7 days' '+%Y-%m-%d'
422 22:35:59 date: invalid date '+7 days'
423 22:35:59 + echo 'Lilibet Statistics: https://lilibet.scandit.io/dashboard/204-job-drill-down?date_range=~&job_name=build-python3-image-with-context&project=internal/gitlab-templates'
424 22:35:59 Lilibet Statistics: https://lilibet.scandit.io/dashboard/204-job-drill-down?date_range=~&job_name=build-python3-image-with-context&project=internal/gitlab-templates
425 22:35:59 + echo
426 22:35:59
427 22:35:59 + exit 0
428 22:35:59
429 22:35:59 section_end:1778106959:step_script
430 22:35:59 +section_start:1778106959:upload_artifacts_on_success
431 22:35:59 +Uploading artifacts for successful job
432 22:35:59 Uploading artifacts...
433 22:35:59 docker_image_build.env: found 1 matching artifact files and directories
434 22:36:00 Uploading artifacts as "dotenv" to coordinator... 201 Created correlation_id=01KQZPY1K7CYR6JQ37GBMEF3FV id=54539144 responseStatus=201 Created token=64_hhvyCb
435 22:36:00
436 22:36:00 section_end:1778106960:upload_artifacts_on_success
437 22:36:00 +section_start:1778106960:cleanup_file_variables
438 22:36:00 +Cleaning up project directory and file based variables
439 22:36:00
440 22:36:00 section_end:1778106960:cleanup_file_variables
441 22:36:00 +
442 22:36:00 Job succeeded
443