New job for Fuel Plugin Build 61/1761/1
authorSzilard Cserey <szilard.cserey@ericsson.com>
Fri, 18 Sep 2015 14:37:28 +0000 (16:37 +0200)
committerSzilard Cserey <szilard.cserey@ericsson.com>
Fri, 18 Sep 2015 14:37:28 +0000 (16:37 +0200)
Update of Fuel Deploy job - for fetching the newly build Fuel Plugin

Change-Id: I983f4244739370510012ddf6445667f53def3734
Signed-off-by: Szilard Cserey <szilard.cserey@ericsson.com>
jjb/genesis/genesis-fuel.yml
utils/lab-reconfiguration/create_venv.sh
utils/lab-reconfiguration/requirements.pip

index 405fbc0..f99fa93 100644 (file)
 
     builders:
         - 'fuel-download-artifact'
+        - 'fuel-opendaylight-plugin-build'
         - 'fuel-deploy'
 
     publishers:
             echo "--------------------------------------------------------"
             echo "Done!"
 
+- builder:
+    name: 'fuel-opendaylight-plugin-build'
+    builders:
+        - shell: |
+            #!/bin/bash
+            set -o errexit
+            set -o nounset
+            set -o pipefail
+
+            # log info to console
+            echo "Starting the build of Fuel Opendaylight Plugin. This could take some time..."
+            echo "--------------------------------------------------------"
+            echo
+
+            export ODL_PLUGIN_BRANCH="juno/lithium-sr1"
+
+            cd $WORKSPACE
+            git clone https://github.com/stackforge/fuel-plugin-opendaylight
+
+            pushd $WORKSPACE/fuel-plugin-opendaylight
+            git checkout $ODL_PLUGIN_BRANCH
+            popd
+
+            fpb --build fuel-plugin-opendaylight/
+
+            echo
+            echo "--------------------------------------------------------"
+            echo "Done!"
+
 - builder:
     name: 'fuel-deploy'
     builders:
             chmod a+x $TMPDIR
 
             # set CONFDIR, BRIDGE
-            export CONFDIR=$WORKSPACE/fuel/deploy/templates/hardware_environment/old_conf/linux_foundation_lab/pod2/ha
+            export CONFDIR=$WORKSPACE/fuel/deploy/templates/hardware_environment/conf/linux_foundation_lab/pod2
             export BRIDGE=pxebr
+            export PLUGIN=$WORKSPACE/fuel-plugin-opendaylight
 
             # cleanup first
             sudo $WORKSPACE/common/ci/clean.sh -base_config $WORKSPACE/foreman/ci/inventory/lf_pod2_ksgen_settings.yml
 
             # start the deployment
             echo "Issuing command"
-            echo "sudo $WORKSPACE/fuel/ci/deploy.sh -iso $WORKSPACE/opnfv.iso -dea $CONFDIR/dea.yaml -dha $CONFDIR/dha.yaml -s $TMPDIR -b $BRIDGE"
-            sudo $WORKSPACE/fuel/ci/deploy.sh -iso $WORKSPACE/opnfv.iso -dea $CONFDIR/dea.yaml -dha $CONFDIR/dha.yaml -s $TMPDIR -b $BRIDGE
+            echo "sudo $WORKSPACE/fuel/ci/deploy.sh -iso $WORKSPACE/opnfv.iso -dea $CONFDIR/dea.yaml -dha $CONFDIR/dha.yaml -s $TMPDIR -b $BRIDGE -p $PLUGIN"
+            sudo $WORKSPACE/fuel/ci/deploy.sh -iso $WORKSPACE/opnfv.iso -dea $CONFDIR/dea.yaml -dha $CONFDIR/dha.yaml -s $TMPDIR -b $BRIDGE -p $PLUGIN
 
             echo
             echo "--------------------------------------------------------"
index 4e45f84..e94b22b 100755 (executable)
@@ -30,6 +30,16 @@ if [[ ! $(rpm -qa | grep python-2.7) ]]; then
     sudo yum install -y python-2.7*
 fi
 
+if [[ ! $(rpm -qa | grep rubygems) ]]; then
+    echo "Rubygems not found, but required for Fuel Plugin build ... attempting to install"
+    sudo yum install -y rubygems ruby-devel
+fi
+
+if [[ ! $(gem list | grep fpm) ]]; then
+    echo "fpm gem not found, but required for Fuel Plugin build ... attempting to install"
+    sudo gem install fpm
+fi
+
 if [ ! -f "$BASEDIR/venv/updated" -o $BASEDIR/requirements.pip -nt $BASEDIR/venv/updated ]; then
     source $BASEDIR/venv/bin/activate
     pip install -r $BASEDIR/requirements.pip
index 8cd1db0..dd3207b 100644 (file)
@@ -1,2 +1,3 @@
 UcsSdk==0.8.2.2
 PyYAML
+fuel-plugin-builder
\ No newline at end of file