alshabib | f6c93b9 | 2016-10-22 17:55:04 +0200 | [diff] [blame^] | 1 | node('build') { |
alshabib | 16bdc1a | 2016-10-18 14:31:32 +0100 | [diff] [blame] | 2 | stage 'Checkout cord repo' |
alshabib | f6c93b9 | 2016-10-22 17:55:04 +0200 | [diff] [blame^] | 3 | checkout([$class: 'RepoScm', currentBranch: true, manifestRepositoryUrl: 'https://gerrit.opencord.org/manifest', quiet: true]) |
alshabib | 16bdc1a | 2016-10-18 14:31:32 +0100 | [diff] [blame] | 4 | |
| 5 | dir ('incubator/voltha') { |
| 6 | try { |
| 7 | stage 'Bring up voltha dev vm' |
| 8 | sh 'vagrant up voltha' |
| 9 | |
| 10 | stage 'Build voltha' |
| 11 | sh 'vagrant ssh -c "cd /voltha && source env.sh && make fetch && make" voltha' |
| 12 | |
| 13 | stage 'Bring up voltha containers' |
| 14 | sh 'vagrant ssh -c "cd /voltha && source env.sh && docker-compose -f compose/docker-compose-system-test.yml up -d" voltha' |
| 15 | |
| 16 | currentBuild.result = 'SUCCESS' |
alshabib | 16bdc1a | 2016-10-18 14:31:32 +0100 | [diff] [blame] | 17 | } catch (err) { |
| 18 | currentBuild.result = 'FAILURE' |
| 19 | step([$class: 'Mailer', notifyEveryUnstableBuild: true, recipients: 'cord-dev@opencord.org', sendToIndividuals: false]) |
| 20 | } finally { |
| 21 | sh 'vagrant destroy -f voltha' |
| 22 | } |
| 23 | echo "RESULT: ${currentBuild.result}" |
| 24 | } |
| 25 | } |