1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00
Commit Graph

63 Commits

Author SHA1 Message Date
Andreas Schneider
f06b40a919 bootstrap: Use quay.io to download fedora images
The docker registry is rate limited now. This often leads to errors, so
use the Red Hat registry.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Sun Jun 26 23:08:03 UTC 2022 on sn-devel-184
2022-06-26 23:08:03 +00:00
Ralph Boehme
b22ddf5ee9 gitlab-ci: Add jq
Pair-Programmed-With: Jule Anger <janger@samba.org>
Signed-off-by: Ralph Boehme <slow@samba.org>
Signed-off-by: Jule Anger <janger@samba.org>

[abartlet@samba.org Regenerated sha1sum after rebase

This commit in aid of future tests for smbstatus JSON output]

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Jun 10 07:51:02 UTC 2022 on sn-devel-184
2022-06-10 07:51:02 +00:00
Joseph Sutton
73f0621a0a bootstrap: Fix [gm]old linker existence check
We used 'test -x $LD_GOLD' to test whether the alternate linker was
available and executable. However, if $LD_GOLD expanded to an empty
string, the 'test' command would be run in single argument mode, see
that '-x' was a non-empty string, and duly return a successful status
code. The result would be a meaningless symlink created, and a
misleading message.

Because 'which' already tests that its argument is executable, the
solution is simply to remove the 'test' command.

We also invert the return code of the 'which' command so that if the
alternate linker is not found, the overall code returned to Docker is
still successful.

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-06-10 06:56:38 +00:00
Joseph Sutton
6b58061d22 bootstrap: Remove duplicate dict key
Commit 86d4836919 added python36-gpg, but
the duplicate key lower down in the same dict meant it never had any
effect. Now it does.

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-06-10 06:56:38 +00:00
Andrew Bartlett
4f7c6ba50b gitlab-ci: Allow --xz compression on our samba-testbase.tar
This may make this faster to upload to our private gitlab server
which is not as close to our runners.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14863

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-06-10 06:56:38 +00:00
Uri Simchoni
e67845a73c ci-images: install diffutils prior to building images
Ensure the podman image used for generating Samba CI images includes
'diff' utility

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Jun  9 23:48:42 UTC 2022 on sn-devel-184
2022-06-09 23:48:42 +00:00
Uri Simchoni
37c6a327ed [ci-images] remove use of sudo in image building smoke test
Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Uri Simchoni <uri@samba.org>
Autobuild-Date(master): Wed May 25 20:50:25 UTC 2022 on sn-devel-184
2022-05-25 20:50:25 +00:00
Uri Simchoni
96da114286 [ci-images] run podman directly instead of docker link
Instead of having a symbolic link from docker to podman,
use podman directly. This is made for better clarity, and
because docker and podman are not 100% intechangeable in this
script.

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2022-05-25 19:54:35 +00:00
Uri Simchoni
4ee29f846f [ci-images] use podman instead of docker
Use podman as image building tool instead of docker. The image-creation
pipeline still runs on docker only (until gitlab-runner supports
podman), but the pipeline image may emply podman instead of docker to
build images.

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2022-05-25 19:54:35 +00:00
Andreas Schneider
91d8bc7ac2 gitlab-ci: Update Fedora to version 36
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed May 18 07:56:52 UTC 2022 on sn-devel-184
2022-05-18 07:56:52 +00:00
Andreas Schneider
f2eb411646 gitlab-ci: Use openSUSE 15.3 for coverity
It provides gcc 10.3 and MIT krb5 1.19. The current coverity version
only supports gcc up to 11.1.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2022-05-18 06:58:35 +00:00
David Mulder
53a5542894 bootstrap: Add python3-requests dependency
Certificate Auto Enrollment will depend on
python3-requests in order to fetch the
root chain.

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-05-13 14:46:29 +00:00
Andrew Bartlett
7244a64478 bootstrap: matplotlib is not a real Samba dep
This came in via the original list of packages used
at Catalyst when building Samba for testing, in particular
related to an example LDB module to trace LDB requests.

