326f0bbac9d851e3f8821073af92e3e573be7c0a
[releng.git] / jjb / apex / apex.yml
1 - project:
2     name: apex
3     jobs:
4         - 'apex-verify-{stream}'
5         - 'apex-merge-{stream}'
6         - 'apex-build-{stream}'
7         - 'apex-deploy-virtual-{scenario}-{stream}'
8         - 'apex-deploy-baremetal-{scenario}-{stream}'
9         - 'apex-daily-{stream}'
10
11     # stream:    branch with - in place of / (eg. stable-arno)
12     # branch:    branch (eg. stable/arno)
13     stream:
14         - master:
15             branch: 'master'
16             gs-pathname: ''
17         - brahmaputra:
18             branch: 'stable/brahmaputra'
19             gs-pathname: '/brahmaputra'
20             disabled: true
21
22     project: 'apex'
23
24     scenario:
25          - 'os-odl_l2-nofeature-ha'
26          - 'os-odl_l2-sfc-ha'
27          - 'os-odl_l3-nofeature-ha'
28          - 'os-onos-nofeature-ha'
29          - 'os-opencontrail-nofeature-ha'
30
31 - job-template:
32     name: 'apex-verify-{stream}'
33
34     node: opnfv-jump-1
35
36     parameters:
37         - apex-parameter:
38             gs-pathname: '{gs-pathname}'
39         - project-parameter:
40             project: '{project}'
41         - gerrit-parameter:
42             branch: '{branch}'
43         - string:
44             name: GIT_BASE
45             default: https://gerrit.opnfv.org/gerrit/$PROJECT
46             description: "Used for overriding the GIT URL coming from parameters macro."
47
48     scm:
49         - gerrit-trigger-scm:
50             credentials-id: '{ssh-credentials}'
51             refspec: '$GERRIT_REFSPEC'
52             choosing-strategy: 'gerrit'
53
54     triggers:
55         - gerrit:
56             trigger-on:
57                 - patchset-created-event:
58                     exclude-drafts: 'false'
59                     exclude-trivial-rebase: 'false'
60                     exclude-no-code-change: 'false'
61                 - draft-published-event
62                 - comment-added-contains-event:
63                     comment-contains-value: 'recheck'
64                 - comment-added-contains-event:
65                     comment-contains-value: 'reverify'
66             projects:
67               - project-compare-type: 'ANT'
68                 project-pattern: 'apex'
69                 branches:
70                   - branch-compare-type: 'ANT'
71                     branch-pattern: '**/{branch}'
72                 file-paths:
73                   - compare-type: ANT
74                     pattern: 'ci/**'
75                   - compare-type: ANT
76                     pattern: 'build/**'
77                   - compare-type: ANT
78                     pattern: 'lib/**'
79                   - compare-type: ANT
80                     pattern: 'config/**'
81                 forbidden-file-paths:
82                   - compare-type: ANT
83                     pattern: 'docs/**'
84
85     properties:
86         - build-blocker:
87             use-build-blocker: true
88             blocking-jobs:
89                 - "apex-daily.*"
90                 - "apex-deploy.*"
91                 - "apex-build.*"
92
93     builders:
94         - 'apex-build'
95         - trigger-builds:
96           - project: 'apex-deploy-virtual-os-odl_l2-nofeature-ha-{stream}'
97             predefined-parameters:
98               BUILD_DIRECTORY=apex-verify-master/build_output
99             git-revision: false
100             block: true
101         - trigger-builds:
102           - project: 'apex-deploy-virtual-os-onos-nofeature-ha-{stream}'
103             predefined-parameters:
104               BUILD_DIRECTORY=apex-verify-master/build_output
105             git-revision: false
106             block: true
107         - 'apex-workspace-cleanup'
108
109 - job-template:
110     name: 'apex-merge-{stream}'
111
112     # builder-merge job to run JJB update
113     #
114     # This job's purpose is to update all the JJB
115
116     node: opnfv-jump-1
117
118     disabled: true
119
120     parameters:
121         - apex-parameter:
122             gs-pathname: '{gs-pathname}'
123         - project-parameter:
124             project: '{project}'
125         - gerrit-parameter:
126             branch: '{branch}'
127         - string:
128             name: GIT_BASE
129             default: https://gerrit.opnfv.org/gerrit/$PROJECT
130             description: "Used for overriding the GIT URL coming from parameters macro."
131
132     scm:
133         - gerrit-trigger-scm:
134             credentials-id: '{ssh-credentials}'
135             refspec: ''
136             choosing-strategy: 'default'
137
138     triggers:
139         - gerrit:
140             trigger-on:
141                 - change-merged-event
142                 - comment-added-contains-event:
143                     comment-contains-value: 'remerge'
144             projects:
145               - project-compare-type: 'ANT'
146                 project-pattern: 'apex'
147                 branches:
148                     - branch-compare-type: 'ANT'
149                       branch-pattern: '**/master'
150                 forbidden-file-paths:
151                   - compare-type: ANT
152                     pattern: 'docs/**'
153
154     builders:
155         - 'apex-build'
156         - 'apex-deploy-virtual'
157         - 'apex-workspace-cleanup'
158
159 - job-template:
160     name: 'apex-build-{stream}'
161
162     # Job template for builds
163     #
164     # Required Variables:
165     #     stream:    branch with - in place of / (eg. stable)
166     #     branch:    branch (eg. stable)
167     node: opnfv-jump-1
168
169     disabled: false
170
171     parameters:
172         - project-parameter:
173             project: '{project}'
174         - apex-parameter:
175             gs-pathname: '{gs-pathname}'
176         - gerrit-parameter:
177             branch: '{branch}'
178         - string:
179             name: GIT_BASE
180             default: https://gerrit.opnfv.org/gerrit/$PROJECT
181             description: "Used for overriding the GIT URL coming from parameters macro."
182
183     scm:
184         - git-scm:
185             credentials-id: '{ssh-credentials}'
186             refspec: ''
187             branch: '{branch}'
188
189     properties:
190         - build-blocker:
191             use-build-blocker: true
192             blocking-jobs:
193                 - "apex-deploy.*"
194
195     builders:
196         - 'apex-build'
197         - trigger-builds:
198           - project: 'apex-deploy-virtual-os-odl_l2-nofeature-ha-{stream}'
199             predefined-parameters:
200               BUILD_DIRECTORY=apex-build-master/build_output
201             git-revision: false
202             block: true
203         - 'apex-upload-artifact'
204         - 'apex-workspace-cleanup'
205
206 - job-template:
207     name: 'apex-deploy-virtual-{scenario}-{stream}'
208
209     # Job template for virtual deployment
210     #
211     # Required Variables:
212     #     stream:    branch with - in place of / (eg. stable)
213     #     branch:    branch (eg. stable)
214     node: opnfv-jump-1
215
216     disabled: false
217
218     scm:
219         - git-scm:
220             credentials-id: '{ssh-credentials}'
221             refspec: ''
222             branch: '{branch}'
223
224     parameters:
225         - project-parameter:
226             project: '{project}'
227         - apex-parameter:
228             gs-pathname: '{gs-pathname}'
229         - string:
230             name: DEPLOY_SCENARIO
231             default: '{scenario}'
232             description: "Scenario to deploy with."
233
234     properties:
235         - build-blocker:
236             use-build-blocker: true
237             blocking-jobs:
238                 - "apex-deploy.*"
239                 - "apex-build.*"
240
241     builders:
242         - 'apex-deploy-virtual'
243         - 'apex-workspace-cleanup'
244
245 - job-template:
246     name: 'apex-deploy-baremetal-{scenario}-{stream}'
247
248     # Job template for baremetal deployment
249     #
250     # Required Variables:
251     #     stream:    branch with - in place of / (eg. stable)
252     #     branch:    branch (eg. stable)
253     node: opnfv-jump-1
254
255     disabled: false
256
257     scm:
258         - git-scm:
259             credentials-id: '{ssh-credentials}'
260             refspec: ''
261             branch: '{branch}'
262
263     parameters:
264         - project-parameter:
265             project: '{project}'
266         - apex-parameter:
267             gs-pathname: '{gs-pathname}'
268         - string:
269             name: DEPLOY_SCENARIO
270             default: '{scenario}'
271             description: "Scenario to deploy with."
272
273     properties:
274         - build-blocker:
275             use-build-blocker: true
276             blocking-jobs:
277                 - "apex-verify.*"
278                 - "apex-deploy.*"
279                 - "apex-build.*"
280
281
282     builders:
283         - 'apex-deploy-baremetal'
284         - 'apex-workspace-cleanup'
285
286 - job-template:
287     name: 'apex-daily-{stream}'
288
289     # Job template for daily build
290     #
291     # Required Variables:
292     #     stream:    branch with - in place of / (eg. stable)
293     #     branch:    branch (eg. stable)
294     node: opnfv-jump-1
295
296     disabled: false
297
298     scm:
299         - git-scm:
300             credentials-id: '{ssh-credentials}'
301             refspec: ''
302             branch: '{branch}'
303
304     parameters:
305         - project-parameter:
306             project: '{project}'
307         - apex-parameter:
308             gs-pathname: '{gs-pathname}'
309
310     properties:
311         - build-blocker:
312             use-build-blocker: true
313             blocking-jobs:
314                 - "apex-verify.*"
315                 - "apex-deploy.*"
316                 - "apex-build.*"
317
318     triggers:
319         - 'apex-master'
320
321     builders:
322         - trigger-builds:
323           - project: 'apex-build-{stream}'
324             git-revision: true
325             current-parameters: true
326             block: true
327         - trigger-builds:
328           - project: 'apex-deploy-baremetal-os-odl_l2-nofeature-ha-{stream}'
329             predefined-parameters:
330               BUILD_DIRECTORY=apex-build-master/build_output
331             git-revision: true
332             block: true
333         - trigger-builds:
334           - project: 'functest-apex-opnfv-jump-1-daily-{stream}'
335             block: true
336             block-thresholds:
337                 build-step-failure-threshold: 'never'
338                 failure-threshold: 'never'
339                 unstable-threshold: 'FAILURE'
340         - trigger-builds:
341           - project: 'yardstick-apex-opnfv-jump-1-daily-{stream}'
342             block: true
343             block-thresholds:
344                 build-step-failure-threshold: 'never'
345                 failure-threshold: 'never'
346                 unstable-threshold: 'FAILURE'
347         - trigger-builds:
348           - project: 'apex-deploy-baremetal-os-onos-nofeature-ha-{stream}'
349             predefined-parameters:
350               BUILD_DIRECTORY=apex-build-master/build_output
351             git-revision: true
352             block: true
353         - trigger-builds:
354           - project: 'functest-apex-opnfv-jump-1-daily-{stream}'
355             block: true
356             block-thresholds:
357                 build-step-failure-threshold: 'never'
358                 failure-threshold: 'never'
359                 unstable-threshold: 'FAILURE'
360         - trigger-builds:
361           - project: 'yardstick-apex-opnfv-jump-1-daily-{stream}'
362             block: true
363             block-thresholds:
364                 build-step-failure-threshold: 'never'
365                 failure-threshold: 'never'
366                 unstable-threshold: 'FAILURE'
367
368 ########################
369 # parameter macros
370 ########################
371 - parameter:
372     name: apex-parameter
373     parameters:
374         - string:
375             name: ARTIFACT_NAME
376             default: 'latest'
377             description: "RPM Artifact name that will be appended to GS_URL to deploy a specific artifact"
378         - string:
379             name: ARTIFACT_VERSION
380             default: 'daily'
381             description: "Artifact version type"
382         - string:
383             name: BUILD_DIRECTORY
384             default: $WORKSPACE/build_output
385             description: "Directory where the build artifact will be located upon the completion of the build."
386         - string:
387             name: CACHE_DIRECTORY
388             default: $HOME/opnfv/cache{gs-pathname}
389             description: "Directory where the cache to be used during the build is located."
390         - string:
391             name: GIT_BASE
392             default: https://gerrit.opnfv.org/gerrit/$PROJECT
393             description: "Used for overriding the GIT URL coming from Global Jenkins configuration in case if the stuff is done on none-LF HW."
394         - string:
395             name: GS_URL
396             default: artifacts.opnfv.org/$PROJECT{gs-pathname}
397             description: "URL to Google Storage."
398
399 ########################
400 # builder macros
401 ########################
402 - builder:
403     name: 'apex-build'
404     builders:
405         - shell: |
406             #!/bin/bash
407             set -o errexit
408             set -o nounset
409             set -o pipefail
410             # log info to console
411             echo "Starting the build of Apex using OpenStack Master packages. This will take some time..."
412             echo "---------------------------------------------------------------------------------------"
413             echo
414             # create the cache directory if it doesn't exist
415             [[ -d $CACHE_DIRECTORY ]] || mkdir -p $CACHE_DIRECTORY
416             # set OPNFV_ARTIFACT_VERSION
417             if echo $GERRIT_BRANCH | grep "brahmaputra" 1> /dev/null; then
418               export OPNFV_ARTIFACT_VERSION="bramaputra.1.rc0"
419             else
420               if echo $BUILD_TAG | grep "apex-verify" 1> /dev/null; then
421                 export OPNFV_ARTIFACT_VERSION=dev${BUILD_NUMBER}
422               elif [ "$ARTIFACT_VERSION" == "daily" ]; then
423                 export OPNFV_ARTIFACT_VERSION=$(date -u +"%Y-%m-%d")
424               else
425                 export OPNFV_ARTIFACT_VERSION=${ARTIFACT_VERSION}
426               fi
427             fi
428             # start the build
429             cd $WORKSPACE/ci
430             ./build.sh -v $OPNFV_ARTIFACT_VERSION -c file://$CACHE_DIRECTORY $BUILD_DIRECTORY
431             RPM_VERSION=$(grep Version $BUILD_DIRECTORY/../build/opnfv-apex.spec | awk '{ print $2 }')-$(echo $OPNFV_ARTIFACT_VERSION | tr -d '_-')
432             # list the contents of BUILD_OUTPUT directory
433             ls -al $BUILD_DIRECTORY
434             # save information regarding artifact into file
435             (
436                 echo "OPNFV_ARTIFACT_VERSION=$OPNFV_ARTIFACT_VERSION"
437                 echo "OPNFV_GIT_URL=$(git config --get remote.origin.url)"
438                 echo "OPNFV_GIT_SHA1=$(git rev-parse HEAD)"
439                 echo "OPNFV_ARTIFACT_URL=$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso"
440                 echo "OPNFV_ARTIFACT_MD5SUM=$(md5sum $BUILD_DIRECTORY/OPNFV-CentOS-7-x86_64-$OPNFV_ARTIFACT_VERSION.iso | cut -d' ' -f1)"
441                 echo "OPNFV_SRPM_URL=$GS_URL/opnfv-apex-$RPM_VERSION.src.rpm"
442                 echo "OPNFV_RPM_URL=$GS_URL/opnfv-apex-$RPM_VERSION.noarch.rpm"
443                 echo "OPNFV_RPM_MD5SUM=$(md5sum $BUILD_DIRECTORY/opnfv-apex-$RPM_VERSION.noarch.rpm | cut -d' ' -f1)"
444                 echo "OPNFV_BUILD_URL=$BUILD_URL"
445             ) > $WORKSPACE/opnfv.properties
446             echo
447             echo "--------------------------------------------------------"
448
449 - builder:
450     name: 'apex-workspace-cleanup'
451     builders:
452         - shell: |
453             #!/bin/bash
454             set -o errexit
455             set -o nounset
456             set -o pipefail
457
458             # delete everything that is in $WORKSPACE
459             /bin/rm -rf $WORKSPACE
460
461 - builder:
462     name: 'apex-upload-artifact'
463     builders:
464         - shell: |
465             #!/bin/bash
466             set -o errexit
467             set -o nounset
468             set -o pipefail
469
470             # log info to console
471             echo "Uploading the Apex artifact. This could take some time..."
472             echo "--------------------------------------------------------"
473             echo
474
475             # source the opnfv.properties to get ARTIFACT_VERSION
476             source $WORKSPACE/opnfv.properties
477
478             # upload artifact and additional files to google storage
479             gsutil cp $BUILD_DIRECTORY/OPNFV-CentOS-7-x86_64-$OPNFV_ARTIFACT_VERSION.iso gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso > gsutil.iso.log 2>&1
480             RPM_INSTALL_PATH=$BUILD_DIRECTORY/$(basename $OPNFV_RPM_URL)
481             RPM_LIST=$RPM_INSTALL_PATH
482             for pkg in common undercloud; do
483                 RPM_LIST+=" ${RPM_INSTALL_PATH/opnfv-apex/opnfv-apex-${pkg}}"
484             done
485             SRPM_INSTALL_PATH=$BUILD_DIRECTORY/$(basename $OPNFV_SRPM_URL)
486             SRPM_LIST=$SRPM_INSTALL_PATH
487             for pkg in common undercloud; do
488                 SRPM_LIST+=" ${SRPM_INSTALL_PATH/opnfv-apex/opnfv-apex-${pkg}}"
489             done
490             for artifact in $RPM_LIST $SRPM_LIST; do
491               gsutil cp $artifact gs://$GS_URL/$(basename $artifact) > gsutil.iso.log 2>&1
492             done
493             gsutil cp $WORKSPACE/opnfv.properties gs://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.properties > gsutil.properties.log 2>&1
494             gsutil cp $WORKSPACE/opnfv.properties gs://$GS_URL/latest.properties > gsutil.latest.log 2>&1
495
496             echo
497             echo "--------------------------------------------------------"
498             echo "Done!"
499             echo "ISO Artifact is available as http://$GS_URL/opnfv-$OPNFV_ARTIFACT_VERSION.iso"
500             echo "RPM Artifact is available as http://$GS_URL/$(basename $OPNFV_RPM_URL)"
501
502 - builder:
503     name: 'apex-deploy-virtual'
504     builders:
505         - shell: |
506             #!/bin/bash
507             set -o errexit
508             set -o nounset
509             set -o pipefail
510
511             # log info to console
512             echo "Starting the Apex virtual deployment."
513             echo "--------------------------------------------------------"
514             echo
515
516             if [[ ! "$ARTIFACT_NAME" == "latest" ]]; then
517                 # if artifact name is passed the pull a
518                 # specific artifact from artifacts.opnfv.org
519                 RPM_INSTALL_PATH=$GS_URL/$ARTIFACT_NAME
520             else
521                 if [[ $BUILD_DIRECTORY == *verify* ]]; then
522                   BUILD_DIRECTORY=$WORKSPACE/../$BUILD_DIRECTORY
523                   echo "BUILD DIRECTORY modified to $BUILD_DIRECTORY"
524                 fi
525
526                 if [[ -f ${BUILD_DIRECTORY}/../opnfv.properties ]]; then
527                     # if opnfv.properties exists then use the
528                     # local build. Source the file so we get local OPNFV vars
529                     source ${BUILD_DIRECTORY}/../opnfv.properties
530                     RPM_INSTALL_PATH=${BUILD_DIRECTORY}/$(basename $OPNFV_RPM_URL)
531                 else
532                     if [[ $BUILD_DIRECTORY == *verify* ]]; then
533                       echo "BUILD_DIRECTORY is from a verify job, so will not use latest from URL"
534                       echo "Check that the slave has opnfv.properties in $BUILD_DIRECTORY"
535                       exit 1
536                     fi
537                     # no opnfv.properties means use the latest from artifacts.opnfv.org
538                     # get the latest.properties to get the link to the latest artifact
539                     curl -s -o $WORKSPACE/opnfv.properties http://$GS_URL/latest.properties
540                     [[ -f opnfv.properties ]] || exit 1
541                     # source the file so we get OPNFV vars
542                     source opnfv.properties
543                     RPM_INSTALL_PATH=$OPNFV_RPM_URL
544                 fi
545             fi
546
547             RPM_LIST=$RPM_INSTALL_PATH
548             for pkg in common undercloud; do
549                 RPM_LIST+=" ${RPM_INSTALL_PATH/opnfv-apex/opnfv-apex-${pkg}}"
550             done
551
552             # update / install the new rpm
553             if rpm -q opnfv-apex > /dev/null; then
554                if [ $(basename $OPNFV_RPM_URL) == $(rpm -q opnfv-apex).rpm ]; then
555                  echo "RPM is already installed"
556                elif sudo yum update -y $RPM_LIST | grep "does not update installed package"; then
557                    if ! sudo yum downgrade -y $RPM_LIST; then
558                      sudo yum remove -y opnfv-undercloud opnfv-common
559                      sudo yum downgrade -y $RPM_INSTALL_PATH
560                    fi
561                fi
562             else
563                sudo yum install -y $RPM_LIST;
564             fi
565
566             # cleanup virtual machines before we start
567             sudo opnfv-clean
568             # initiate virtual deployment
569             if [ -e /etc/opnfv-apex/network_settings.yaml ]; then
570               if [ -n "$DEPLOY_SCENARIO" ]; then
571                 echo "Deploy Scenario set to ${DEPLOY_SCENARIO}"
572                 if [ -e /etc/opnfv-apex/${DEPLOY_SCENARIO}.yaml ]; then
573                   sudo opnfv-deploy -v -d /etc/opnfv-apex/${DEPLOY_SCENARIO}.yaml -n /etc/opnfv-apex/network_settings.yaml
574                 else
575                   echo "File does not exist /etc/opnfv-apex/${DEPLOY_SCENARIO}.yaml"
576                   exit 1
577                 fi
578               else
579                 echo "Deploy scenario not set!"
580                 exit 1
581               fi
582             else
583               sudo opnfv-deploy -v
584             fi
585             echo
586             echo "--------------------------------------------------------"
587             echo "Done!"
588
589 - builder:
590     name: 'apex-deploy-baremetal'
591     builders:
592         - shell: |
593             #!/bin/bash
594             set -o errexit
595             set -o nounset
596             set -o pipefail
597
598             # log info to console
599             echo "Starting the Apex baremetal deployment."
600             echo "--------------------------------------------------------"
601             echo
602
603             if [[ ! "$ARTIFACT_NAME" == "latest" ]]; then
604                 # if artifact name is passed the pull a
605                 # specific artifact from artifacts.opnfv.org
606                 RPM_INSTALL_PATH=$GS_URL/$ARTIFACT_NAME
607             else
608                 if [[ $BUILD_DIRECTORY == *apex-build* ]]; then
609                   BUILD_DIRECTORY=$WORKSPACE/../$BUILD_DIRECTORY
610                   echo "BUILD DIRECTORY modified to $BUILD_DIRECTORY"
611                 fi
612                 if [[ -f ${BUILD_DIRECTORY}/../opnfv.properties ]]; then
613                     # if opnfv.properties exists then use the
614                     # local build. Source the file so we get local OPNFV vars
615                     source ${BUILD_DIRECTORY}/../opnfv.properties
616                     RPM_INSTALL_PATH=${BUILD_DIRECTORY}/$(basename $OPNFV_RPM_URL)
617                 else
618                     # no opnfv.properties means use the latest from artifacts.opnfv.org
619                     # get the latest.properties to get the link to the latest artifact
620                     curl -s -o $WORKSPACE/opnfv.properties http://$GS_URL/latest.properties
621                     [[ -f opnfv.properties ]] || exit 1
622                     # source the file so we get OPNFV vars
623                     source opnfv.properties
624                     RPM_INSTALL_PATH=$OPNFV_RPM_URL
625                 fi
626             fi
627
628             if [ ! -e "$RPM_INSTALL_PATH" ]; then
629                RPM_INSTALL_PATH=http://${OPNFV_RPM_URL}
630             fi
631
632             RPM_LIST=$RPM_INSTALL_PATH
633             for pkg in common undercloud; do
634                 RPM_LIST+=" ${RPM_INSTALL_PATH/opnfv-apex/opnfv-apex-${pkg}}"
635             done
636
637             # update / install the new rpm
638             if rpm -q opnfv-apex > /dev/null; then
639                if [ $(basename $OPNFV_RPM_URL) == $(rpm -q opnfv-apex).rpm ]; then
640                  echo "RPM is already installed"
641                elif sudo yum update -y $RPM_LIST | grep "does not update installed package"; then
642                    if ! sudo yum downgrade -y $RPM_LIST; then
643                      sudo yum remove -y opnfv-undercloud opnfv-common
644                      sudo yum downgrade -y $RPM_INSTALL_PATH
645                    fi
646                fi
647             else
648                sudo yum install -y $RPM_LIST;
649             fi
650
651             # cleanup environment before we start
652             sudo opnfv-clean
653             # initiate baremetal deployment
654             if [ -e /etc/opnfv-apex/network_settings.yaml ]; then
655               if [ -n "$DEPLOY_SCENARIO" ]; then
656                 echo "Deploy Scenario set to ${DEPLOY_SCENARIO}"
657                 if [ -e /etc/opnfv-apex/${DEPLOY_SCENARIO}.yaml ]; then
658                   sudo opnfv-deploy -i  /root/inventory/pod_settings.yaml \
659                   -d /etc/opnfv-apex/${DEPLOY_SCENARIO}.yaml \
660                   -n /root/network_settings.yaml
661                 else
662                   echo "File does not exist /etc/opnfv-apex/${DEPLOY_SCENARIO}.yaml"
663                   exit 1
664                 fi
665               else
666                 echo "Deploy scenario not set!"
667                 exit 1
668               fi
669             else
670               echo "File /etc/opnfv-apex/network_settings.yaml does not exist!"
671               exit 1
672             fi
673
674             echo
675             echo "--------------------------------------------------------"
676             echo "Done!"
677
678 #######################
679 # trigger macros
680 ########################
681 - trigger:
682     name: 'apex-master'
683     triggers:
684         - timed: '0 3 * * *'