From f579df75d3a7b14e9c85fa6667deaab91a4339c4 Mon Sep 17 00:00:00 2001 From: Dan Radez Date: Tue, 27 Oct 2015 01:55:20 -0400 Subject: adding the opendaylight integration Change-Id: Iaaf5cbc790abd3b7af6f94b4e6d7e8ecfbbc6534 --- build/instack.sh | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) (limited to 'build/instack.sh') 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 -- cgit 1.2.3-korg