2019-03-16 23:54:13 +00:00
|
|
|
def MODULE_GIT_URL="https://github.com/openresty/lua-nginx-module.git"
|
|
|
|
|
|
|
|
pipeline {
|
|
|
|
agent none
|
2019-03-16 23:56:26 +00:00
|
|
|
stages {
|
|
|
|
stage('Build') {
|
|
|
|
parallel {
|
|
|
|
stage("Build on nginx:stable-alpine") {
|
|
|
|
agent {
|
|
|
|
docker {
|
|
|
|
image 'nginx:stable-alpine'
|
|
|
|
label 'linux && docker && amd64'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
steps {
|
|
|
|
sh 'apk add --no-cache curl gnupg1'
|
|
|
|
sh './download-nginx.sh'
|
|
|
|
|
|
|
|
dir('module') {
|
|
|
|
git changelog: false, url: MODULE_GIT_URL
|
|
|
|
}
|
|
|
|
|
|
|
|
/* BUILD DEPENDENCIES */
|
|
|
|
sh 'apk add lua5.1-dev luajit-dev'
|
|
|
|
// FIXME - workaround wrong include path for luajit
|
|
|
|
sh 'echo "#include <luajit-2.1/luajit.h>" > /usr/include/luajit.h'
|
|
|
|
|
|
|
|
sh './build-alpine.sh'
|
|
|
|
archiveArtifacts "*.so,required_packages.txt"
|
|
|
|
}
|
2019-03-16 23:54:13 +00:00
|
|
|
}
|
2019-03-16 23:56:26 +00:00
|
|
|
stage("Build on nginx:mainline-alpine") {
|
|
|
|
agent {
|
|
|
|
docker {
|
|
|
|
image 'nginx:mainline-alpine'
|
|
|
|
label 'linux && docker && amd64'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
steps {
|
|
|
|
sh 'apk add --no-cache curl gnupg1'
|
|
|
|
sh './download-nginx.sh'
|
|
|
|
|
|
|
|
dir('module') {
|
|
|
|
git changelog: false, url: MODULE_GIT_URL
|
|
|
|
}
|
|
|
|
|
|
|
|
/* BUILD DEPENDENCIES */
|
|
|
|
sh 'apk add lua5.1-dev luajit-dev'
|
|
|
|
// FIXME - workaround wrong include path for luajit
|
|
|
|
sh 'echo "#include <luajit-2.1/luajit.h>" > /usr/include/luajit.h'
|
|
|
|
|
|
|
|
sh './build-alpine.sh'
|
|
|
|
archiveArtifacts "*.so,required_packages.txt"
|
|
|
|
}
|
2019-03-16 23:54:13 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|