Some checks failed
internetmastercz/test/pipeline/head There was a failure building this commit
40 lines
1.1 KiB
Groovy
40 lines
1.1 KiB
Groovy
pipeline {
|
|
|
|
agent { dockerfile true }
|
|
|
|
environment {
|
|
REGISTRY_CREDENTIALS = credentials('registry-credentials-id')
|
|
}
|
|
|
|
stages {
|
|
|
|
stage('Installation') {
|
|
steps {
|
|
echo "start Installation"
|
|
echo "finish Installation"
|
|
}
|
|
}
|
|
stage('Build') {
|
|
steps {
|
|
echo "Running ${env.BUILD_ID} on ${env.JENKINS_URL}"
|
|
echo 'Building..'
|
|
sh 'docker build -t registry.proxyq.co/jenkins/website:${env.BUILD_ID} .'
|
|
}
|
|
}
|
|
stage('Test') {
|
|
steps {
|
|
echo "start Testing"
|
|
sh 'sleep 5'
|
|
echo "finish Testing"
|
|
}
|
|
}
|
|
stage('Deploy') {
|
|
steps {
|
|
echo "${env.ENV_REGISTRY_URL}"
|
|
sh 'docker login https://registry.proxyq.co -u ${REGISTRY_CREDENTIALS_USR} -p ${REGISTRY_CREDENTIALS_PSW}'
|
|
sh 'docker push registry.proxyq.co/jenkins/website:${env.BUILD_ID}'
|
|
}
|
|
}
|
|
}
|
|
}
|