Commit Graph

20 Commits

Author SHA1 Message Date
Niels de Vos
648c3f7f77 ci: allow everyone to run the "commitlint" job
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-10 13:04:23 +00:00
Niels de Vos
fdb17ace76 ci: make members of the GitHub "ceph" organization admins
Not everyone can restart CI jobs, only members of the Ceph organization
in GitHub. All jibs (except "commitlint") are started automatically, so
there is no functional change.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-10 12:02:13 +00:00
Niels de Vos
65a0e5c40b ci: do not run commitlint for admin user/group
commitlint should not run automatically on PRs, regardless who posted
the PR. Everyone should be able to trigger a run of the job with `/test
commitlint` anyway.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-07 14:15:51 +00:00
Niels de Vos
2e2f69e04a ci: run commitlint when requested, not containeriized-tests
The jobs/commitlint.yaml refered to the containerized-test.groovy
script, not the commitlint.groovy script.

Make sure to run the righ job when requested. Add some comments to make
things a little clearer.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-07 14:15:51 +00:00
Niels de Vos
120bbc66ab ci: add commitlint fallback job
Each PR gets tested by the commitlint app (which is deprecated). On
occasion the app does not pickup the change in a PR, and the only way to
start a retest is to re-push the PR. All tests will then get executed
again, even if only commitlint was needed.

The new commitlint CI job introduces '/retest commitlint' and runs in
the CentOS CI like other Jenkins jobs. However, the job does not start
automatically on each (updated) PR, but needs manual starting with the
'/test commitlint' or '/retest commitlint' comments. The normal way of
running commitlint is with the app (at least for now).

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-07 12:52:05 +00:00
Niels de Vos
020d3eb212 ci: add mini-e2e-helm Jenkins job
The mini-e2e-helm.groovy script is mostly a copy of mini-e2e.groovy that
does the deployment through the e2e.test executable. The new script
installs Helm and deploys Ceph-CSI through that.

Once the e2e tests have successfully finished, the deployment of
Ceph-CSI is removed again.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-05 05:36:49 +00:00
Niels de Vos
0f811e9735 ci: jjb-deploy should have a "deployment" stage
The stage is called "validate" at the moment, this is a copy/paste
mistake from the jjb-validate job.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 15:36:47 +00:00
Niels de Vos
86448395a5 ci: job name should not contain a "/"
The "/" in the name may have a conflict with the existing "mini-e2e" job
name. Rename the new generated jobs to "mini-e2e_k8s-1.x.y", with a "_"
instead of "/".

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 16:58:15 +02:00
Niels de Vos
322698a313 ci: pass ghprbPullId as parameter to jjb-validate job
Currently the jjb-validate job always checks out the ci/centos branch,
not the contents of the PR. This makes testing PRs unreliable.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 16:50:14 +02:00
Niels de Vos
1fb77b0626 ci: correctly indent parameters for mini-e2e job
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 16:50:14 +02:00
Niels de Vos
1de6b0bba2 ci: pass Kubernetes version as parameter to mini-e2e job
Move the mini-e2e job into a template-job and generate two jobs out of
it: mini-e2e/k8s-1.17.8 and mini-e2e/k8s-1.18.5

By passing the k8s_version as variable to the job-template, and placing
it in the parameters for the mini-e2e.groovy script, all hard-coded
occurences of the Kubernetes version can be replaced by the
{k8s_version} placeholder.

See-also: https://jenkins-job-builder.readthedocs.io/en/latest/definition.html#job-template
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 14:12:25 +00:00
Niels de Vos
96dcc08223 ci: use ci/centos/mini-e2e/k8s-1.18 as context for mini-e2e job
Restarting the CI job can now be done with the following comments in a
PR:
- /test all
- /retest all
- /test ci/centos/mini-e2e
- /retest ci/centos/mini-e2e
- /test ci/centos/mini-e2e/k8s-1.18
- /retest ci/centos/mini-e2e/k8s-1.18

This is added as preparation for enabling running the mini-e2e job with
different Kubernetes versions.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 10:13:46 +00:00
Niels de Vos
f5cba3aaa8 ci: add mini-e2e Jenkins job
The new mini-e2e jobs does the following:
 - reserve a bare-metal machine
 - checkout the git repository with the PR
 - build used artifacts (container image and e2e.test executable)
 - deploy k8s and Rook in a minikube VM
 - run the e2e tests

With-contributions-from: Yug <yuggupta27@gmail.com>
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-08-03 08:11:17 +00:00
Niels de Vos
a089d8eaa1 ci: use correct refspec for fetching PRs in jjb-validate job
Also use https, instead of http for the repository.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-29 09:51:16 +00:00
Niels de Vos
06ef71971d ci: re-enable jjb-validate job for PRs
With the jjb/session label on the Pod, tracking the job works again.
Therefor this test can be re-enabled.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-29 09:51:16 +00:00
Niels de Vos
69b16771ae ci: do not automatically run jjb-validate on PRs
The jjb-validate job is not correct, it does not always return the
results of the PR.

Prevent triggering the job automatically, and only have it run when
someone leaves the '/test ci/centos/jjb-validate' comment.

Updates: #1111
Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-28 07:36:06 +00:00
Niels de Vos
d2905081b3 ci: checkout the PR when running jjb-validate
Using the 'git' function in groovy does not allow checking out a
non-branch, so use the 'checkout' function instead.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-27 18:21:59 +02:00
Niels de Vos
8f4a556dcc ci: add properties for jobs/jjb-deploy.yaml
The 'scm' section also needs to be a list. Jenkins Jobs Builder does not
detect this while validating, but it cause an error while updating the
jobs in Jenkins.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-27 16:22:51 +02:00
Niels de Vos
6022807f52 ci: jenkins-jobs builder requires git:name set
In case there is no 'origin', jenkins-jobs fails with an error like:

    jenkins_jobs.errors.JenkinsJobsException: Must specify a url for git remote "origin"

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-27 14:25:51 +02:00
Niels de Vos
650d749d28 ci: move the Jenkins Job Builder .yaml files under jobs/
There is a new .commitlintrc.yml file in the root of the repository.
This causes jenkins-job-builder to complains that the file is not
confirm the Jenkins Job Builder format/specification.

    jenkins_jobs.errors.JenkinsJobsException: The topmost collection in file '/opt/build/.commitlintrc.yml' must be a list, not a <class 'collections.OrderedDict'>

Move all Jenkins Job Builder .yaml files to jobs/ so that all the
Jenkins job configurations are kept together without other files.

Signed-off-by: Niels de Vos <ndevos@redhat.com>
2020-05-27 13:53:43 +02:00