a.
Some checks failed
internetmastercz/test/pipeline/head There was a failure building this commit

This commit is contained in:
2021-10-20 03:18:53 +02:00
parent d7aed0badd
commit 80291dcda0

29
Jenkinsfile vendored
View File

@@ -3,34 +3,35 @@ pipeline {
agent { dockerfile true } agent { dockerfile true }
stages { stages {
environment {
REGISTRY_CREDENTIALS = credentials('registry-credentials-id')
}
stage('Installation') { stage('Installation') {
steps { steps {
echo "start Installation" echo "start Installation"
echo "finish Installation" echo "finish Installation"
} }
} }
stage('Build') { stage('Build') {
steps { steps {
echo "Running ${env.BUILD_ID} on ${env.JENKINS_URL}" echo "Running ${env.BUILD_ID} on ${env.JENKINS_URL}"
echo 'Building..' echo 'Building..'
sh 'docker build -t registry.proxyq.co/cd/website .' sh 'docker build -t registry.proxyq.co/jenkins/website:${env.BUILD_ID} .'
} }
} }
stage('Test') { stage('Test') {
steps { steps {
echo "start Testing" echo "start Testing"
sh 'sleep 5' sh 'sleep 5'
echo "finish Testing" echo "finish Testing"
} }
} }
stage('Deploy') { stage('Deploy') {
steps { steps {
echo "${env.ENV_REGISTRY_URL}" echo "${env.ENV_REGISTRY_URL}"
// docker.withRegistry("https://registry.proxyq.co", 'registry-credentials-id') { sh 'docker login https://registry.proxyq.co -u ${REGISTRY_CREDENTIALS_USR} -p ${REGISTRY_CREDENTIALS_PSW}'
// def customImage = docker.build("registry.proxyq.co/jenkins/website:${env.BUILD_ID}", '.') sh 'docker push registry.proxyq.co/jenkins/website:${env.BUILD_ID}'
// customImage.push() }
// }
}
} }
} }
} }