experimenting with Jenkinsbuild
Some checks failed
arbeitszeitmessung/pipeline/head There was a failure building this commit

This commit is contained in:
2025-08-20 18:55:47 +02:00
parent 33185150cc
commit 3475e6d7c9
7 changed files with 762 additions and 42 deletions

25
Jenkinsfile vendored
View File

@@ -2,14 +2,32 @@ pipeline {
environment {
DOCKER_USERNAME = 'jenkins'
DOCKER_PASSWORD = credentials('gitea_jenkins')
}
SONAR_TOKEN = credentials('sonarcube_token')
}
agent any
stages {
stage ("Building image arbeitszeit-backend"){
stage('Test') {
agent {
docker {
image 'golang:alpine'
}
}
steps {
sh 'cd Backend && go mod download && go mod verify'
sh 'make test'
}
}
stage('SonarCube Analysis') {
steps {
sh 'make scan'
}
}
}
stage('Building image arbeitszeit-backend') {
when {
anyOf{
anyOf {
changeset 'Jenkinsfile'
changeset 'Makefile'
changeset 'Backend/**'
@@ -18,7 +36,6 @@ pipeline {
steps {
sh 'make backend'
}
}
}
}