summaryrefslogtreecommitdiffstats
path: root/build/instack.sh
diff options
context:
space:
mode:
Diffstat (limited to 'build/instack.sh')
-rwxr-xr-xbuild/instack.sh31
1 files changed, 30 insertions, 1 deletions
diff --git a/build/instack.sh b/build/instack.sh
index 79a99f83..1e8e8b38 100755
--- a/build/instack.sh
+++ b/build/instack.sh
@@ -57,9 +57,17 @@ elif [ "$1" == "-master" ]; then
sudo curl -o /etc/yum.repos.d/delorean.repo http://trunk.rdoproject.org/centos7-liberty/current-passed-ci/delorean.repo
sudo curl -o /etc/yum.repos.d/delorean-deps.repo http://trunk.rdoproject.org/centos7-liberty/delorean-deps.repo
sudo rm -f /etc/yum.repos.d/delorean-current.repo
-
fi
+# install the opendaylight yum repo definition
+cat << 'EOF' | sudo tee /etc/yum.repos.d/opendaylight.repo
+[opendaylight]
+name=OpenDaylight $releasever - $basearch
+baseurl=http://cbs.centos.org/repos/nfv7-opendaylight-3-candidate/$basearch/os/
+enabled=1
+gpgcheck=0
+EOF
+
# ensure the undercloud package is installed so we can build the undercloud
if ! rpm -q instack-undercloud > /dev/null; then
sudo yum install -y python-tripleoclient
@@ -187,6 +195,27 @@ for i in $IMAGES; do
curl https://repos.fedorapeople.org/repos/openstack-m/rdo-images-centos-liberty/$i -z stack/$i -o stack/$i --verbose --silent --location
done
+#Adding OpenDaylight to overcloud
+pushd stack
+cp overcloud-full.qcow2 overcloud-full-odl.qcow2
+for i in opendaylight python-networking-odl; do
+ yumdownloader $i
+ if rpmfile=$(ls -r $i*); then
+ rpmfile=$(echo $rpmfile | head -n1)
+ LIBGUESTFS_BACKEND=direct virt-customize --upload $rpmfile:/tmp --install /tmp/$rpmfile -a overcloud-full-odl.qcow2
+ else
+ echo "Cannot install $i into overcloud-full image."
+ exit 1
+ fi
+done
+rm -rf puppet-opendaylight
+git clone https://github.com/dfarrell07/puppet-opendaylight
+pushd puppet-opendaylight
+git archive --format=tar.gz --prefix=opendaylight/ HEAD > ../puppet-opendaylight.tar.gz
+popd
+LIBGUESTFS_BACKEND=direct virt-customize --upload puppet-opendaylight.tar.gz:/etc/puppet/modules/ --run-command "cd /etc/puppet/modules/; tar xzf puppet-opendaylight.tar.gz" -a overcloud-full-odl.qcow2
+popd
+
# move and Sanitize private keys from instack.json file
mv stack/instackenv.json instackenv-virt.json
sed -i '/pm_password/c\ "pm_password": "INSERT_STACK_USER_PRIV_KEY",' instackenv-virt.json