There is no testing need for this even in make test.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-05-10 23:05:31 +00:00
Andrew Bartlett
c771d197ee bootstrap: chown the whole cloned repo, not just the subfolders
Modern git versions have started to notice the possible security issue.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-05-10 23:05:31 +00:00
Andrew Bartlett
dd56849008 .gitlab-ci: Work around new git restrictions arising from CVE-2022-24765
It was realised that git would run commands found in a git repo
(eg from configuration).

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2022-05-10 23:05:31 +00:00
David Mulder
8d62b7aca7 ci: Create samba-fileserver-without-smb1 environment
Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
2022-04-07 17:37:30 +00:00
Andreas Schneider
1bde388ba8 gitlab-ci: Drop Debian 10
It should be enough to build on the latest Debian version. We have older
Ubuntu versions already.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-23 11:33:33 +00:00
Andreas Schneider
0b10962d63 gitlab-ci: Update to openSUSE 15.3
This drops openSUSE 15.1 and 15.2 to save some CI resources.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-23 11:33:33 +00:00
Andreas Schneider
4993faea2d gitlab-ci: Drop Fedora 34
It should be enough to run on the latest Fedora version. This should save us
some CI minutes. We have CentOS runners and I would prefer to add CentOS9
Stream.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-23 11:33:33 +00:00
Andreas Schneider
0e81b7965e gitlab-ci: Use Ubuntu 20.04 for Coverity
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-23 11:33:33 +00:00
Andreas Schneider
c886d58b80 gitlab-ci: Remove unused variable for ubuntu1604
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-23 11:33:33 +00:00
Andreas Schneider
d1d47a5544 gitlab-ci: Run krb5 tests also with MIT Kerberos 1.20 (prerelease)
This adds test against MIT Kerberos 1.20 (prerelease) in order to test
Bronze Bit, S4U and RBCD functionality supported only in current MIT Kerberos
git master. We created a Fedora COPR package for MIT KRB5 1.20 (prerelease).

MIT Kerberos 1.20 will be released in autumn 2022. As soon as MIT Kerberos 1.20
will be in a Fedora release, these runners will be removed again.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-04 14:05:31 +00:00
Andreas Schneider
e908bbb1b3 gitlab-ci: Print the krb5 version
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2022-03-04 14:05:31 +00:00
Andreas Schneider
3bc00dfdd6 bootstrap: Install mold linker on Fedora 35
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Tue Feb 15 12:31:43 UTC 2022 on sn-devel-184
2022-02-15 12:31:43 +00:00
Andreas Schneider
d409c23832 bootstrap: If the mold linker is available prefer it over gold
The gold linker will be deprecated soon. However we got a new linker called
mold:

https://github.com/rui314/mold/

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2022-02-15 11:35:31 +00:00
Andreas Schneider
136ec5bc01 bootstrap: Migrate to CentOS8 Stream
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Feb  4 21:11:40 UTC 2022 on sn-devel-184
2022-02-04 21:11:40 +00:00
Andreas Schneider
0c6554aa0d bootstrap: Fix CentOS8 runner
CentOS8 is EOL since December 31, 2021. The packages move to vault.centos.org.
We should migrate to CentOS8 Stream soon.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Thu Feb  3 14:31:01 UTC 2022 on sn-devel-184
2022-02-03 14:31:01 +00:00
Stefan Metzmacher
d0aa04e8c1 bootstrap: use compat-gnutls37-devel for centos7
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2022-01-21 20:46:35 +00:00
Andreas Schneider
ce4d134da7 gitlab-ci: Use Fedora 34 for Coverity Scan
The Coverity Scan tools are not updated very often and miss support for the
latest gcc build. Lets use Fedora 34 for that and stay behind a bit.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed Jan 19 10:49:18 UTC 2022 on sn-devel-184
2022-01-19 10:49:18 +00:00
Andreas Schneider
80115f9be1 gitlab-ci: Add Fedora 35 and drop Fedora 33
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Nov  5 12:36:55 UTC 2021 on sn-devel-184
2021-11-05 12:36:55 +00:00
Martin Schwenke
04f188f4d5 bootstrap: Debian 11 has liburing-dev
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14872

Signed-off-by: Martin Schwenke <martin@meltin.net>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue Oct 19 09:14:10 UTC 2021 on sn-devel-184
2021-10-19 09:14:10 +00:00
Martin Schwenke
c901adaa0d bootstrap: Add Debian 11
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14872

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Mon Oct 18 17:19:17 UTC 2021 on sn-devel-184
2021-10-18 17:19:17 +00:00
Andrew Bartlett
ce3d33f4c1 gitlab-ci: Do not download artifacts of unrelated builds
This needs: is overridden in many cases, but ensures none of the other
main jobs start until this build finishes.  However this also
ensures we do not download artifacts from any build unless we
specifically depend on it, saving bandwidth

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14863

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2021-10-15 09:09:36 +00:00
Andrew Bartlett
1cdf8493b5 gitlab-ci: Do not retry for job_execution_timeout
If we timeout, we should just stop at 2 hours, not waste 6 hours (3 x 2 hours).

This is for when the job runs long for any reason, currently the
reasons for a timeout are not transient, we need to either change
the timeout or fix the system.  Likewise if the tests get into a loop
or deadlock we want to see that as a failure.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14863

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2021-10-15 09:09:36 +00:00
Andrew Bartlett
8ab0238abd .gitlab-ci: Avoid duplicate CI on all merge requests
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14861

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Oct 14 01:21:11 UTC 2021 on sn-devel-184
2021-10-14 01:21:11 +00:00
Andrew Bartlett
bcc22d0056 .gitlab-ci.yml: Restore building most of our jobs
We are changing the primary build jobs to use "when"
not "only".  These a similar and related GitLab syntax
tools to control when jobs are run.

With 'when' now in use it must be specified on all jobs
that inherit from each other via:

