mirror of
https://github.com/docker/docker-install.git
synced 2026-11-20 10:03:11 +03:00
Simplifies CI to run through a simple `make test` target that has an underlying `TEST_IMAGE` variable which determines the distribution to run on. Also changes the Jenkinsfile to be declarative since the old one kind of sucked. Also adds a test for version pinning since that's something we rely on a lot. Signed-off-by: Eli Uriegas <eli.uriegas@docker.com>
46 lines
1.3 KiB
Groovy
46 lines
1.3 KiB
Groovy
#!groovy
|
|
|
|
def VERSION="18.09"
|
|
|
|
pipeline {
|
|
agent {
|
|
label "linux&&x86_64"
|
|
}
|
|
|
|
stages {
|
|
stage("shellcheck") {
|
|
steps {
|
|
sh "make shellcheck"
|
|
}
|
|
}
|
|
// Test out that the script will work for distros / version pinning
|
|
stage("Check distributions / version pinning") {
|
|
// NOTE: These can all technically run on the same node since they
|
|
// run in containers
|
|
parallel {
|
|
stage("Ubuntu 18.04") {
|
|
steps {
|
|
sh "TEST_IMAGE=ubuntu:18.04 make test"
|
|
}
|
|
}
|
|
stage("Ubuntu 18.04 / version pinning") {
|
|
steps {
|
|
sh "TEST_IMAGE=ubuntu:18.04 VERSION=${VERSION} make test"
|
|
}
|
|
}
|
|
stage("Centos 7") {
|
|
steps {
|
|
sh "TEST_IMAGE=centos:7 make test"
|
|
}
|
|
}
|
|
stage("Centos 7 / version pinning") {
|
|
steps {
|
|
sh "TEST_IMAGE=centos:7 VERSION=${VERSION} make test"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
// TODO: add release step here to upload to S3
|
|
}
|
|
}
|