From 1504fa90460378597344e91120489225011d5966 Mon Sep 17 00:00:00 2001 From: Dan Radez Date: Wed, 2 Dec 2015 17:03:20 -0500 Subject: switching to RDO build undercloud instead of building it ourselves Change-Id: I9f09c195352d2d88a3da4f42e09424d96d39722b --- build/instack.sh | 65 ++++++++++++++++++++++++++++++-------------------------- 1 file changed, 35 insertions(+), 30 deletions(-) (limited to 'build/instack.sh') diff --git a/build/instack.sh b/build/instack.sh index f23df672..182d2367 100755 --- a/build/instack.sh +++ b/build/instack.sh @@ -40,14 +40,6 @@ fi ssh -T ${SSH_OPTIONS[@]} stack@localhost "rm -f instack*.qcow2" # Yum repo setup for building the undercloud -if ! rpm -q epel-release > /dev/null; then - sudo yum install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm -fi - -if ! rpm -q rdo-release > /dev/null; then - sudo yum install -y https://rdoproject.org/repos/openstack-${RDO_RELEASE}/rdo-release-${RDO_RELEASE}.rpm -fi - if ! rpm -q rdo-release > /dev/null && [ "$1" != "-master" ]; then sudo yum install -y https://rdoproject.org/repos/openstack-${RDO_RELEASE}/rdo-release-${RDO_RELEASE}.rpm sudo rm -rf /etc/yum.repos.d/delorean.repo @@ -117,6 +109,7 @@ done # yum repo, triple-o package and ssh key setup for the undercloud ssh -T ${SSH_OPTIONS[@]} "root@$UNDERCLOUD" < /dev/null; then yum install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm fi @@ -124,26 +117,20 @@ fi yum -y install yum-plugin-priorities curl -o /etc/yum.repos.d/delorean.repo http://trunk.rdoproject.org/centos7-liberty/current-passed-ci/delorean.repo curl -o /etc/yum.repos.d/delorean-deps.repo http://trunk.rdoproject.org/centos7-liberty/delorean-deps.repo -yum install -y python-tripleoclient + cp /root/.ssh/authorized_keys /home/stack/.ssh/authorized_keys chown stack:stack /home/stack/.ssh/authorized_keys EOI -# install undercloud on Undercloud VM -ssh -T ${SSH_OPTIONS[@]} "stack@$UNDERCLOUD" "openstack undercloud install" - # copy instackenv file for future virt deployments if [ ! -d stack ]; then mkdir stack; fi scp ${SSH_OPTIONS[@]} stack@$UNDERCLOUD:instackenv.json stack/instackenv.json -# Clean cache to reduce the images size -ssh -T ${SSH_OPTIONS[@]} "root@$UNDERCLOUD" "yum clean all" - # make a copy of instack VM's definitions, and disk image # it must be stopped to make a copy of its disk image ssh -T ${SSH_OPTIONS[@]} stack@localhost < ../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 +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 -- cgit 1.2.3-korg