gitlab-ci: add .gitlab-ci.yml
authorJoe Guo <joeg@catalyst.net.nz>
Tue, 19 Sep 2017 21:33:27 +0000 (09:33 +1200)
committerRalph Boehme <slow@samba.org>
Tue, 31 Oct 2017 14:32:16 +0000 (15:32 +0100)
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 <joeg@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Tue Oct 31 15:32:16 CET 2017 on sn-devel-144

.gitlab-ci.yml [new file with mode: 0644]

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644 (file)
index 0000000..2ae9eb4
--- /dev/null
@@ -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!"