[icinga-checkins] icinga.org: icingaweb2-module-director/bugfix/service-set-contraints-13309 : testing: document and enable tests on CentOS 6

git at icinga.org git at icinga.org
Mon Nov 28 16:53:49 CET 2016


Module: icingaweb2-module-director
Branch: bugfix/service-set-contraints-13309
Commit: 7895023498553bf05c8e305d359cccf1054e96a2
URL:    https://git.icinga.org/?p=icingaweb2-module-director.git;a=commit;h=7895023498553bf05c8e305d359cccf1054e96a2

Author: Thomas Gelf <thomas at gelf.net>
Date:   Mon Nov 21 23:10:37 2016 +0100

testing: document and enable tests on CentOS 6

refs #13271

---

 .gitlab-ci.yml    |   15 +++++++++++++++
 doc/93-Testing.md |   25 +++++++++++++++++++++++++
 2 files changed, 40 insertions(+)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index ca11439..e84904a 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -34,6 +34,21 @@ CentOS 7/PostgreSQL:
   script:
   - phpunit
 
+CentOS 6/MySQL:
+  stage: Unit-Tests with DB
+  tags:
+  - centos6
+  - director
+  variables:
+    DIRECTOR_TESTDB: "director_test_${CI_BUILD_ID}_${CI_RUNNER_ID}"
+    DIRECTOR_TESTDB_RES: "Director MySQL TestDB"
+  before_script:
+  - mysql -u root -e "CREATE DATABASE $DIRECTOR_TESTDB"
+  after_script:
+  - mysql -u root -e "DROP DATABASE $DIRECTOR_TESTDB"
+  script:
+  - phpunit
+
 Jessie/MySQL:
   stage: Unit-Tests with DB
   tags:
diff --git a/doc/93-Testing.md b/doc/93-Testing.md
index 31ce2e6..cfa3c7e 100644
--- a/doc/93-Testing.md
+++ b/doc/93-Testing.md
@@ -190,6 +190,31 @@ gitlab-ci-multi-runner register -n \
   --tag-list centos7,director
 ```
 
+#### CentOS 6
+
+```
+yum makecache
+curl -L https://packages.gitlab.com/install/repositories/runner/gitlab-ci-multi-runner/script.rpm.sh | bash
+
+# Package installation
+yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
+yum install -y https://packages.icinga.org/epel/6/release/noarch/icinga-rpm-release-6-1.el6.noarch.rpm
+yum install -y php-Icinga icingaweb2-common phpunit mysql-server gitlab-ci-multi-runner
+
+# Start and enable MySQL
+/etc/init.d/mysqld start
+chkconfig mysqld on
+
+# No PostgeSQL, 8.4 on CentOS 6 is too old
+
+# Register the runner with your Gitlab installation
+gitlab-ci-multi-runner register -n \
+  -r "$REGISTRATION_TOKEN" \
+  --executor shell \
+  -u "$GITLAB_URL" \
+  --tag-list centos6,director
+```
+
 #### Debian Stable (Jessie)
 
 ```sh



More information about the icinga-checkins mailing list