2024-09-26 12:34:36 +02:00
|
|
|
pipeline {
|
|
|
|
environment {
|
|
|
|
ORG = "go"
|
|
|
|
APP = "folderwatcher"
|
|
|
|
GIT_REPO_OWNER = "go"
|
|
|
|
GIT_REPO_NAME = "folderwatcher"
|
|
|
|
}
|
|
|
|
|
|
|
|
agent {
|
|
|
|
docker {
|
2024-11-14 12:37:49 +01:00
|
|
|
image 'docker.sportwanninger.de/infrastructure/golang-mingw:1.23.3'
|
2024-09-26 12:34:36 +02:00
|
|
|
args "${dindArgs()}"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
options {
|
|
|
|
buildDiscarder(logRotator(numToKeepStr: '5', artifactNumToKeepStr: '5'))
|
|
|
|
disableConcurrentBuilds()
|
|
|
|
}
|
|
|
|
|
|
|
|
stages {
|
2024-09-26 12:35:15 +02:00
|
|
|
stage('Test') {
|
2024-09-26 12:34:36 +02:00
|
|
|
environment {
|
|
|
|
CGO_ENABLED = "1"
|
|
|
|
GOOS = "linux"
|
|
|
|
CXX = "g++"
|
|
|
|
CC = "gcc"
|
|
|
|
}
|
|
|
|
steps {
|
|
|
|
ansiColor('xterm') {
|
|
|
|
sh "go test ./..."
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2024-09-26 12:35:15 +02:00
|
|
|
stage('Test Win') {
|
2024-09-26 12:34:36 +02:00
|
|
|
environment {
|
|
|
|
CGO_ENABLED = "1"
|
|
|
|
GOOS = "windows"
|
|
|
|
CXX = "x86_64-w64-mingw32-g++"
|
|
|
|
CC = "x86_64-w64-mingw32-gcc"
|
|
|
|
}
|
|
|
|
steps {
|
|
|
|
ansiColor('xterm') {
|
|
|
|
sh "go test -exec wine64 -ldflags \"-extldflags '-static -fstack-protector'\" ./..."
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
post {
|
|
|
|
always {
|
|
|
|
script {
|
|
|
|
sendBuildMessage();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|