s3: smbd: Move check_fsp_open() and check_fsp() to smb1_reply.c
[Samba.git] / .gitlab-ci-main.yml
blob8bc33ecfc4d4b34c53ca846320aff23c8b78f5c6
1 # see https://docs.gitlab.com/ce/ci/yaml/README.html for all available options
3 # Stages explained
5 # images: Build the images with the bootstrap script
6 # build_first: Build a few things first to find silly errors (fast job)
7 #              (don't pay for 35 machines until something compiles)
8 # build: The main parallel job
9 #              (keep these to 1hour as we are billed per hour)
10 # test_only: Tests using the build from prior stages, these typically
11 #            have an explicit dependency defined to a specific build job,
12 #            which means that start as soon as the build job finished.
13 # test_private: Like test_only, but running on private runners
14 # report: Code coverage reporting
16 stages:
17   - images
18   - build_first
19   - build
20   - test_only
21   - test_private
22   - report
24 variables:
25   # We want to be resilient to runner failures
26   ARTIFACT_DOWNLOAD_ATTEMPTS: "3"
27   EXECUTOR_JOB_SECTION_ATTEMPTS: "3"
28   GET_SOURCES_ATTEMPTS: "3"
29   RESTORE_CACHE_ATTEMPTS: "3"
30   #
31   GIT_STRATEGY: fetch
32   GIT_DEPTH: "3"
33   #
34   # Use GZip by default, it is fast and is good enough.  Other options include --xz
36   SAMBA_TESTBASE_TAR_OPTIONS: -z
38   #
39   # we run autobuild.py inside a samba CI docker image located on gitlab's registry
40   # overwrite this variable if you want use your own image registry.
41   #
42   # Or better ask for access to the shared development repository, see
43   # https://wiki.samba.org/index.php/Samba_CI_on_gitlab#Getting_Access
44   #
45   SAMBA_CI_CONTAINER_REGISTRY: registry.gitlab.com/samba-team/devel/samba
46   #
47   # Set this to the contents of bootstrap/sha1sum.txt
48   # which is generated by bootstrap/template.py --render
49   #
50   SAMBA_CI_CONTAINER_TAG: ae284a5a64fcff65729bf50b5b0cfdba16afc682
51   #
52   # We use the ubuntu1804 image as default as
53   # it matches what we have on sn-devel-184.
54   #
55   SAMBA_CI_CONTAINER_IMAGE: ubuntu1804
56   #
57   # The following images are available
58   # Please see the samba-o3 sections at the end of this file!
59   # We should run that for each available image
60   #
61   SAMBA_CI_CONTAINER_IMAGE_ubuntu1804: ubuntu1804
62   SAMBA_CI_CONTAINER_IMAGE_ubuntu1804_32bit: ubuntu1804-32bit
63   SAMBA_CI_CONTAINER_IMAGE_ubuntu2004: ubuntu2004
64   SAMBA_CI_CONTAINER_IMAGE_debian11: debian11
65   SAMBA_CI_CONTAINER_IMAGE_opensuse154: opensuse154
66   SAMBA_CI_CONTAINER_IMAGE_fedora37: fedora37
67   SAMBA_CI_CONTAINER_IMAGE_f37mit120: f37mit120
68   SAMBA_CI_CONTAINER_IMAGE_centos7: centos7
69   SAMBA_CI_CONTAINER_IMAGE_centos8s: centos8s
71 include:
72   # The image creation details are specified in a separate file
73   # See bootstrap/README.md for details
74   - 'bootstrap/.gitlab-ci.yml'
76 .shared_runner_build_image:
77   extends: .shared_runner_build
78   variables:
79     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE}
80   image: ${SAMBA_CI_CONTAINER_REGISTRY}/samba-ci-${SAMBA_CI_JOB_IMAGE}:${SAMBA_CI_CONTAINER_TAG}
82 .shared_template:
83   extends: .shared_runner_build_image
84   # All Samba jobs are interruptible, this avoids burning CPU when a
85   # newer branch is pushed.
86   interruptible: true
87   timeout: 2h
89   # Otherwise we run twice, once on push and once on MR
90   # https://forum.gitlab.com/t/new-rules-syntax-and-detached-pipelines/37292
91   rules:
92     - if: $CI_MERGE_REQUEST_ID
93       when: never
94     - when: on_success
96   variables:
97     AUTOBUILD_JOB_NAME: $CI_JOB_NAME
98   stage: build
99   cache:
100     key: ccache.${CI_JOB_NAME}.${SAMBA_CI_JOB_IMAGE}.${SAMBA_CI_FLAVOR}
101     paths:
102       - ccache
104   # This is overridden in many cases, but ensures none of the other
105   # main jobs start until and unless this build finishes.  However
106   # this also ensures we do not download artifacts from any build
107   # unless we specifically depend on it, saving bandwidth
109   needs:
110     - job: samba-def-build
111       artifacts: false
113   before_script:
114     - uname -a
115     - lsb_release -a
116     - cat /etc/os-release
117     - lscpu
118     - cat /proc/cpuinfo
119     - mount
120     - df -h
121     - cat /proc/swaps
122     - free -h
123       # ld will fail if coverage enabled, force link ld to ld.bfd
124     - if [ -n "$SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE" ]; then sudo ln -sf $(which ld.bfd) $(which ld); fi
125       # See bootstrap/.gitlab-ci.yml how to generate a new image
126     - echo "SAMBA_CI_CONTAINER_REGISTRY[${SAMBA_CI_CONTAINER_REGISTRY}]"
127     - echo "SAMBA_CI_CONTAINER_TAG[${SAMBA_CI_CONTAINER_TAG}]"
128     - echo "SAMBA_CI_JOB_IMAGE[${SAMBA_CI_JOB_IMAGE}]"
129     - echo "CI_JOB_IMAGE[${CI_JOB_IMAGE}]"
130     - bootstrap/template.py --sha1sum > /tmp/sha1sum-template.txt
131     - diff -u bootstrap/sha1sum.txt /tmp/sha1sum-template.txt
132     - echo "${SAMBA_CI_CONTAINER_TAG}" > /tmp/sha1sum-tag.txt
133     - diff -u bootstrap/sha1sum.txt /tmp/sha1sum-tag.txt
134     - diff -u bootstrap/sha1sum.txt /sha1sum.txt
135     - echo "${CI_COMMIT_SHA} ${CI_COMMIT_TITLE}" > /tmp/commit.txt
136     - export CCACHE_BASEDIR="${PWD}"
137     - export CCACHE_DIR="${PWD}/ccache" && mkdir -pv "$CCACHE_DIR"
138     - export CC="ccache cc"
139     - export CXX="ccache c++"
140     - ccache -z -M 500M
141     - ccache -s
142       # We are already running .gitlab-ci directives from this repo, remove additional checks that break our CI
143     - git config --global --add safe.directory `pwd`
144   after_script:
145     - mount
146     - df -h
147     - cat /proc/swaps
148     - free -h
149     - CCACHE_BASEDIR="${PWD}" CCACHE_DIR="${PWD}/ccache" ccache -s -c
150   artifacts:
151     expire_in: 1 week
152     paths:
153       - "*.stdout"
154       - "*.stderr"
155       - "*.info"
156       - public
157       - system-info.txt
158   retry:
159     max: 2
160     when:
161       - runner_system_failure
162       - stuck_or_timeout_failure
163       - api_failure
164       - runner_unsupported
165       - stale_schedule
166       - archived_failure
167       - scheduler_failure
168       - data_integrity_failure
170   script:
171     # gitlab predefines CI_JOB_NAME for each job. The gitlab job usually matches the
172     # autobuild name, which means we can define a default template that runs most autobuild jobs
173     - script/autobuild.py $AUTOBUILD_JOB_NAME $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE  --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase
175 # Ensure when adding a new job below that you also add it to
176 # the dependencies for 'pages' below for the code coverage page
177 # generation.
179 others:
180   extends: .shared_template
181   script:
182     - script/autobuild.py ldb      $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/ldb
183     - script/autobuild.py pidl     $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/pidl
184     - script/autobuild.py replace  $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/replace
185     - script/autobuild.py talloc   $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/talloc
186     - script/autobuild.py tdb      $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/tdb
187     - script/autobuild.py tevent   $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/tevent
188     - script/autobuild.py samba-xc $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/samba-xc
189     - script/autobuild.py docs-xml $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase/docs-xml
191 .shared_template_build_only:
192   extends: .shared_template
193   timeout: 2h
194   needs:
195   artifacts:
196     expire_in: 1 week
197     paths:
198       - "*.stdout"
199       - "*.stderr"
200       - "*.info"
201       - system-info.txt
202       - samba-testbase.tar
203   script:
204     # gitlab predefines CI_JOB_NAME for each job. The gitlab job usually matches the
205     # autobuild name, which means we can define a default template that runs most autobuild jobs
206     - script/autobuild.py $AUTOBUILD_JOB_NAME $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE  --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase
207     # On success we need to pack everything into an artifacts file
208     # which needs to be in the git checkout.
209     # As tar doesn't handle hardlink of read-only files,
210     # we remember the acls and add write permissions
211     # before creating the archive. The consumer will apply
212     # the acls again.
213     - cp -a /sha1sum.txt /tmp/samba-testbase/image-sha1sum.txt
214     - cp -a /tmp/commit.txt /tmp/samba-testbase/commit.txt
215     - ln -s /tmp/samba-testbase/${AUTOBUILD_JOB_NAME}/ /tmp/samba-testbase/build_subdir_link
216     - pushd /tmp && getfacl -R samba-testbase > samba-testbase.acl.dump && popd
217     - chmod -R +w /tmp/samba-testbase
218     - mv /tmp/samba-testbase.acl.dump /tmp/samba-testbase/
219     - tar $SAMBA_TESTBASE_TAR_OPTIONS -cf samba-testbase.tar /tmp/samba-testbase
220     - ls -la samba-testbase.tar
221     - sha1sum samba-testbase.tar
223 .shared_template_test_only:
224   extends:
225     - .shared_template
226     - .shared_runner_test
227   stage: test_only
228   script:
229     # Print the Kerberos version to check we ended up with the right one
230     # in the runner. We do not have configure output to recognize it
231     # otherwise.
232     - if [ -x "$(command -v krb5-config)" ]; then krb5-config --version; fi
233     # We unpack the artifacts file created by the .shared_template_build_only
234     # run we depend on
235     - ls -la samba-testbase.tar
236     - sha1sum samba-testbase.tar
237     - tar $SAMBA_TESTBASE_TAR_OPTIONS -xf samba-testbase.tar -C /
238     - diff -u /tmp/samba-testbase/image-sha1sum.txt /sha1sum.txt
239     - diff -u /tmp/samba-testbase/commit.txt /tmp/commit.txt
240     - mv /tmp/samba-testbase/samba-testbase.acl.dump /tmp/samba-testbase.acl.dump
241     - pushd /tmp && setfacl --restore=/tmp/samba-testbase.acl.dump && popd
242     - ls -la /tmp/samba-testbase/
243     - ls -la /tmp/samba-testbase/build_subdir_link
244     - ls -la /tmp/samba-testbase/build_subdir_link/
245     - if [ -n "$SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE" ]; then find /tmp/samba-testbase/build_subdir_link/ -type d -printf "'%p'\n" | xargs chmod u+w; fi
246     - ls -la /tmp/samba-testbase/build_subdir_link/
247     # gitlab predefines CI_JOB_NAME for each job. The gitlab job usually matches the
248     # autobuild name, which means we can define a default template that runs most autobuild jobs
249     - script/autobuild.py $AUTOBUILD_JOB_NAME $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE --skip-dependencies --verbose --nocleanup --keeplogs --tail --full-testbase /tmp/samba-testbase
251 samba-def-build:
252   extends: .shared_template_build_only
253   stage: build_first
255 .needs_samba-def-build:
256   extends: .shared_template_test_only
257   needs:
258     - job: samba-def-build
259       artifacts: true
260     - job: samba-shellcheck
262 samba-mit-build:
263   extends: .shared_template_build_only
264   variables:
265     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_fedora37}
266   stage: build_first
268 samba-mit120-build:
269   extends: .shared_template_build_only
270   variables:
271     AUTOBUILD_JOB_NAME: samba-mit-build
272     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_f37mit120}
273   stage: build_first
275 .needs_samba-mit-build:
276   extends: .shared_template_test_only
277   variables:
278     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_fedora37}
279   needs:
280     - job: samba-mit-build
281       artifacts: true
282     - job: samba-shellcheck
284 .needs_samba-mit120-build:
285   extends: .shared_template_test_only
286   variables:
287     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_f37mit120}
288   needs:
289     - job: samba-mit120-build
290       artifacts: true
292 samba-h5l-build:
293   extends: .shared_template_build_only
295 .needs_samba-h5l-build:
296   extends: .shared_template_test_only
297   needs:
298     - job: samba-h5l-build
299       artifacts: true
301 samba-without-smb1-build:
302   extends: .shared_template_build_only
304 .needs_samba-without-smb1-build:
305   extends: .shared_template_test_only
306   needs:
307     - job: samba-without-smb1-build
308       artifacts: true
310 samba-nt4-build:
311   extends: .shared_template_build_only
313 .needs_samba-nt4-build:
314   extends: .shared_template_test_only
315   needs:
316     - job: samba-nt4-build
317       artifacts: true
319 samba-no-opath-build:
320   extends: .shared_template_build_only
322 .needs_samba-no-opath-build:
323   extends: .shared_template_test_only
324   needs:
325     - job: samba-no-opath-build
326       artifacts: true
328 samba:
329   extends: .shared_template
331 samba-mitkrb5:
332   extends: .shared_template
333   variables:
334     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_fedora37}
336 samba-minimal-smbd:
337   extends: .shared_template
339 samba-nopython:
340   extends: .shared_template
342 samba-admem:
343   extends: .needs_samba-def-build
345 samba-ad-dc-2:
346   extends: .needs_samba-def-build
348 samba-ad-dc-3:
349   extends: .needs_samba-def-build
351 samba-ad-dc-4a:
352   extends: .needs_samba-def-build
354 samba-ad-dc-4b:
355   extends: .needs_samba-def-build
357 samba-ad-dc-5:
358   extends: .needs_samba-def-build
360 samba-ad-dc-6:
361   extends: .needs_samba-def-build
363 samba-ad-back1:
364   extends: .needs_samba-def-build
366 samba-ad-back2:
367   extends: .needs_samba-def-build
369 samba-schemaupgrade:
370   extends: .needs_samba-def-build
372 samba-libs:
373   extends: .shared_template
375 samba-fuzz:
376   extends: .shared_template
377   variables:
378     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_ubuntu2004}
380 ctdb:
381   extends: .shared_template
383 samba-ctdb:
384   extends: .shared_template
386 samba-ad-dc-ntvfs:
387   extends: .needs_samba-def-build
389 samba-admem-mit:
390   extends: .needs_samba-mit-build
392 samba-addc-mit-4a:
393   extends: .needs_samba-mit-build
395 samba-addc-mit-4b:
396   extends: .needs_samba-mit-build
398 # This task is run first to ensure we compile before we start the
399 # main run as it is the fastest full compile of Samba.
400 samba-fips:
401   extends: .shared_template
402   variables:
403     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_fedora37}
405 samba-shellcheck:
406   extends: .shared_template
407   needs:
408   variables:
409     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_fedora37}
410   stage: build_first
412 .private_test_only:
413   extends: .private_runner_test
414   stage: test_private
415   rules:
416       # See above, to avoid a duplicate CI on the MR (these rules override the others)
417     - if: $CI_MERGE_REQUEST_ID
418       when: never
420       # These jobs are only run if the gitlab repo has private runners available.
421       # To enable private jobs, you must add the following var and value to
422       # your gitlab repo by navigating to:
423       # settings -> CI/CD -> Environment variables
424     - if: $SUPPORT_PRIVATE_TEST == "yes"
426 .needs_samba-def-build-private:
427   extends:
428     - .needs_samba-def-build
429     - .private_test_only
431 .needs_samba-mit-build-private:
432   extends:
433     - .needs_samba-mit-build
434     - .private_test_only
436 .needs_samba-mit120-build-private:
437   extends:
438     - .needs_samba-mit120-build
439     - .private_test_only
441 .needs_samba-h5l-build-private:
442   extends:
443     - .needs_samba-h5l-build
444     - .private_test_only
446 .needs_samba-without-smb1-build-private:
447   extends:
448     - .needs_samba-without-smb1-build
449     - .private_test_only
451 .needs_samba-nt4-build-private:
452   extends:
453     - .needs_samba-nt4-build
454     - .private_test_only
456 .needs_samba-no-opath-build-private:
457   extends:
458     - .needs_samba-no-opath-build
459     - .private_test_only
461 samba-fileserver:
462   extends: .needs_samba-h5l-build-private
464 samba-fileserver-without-smb1:
465   extends: .needs_samba-without-smb1-build-private
467 # This is a full build without the AD DC so we test the build with MIT
468 # Kerberos from the default system (Ubuntu 18.04 at this stage).
469 # Runtime behaviour checked via the ktest (static ccache and keytab)
470 # environment
471 samba-ktest-mit:
472  extends: .shared_template
474 samba-ad-dc-1:
475   extends: .needs_samba-def-build-private
477 samba-nt4:
478   extends: .needs_samba-nt4-build-private
480 samba-addc-mit-1:
481   extends: .needs_samba-mit-build-private
483 samba-addc-mit120:
484   extends: .needs_samba-mit120-build-private
485   variables:
486     AUTOBUILD_JOB_NAME: samba-addc-mit-1
488 samba-no-opath1:
489   extends: .needs_samba-no-opath-build-private
491 samba-no-opath2:
492   extends: .needs_samba-no-opath-build-private
494 # 'pages' is a special job which can publish artifacts in `public` dir to gitlab pages
495 pages:
496   extends: .shared_runner_build_image
497   stage: report
498   dependencies:  # tell gitlab to download artifacts for these jobs
499     - others
500     - samba
501     - samba-mitkrb5
502     - samba-admem
503     - samba-ad-dc-2
504     - samba-ad-dc-3
505     - samba-ad-dc-4a
506     - samba-ad-dc-4b
507     - samba-ad-dc-5
508     - samba-ad-dc-6
509     - samba-libs
510     - samba-minimal-smbd
511     - samba-nopython
512     - samba-fuzz
513     # - ctdb  # TODO
514     - samba-ctdb
515     - samba-ad-dc-ntvfs
516     - samba-admem-mit
517     - samba-addc-mit-4a
518     - samba-addc-mit-4b
519     - samba-ad-back1
520     - samba-ad-back2
521     - samba-fileserver
522     - samba-fileserver-without-smb1
523     - samba-ad-dc-1
524     - samba-nt4
525     - samba-schemaupgrade
526     - samba-addc-mit-1
527     - samba-fips
528     - samba-no-opath1
529     - samba-no-opath2
530     - ubuntu1804-samba-o3
531   script:
532     - ls -la *.info
533     - ./configure.developer
534     - make -j
535     - ls -la *.info
536     - lcov $(ls *.info | xargs -I{} echo -n "-a {} ") -o all.info
537     - ls -la *.info
538     - genhtml all.info --ignore-errors source --output-directory public --prefix=$(pwd) --title "coverage report for $CI_COMMIT_REF_NAME $CI_COMMIT_SHORT_SHA"
539   artifacts:
540     expire_in: 30 days
541     paths:
542       - public
543   only:
544     variables:
545       - $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE == "--enable-coverage"
547 # Coverity Scan
548 coverity:
549   extends: .shared_runner_build_image
550   variables:
551     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_opensuse154}
552   stage: build
553   script:
554     - wget https://scan.coverity.com/download/linux64 --post-data "token=$COVERITY_SCAN_TOKEN&project=$COVERITY_SCAN_PROJECT_NAME" -O /tmp/coverity_tool.tgz
555     - tar xf /tmp/coverity_tool.tgz
556     - ./configure.developer --with-cluster-support --with-system-mitkrb5 --with-experimental-mit-ad-dc
557     - cov-analysis-linux64-*/bin/cov-build --dir cov-int make -j$(nproc)
558     - tar czf cov-int.tar.gz cov-int
559     - curl
560       --form token=$COVERITY_SCAN_TOKEN
561       --form email=$COVERITY_SCAN_EMAIL
562       --form file=@cov-int.tar.gz
563       --form version="`git describe --tags`"
564       --form description="CI build"
565       https://scan.coverity.com/builds?project=$COVERITY_SCAN_PROJECT_NAME
566   only:
567     refs:
568       - master
569       - schedules
570     variables:
571       - $COVERITY_SCAN_TOKEN != null
572       - $COVERITY_SCAN_PROJECT_NAME != null
573       - $COVERITY_SCAN_EMAIL != null
574   artifacts:
575     expire_in: 1 week
576     when: on_failure
577     paths:
578       - cov-int/*.txt
580 ubuntu1804-samba-32bit:
581   extends: .shared_template
582   variables:
583     AUTOBUILD_JOB_NAME: samba-32bit
584     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_ubuntu1804_32bit}
587 # We build samba-o3 on all supported distributions
590 # This job, which matches the main CI, needs to still do coverage so
591 # we show the coverage on the "none" environment tests
593 # We want --enable-coverage specified here otherwise we will have a
594 # different set of build options on the coverage build and can fail
595 # when -O3 gets combined with --enable-coverage in the scheduled
596 # builds.
598 ubuntu1804-samba-o3:
599   extends: .shared_template
600   variables:
601     AUTOBUILD_JOB_NAME: samba-o3
602     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_ubuntu1804}
603     SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE: "--enable-coverage"
604   rules:
605     # See above, to avoid a duplicate CI on the MR (these rules override the others)
606     - if: $CI_MERGE_REQUEST_ID
607       when: never
608     # do not run o3 builds (which run a lot of VMs) if told not to
609     # (this uses the same variable as autobuild.py)
610     - if: $AUTOBUILD_SKIP_SAMBA_O3 == "1"
611       when: never
613 # All other jobs do not want code coverage.
614 .samba-o3-template:
615   extends: .shared_template
616   variables:
617     AUTOBUILD_JOB_NAME: samba-o3
618   rules:
619     # See above, to avoid a duplicate CI on the MR (these rules override the others)
620     - if: $CI_MERGE_REQUEST_ID
621       when: never
622     # do not run o3 builds (which run a lot of VMs) if told not to
623     # (this uses the same variable as autobuild.py)
624     - if: $AUTOBUILD_SKIP_SAMBA_O3 == "1"
625       when: never
626     # do not run o3 for coverage since they are using different images
627     - if: $SAMBA_CI_AUTOBUILD_ENABLE_COVERAGE == ""
629 ubuntu2004-samba-o3:
630   extends: .samba-o3-template
631   variables:
632     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_ubuntu2004}
634 debian11-samba-o3:
635   extends: .samba-o3-template
636   variables:
637     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_debian11}
639 opensuse154-samba-o3:
640   extends: .samba-o3-template
641   variables:
642     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_opensuse154}
644 centos7-samba-o3:
645   extends: .samba-o3-template
646   variables:
647     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_centos7}
648     # Git on CentOS doesn't support shallow git cloning
649     GIT_DEPTH: ""
650     # We need a newer GnuTLS version on CentOS7
651     PKG_CONFIG_PATH: "/usr/lib64/compat-gnutls37/pkgconfig:/usr/lib64/compat-nettle32/pkgconfig"
653 centos8s-samba-o3:
654   extends: .samba-o3-template
655   variables:
656     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_centos8s}
658 fedora37-samba-o3:
659   extends: .samba-o3-template
660   variables:
661     SAMBA_CI_JOB_IMAGE: ${SAMBA_CI_CONTAINER_IMAGE_fedora37}
664 # Keep the samba-o3 sections at the end ...