.extends .shared_template

"only" can be left however for the pages and coverity as
these use:

.extends .shared_runner_build_image

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14861

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
2021-10-14 00:31:35 +00:00
Joseph Sutton
dd178d9725 .gitlab-ci: Increase build timeout
While the build will not take > 1hr, uploading the artifacts
needed to pass the build objects to the next stage can take
some time due to the distance between the runners and the
private CI server.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14861

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Ralph Boehme <slow@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Oct 13 12:00:03 UTC 2021 on sn-devel-184
2021-10-13 12:00:03 +00:00
Andrew Bartlett
7857e1249b .gitlab-ci.yml: Honour AUTOBUILD_SKIP_SAMBA_O3 in GitLab CI
GitLab CI resources are expensive and often rationed so
provide a way to test other things without testing an -O3
build also, as this will save 9 jobs.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14861

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
2021-10-13 11:10:44 +00:00
Andrew Bartlett
1305ec3ae6 .gitlab-ci: Allow a 1 hour to build Samba
I have seen cases where the job is pushed to the private runners
(which do not have the ccache) where this takes over 45mins, and
a typical job can be 35 mins so this is too tight.

Triggering the timeout causes a rebuild from scratch, which is
done twice automatically, and is financially costly (we pay
per VM start) and a waste of CPU/energy/etc.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=14844

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Oct  1 19:43:16 UTC 2021 on sn-devel-184
2021-10-01 19:43:16 +00:00
Andrew Bartlett
b0b9663c80 .gitlab-ci: Ignore errors from missing source files in code coverage
This could happen when code coverage is collected from multiple distributions.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2021-10-01 18:58:34 +00:00
Andrew Bartlett
ce2bc74dce bootstrap: Remove last references to Ubuntu 16.04
The Ubuntu 16.04 build went away with
4366c3bb71 as oss-fuzz moves
to Ubuntu 20.04.

We don't do a special build for the oss-fuzz, this restores the
behaviour before e10910f8de and
d048d7e17d where oss-fuzz was only
tested as part of the main build.  (In the case of a failure the
pipeline would fail, preventing a merge, just the same as for
any other failing test).

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>

Autobuild-User(master): Uri Simchoni <uri@samba.org>
Autobuild-Date(master): Tue Sep 14 04:44:44 UTC 2021 on sn-devel-184
2021-09-14 04:44:44 +00:00
Uri Simchoni
4366c3bb71 gitlab-ci: run samba-fuzz autobuild target on Ubuntu 20.04-based image
REF: https://github.com/google/oss-fuzz/issues/6301#issuecomment-911705365

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Thu Sep  9 01:45:09 UTC 2021 on sn-devel-184
2021-09-09 01:45:09 +00:00
Andrew Bartlett
e9c8ac4adb bootstrap: Update to get newer krb5 on Fedora 34
We need the update FEDORA-2021-20b495cb94 (krb5) to
get a fix for CVE-2021-37750 (explicit NULL deref on KDC)
so our CI will pass as we have a test for this.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2021-09-02 13:41:28 +00:00
Andrew Bartlett
649b0741e1 gitlab-ci: Move MIT builds to current Fedora so we can test against a current MIT KDC
Fedora packages current MIT builds pretty fast so we base our
MIT KDC tests there, as this avoids backporting and tests against
the most current code.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2021-08-26 06:16:35 +00:00
Andrew Bartlett
6145c388d2 gitlab-ci/autobuild: Add new build confirming behaviour on older MIT Kerberos
Because the MIT KDC builds are moving to current MIT and out of the default autobuild
this ensures that on our default host, which is closer to what most of our
users operate, Samba still works with Kerberos.

This uses the ktest environment that does not require the KDC to exist
and instead uses a static ccache and keytab.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2021-08-26 06:16:35 +00:00
Andreas Schneider
000f389d09 gitlab: Use shorter names for Samba AD DC env with MIT KRB5
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14779

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Tue Aug  3 20:35:49 UTC 2021 on sn-devel-184
2021-08-03 20:35:49 +00:00
Andreas Schneider
ee9dfff617 bootstrap: Install python3-dateutil instead of python3-iso8601 on RPM distros
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed Jul 21 12:18:30 UTC 2021 on sn-devel-184
2021-07-21 12:18:30 +00:00
Andreas Schneider
e0fa3e359f bootstrap: Install krb5-workstation on Fedora based distros
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Alexander Bokovoy <ab@samba.org>
2021-07-21 06:30:31 +00:00
Andreas Schneider
170d2f85a1 gitlab-ci: Install devel files for tracker-sparql (spotlight backend)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Thu May 20 12:01:06 UTC 2021 on sn-devel-184
2021-05-20 12:01:06 +00:00
Andreas Schneider
ac78b921da bootstrap: Add Fedora 34 CI runner
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri May  7 07:18:02 UTC 2021 on sn-devel-184
2021-05-07 07:18:01 +00:00