From 257a84be9ffb6eca93f3b59286e50968e1e51289 Mon Sep 17 00:00:00 2001 From: Joe Guo Date: Wed, 20 Sep 2017 09:33:27 +1200 Subject: [PATCH 1/2] gitlab-ci: add .gitlab-ci.yml MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add .gitlab-ci.yml file, and define build jobs in groups. Once gitlab-runner set up, builds and tests can be triggered automatically in parallel when push to gitlab. Also, with gitlab-runner autoscale mode, build instances will be created and removed on demand. Signed-off-by: Joe Guo Reviewed-by: Andrew Bartlett Reviewed-by: Ralph Boehme Autobuild-User(master): Ralph Böhme Autobuild-Date(master): Tue Oct 31 15:32:16 CET 2017 on sn-devel-144 (cherry picked from commit 8be4236b323b5f755ff6c0bf0a4a5fb99343c84d) --- .gitlab-ci.yml | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 00000000000..2ae9eb4032d --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,47 @@ +# see https://docs.gitlab.com/ce/ci/yaml/README.html for all available options + +before_script: + - echo "Build starting ..." + +build_samba: + stage: build + tags: + - autobuild + script: + # this one takes about 4 hours to finish + - python script/autobuild.py samba --verbose --tail --testbase /tmp/samba-testbase + +build_samba_others: + stage: build + tags: + - autobuild + script: + - python script/autobuild.py samba-nopython --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py samba-systemkrb5 --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py samba-xc --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py samba-o3 --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py samba-libs --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py samba-static --verbose --tail --testbase /tmp/samba-testbase + +build_ctdb: + stage: build + tags: + - autobuild + script: + - python script/autobuild.py samba-ctdb --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py ctdb --verbose --tail --testbase /tmp/samba-testbase + +build_others: + stage: build + tags: + - autobuild + script: + - python script/autobuild.py ldb --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py pidl --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py replace --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py talloc --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py tdb --verbose --tail --testbase /tmp/samba-testbase + - python script/autobuild.py tevent --verbose --tail --testbase /tmp/samba-testbase + +after_script: + - echo "Build finished!" -- 2.11.0 From 0b132e3bb0f332f8fa472ebd981df2025ef5ee2a Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Tue, 26 Jun 2018 14:59:26 +1200 Subject: [PATCH 2/2] .gitlab-ci.yml: Adapt to current GitLab CI setup Signed-off-by: Andrew Bartlett (cherry picked from commit fb522c1ba0afa1b2298e66dfde42806cae72e5b9) --- .gitlab-ci.yml => .gitlab-ci-private.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) rename .gitlab-ci.yml => .gitlab-ci-private.yml (92%) diff --git a/.gitlab-ci.yml b/.gitlab-ci-private.yml similarity index 92% rename from .gitlab-ci.yml rename to .gitlab-ci-private.yml index 2ae9eb4032d..584b853c25e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci-private.yml @@ -1,12 +1,15 @@ # see https://docs.gitlab.com/ce/ci/yaml/README.html for all available options +image: registry.gitlab.com/samba-team/samba:latest + before_script: - echo "Build starting ..." build_samba: stage: build tags: - - autobuild + - docker + - private script: # this one takes about 4 hours to finish - python script/autobuild.py samba --verbose --tail --testbase /tmp/samba-testbase @@ -14,7 +17,8 @@ build_samba: build_samba_others: stage: build tags: - - autobuild + - docker + - private script: - python script/autobuild.py samba-nopython --verbose --tail --testbase /tmp/samba-testbase - python script/autobuild.py samba-systemkrb5 --verbose --tail --testbase /tmp/samba-testbase @@ -26,7 +30,8 @@ build_samba_others: build_ctdb: stage: build tags: - - autobuild + - docker + - private script: - python script/autobuild.py samba-ctdb --verbose --tail --testbase /tmp/samba-testbase - python script/autobuild.py ctdb --verbose --tail --testbase /tmp/samba-testbase @@ -34,7 +39,8 @@ build_ctdb: build_others: stage: build tags: - - autobuild + - docker + - private script: - python script/autobuild.py ldb --verbose --tail --testbase /tmp/samba-testbase - python script/autobuild.py pidl --verbose --tail --testbase /tmp/samba-testbase -- 2.11.0