Files
java-maven-app/Jenkinsfile
2020-12-04 19:32:41 +01:00

32 lines
840 B
Groovy

#!/usr/bin/env groovy
pipeline {
agent any
stages {
stage('build app') {
steps {
script {
echo "building the application..."
}
}
}
stage('build image') {
steps {
script {
echo "building the docker image..."
}
}
}
stage('deploy') {
steps {
script {
echo 'deploying docker image...'
withKubeConfig([credentialsId: 'lke-credentials', serverUrl: 'https://79fa9228-1d11-47ec-870b-33106d53122b.eu-central-2.linodelke.net']) {
sh 'kubectl create deployment nginx-deployment --image=nginx'
}
}
}
}
}
}