diff --git a/Jenkinsfile b/Jenkinsfile index 301e86a..b37d1b9 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -88,6 +88,32 @@ pipeline { } } } + + stage('Promoting release v5.0') { + when { + branch 'v5.0' + } + stages { + stage('Generating release') { + steps { + sh 'docker tag registry.sonata-nfv.eu:5000/tng-vnv-dsm:latest registry.sonata-nfv.eu:5000/tng-vnv-dsm:v5.0' + sh 'docker tag registry.sonata-nfv.eu:5000/tng-vnv-dsm:latest sonatanfv/tng-vnv-dsm:v5.0' + sh 'docker push registry.sonata-nfv.eu:5000/tng-vnv-dsm:v5.0' + sh 'docker push sonatanfv/tng-vnv-dsm:v5.0' + } + } + stage('Deploying in v5.0 servers') { + steps { + sh 'rm -rf tng-devops || true' + sh 'git clone https://github.com/sonata-nfv/tng-devops.git' + dir(path: 'tng-devops') { + sh 'ansible-playbook roles/vnv.yml -i environments -e "target=sta-vnv-v5-0 component=tng-vnv-dsm"' + } + } + } + } + } + } post { always {