diff options
author | Lusheng Ji <lji@research.att.com> | 2017-10-16 21:51:26 -0400 |
---|---|---|
committer | Lusheng Ji <lji@research.att.com> | 2017-10-16 21:51:33 -0400 |
commit | 5513513ddcbd4209df012e33ea07cf7f9552b14b (patch) | |
tree | 5d7f5f1ac5f9c8a061033156c862eed9b98ec66d /boot | |
parent | f79590758d6cce11b10d9257af798c8f8bc10f1e (diff) |
Fix install script for dcae2
Issue-Id: DCAEGEN2-127
Change-Id: Icbb9e69d7cd28161ac4fc48f4449e188ae72e0d7
Signed-off-by: Lusheng Ji <lji@research.att.com>
Diffstat (limited to 'boot')
-rw-r--r-- | boot/dcae2_install.sh | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/boot/dcae2_install.sh b/boot/dcae2_install.sh index 5868607b..21587467 100644 --- a/boot/dcae2_install.sh +++ b/boot/dcae2_install.sh @@ -1,5 +1,7 @@ #!/bin/bash +set -ex + # Read configuration files NEXUS_REPO=$(cat /opt/config/nexus_repo.txt) ARTIFACTS_VERSION=$(cat /opt/config/artifacts_version.txt) @@ -52,7 +54,7 @@ fi echo "deb http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list echo "deb-src http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list apt-get update -apt-get install --allow-unauthenticated -y apt-transport-https ca-certificates wget make openjdk-8-jdk git ntp ntpdate +apt-get install --allow-unauthenticated -y apt-transport-https ca-certificates wget make openjdk-8-jdk git ntp ntpdate python python-pip # Download scripts from Nexus curl -k $NEXUS_REPO/org.onap.demo/boot/$ARTIFACTS_VERSION/dcae2_vm_init.sh -o /opt/dcae2_vm_init.sh @@ -68,7 +70,7 @@ apt-get update apt-get install -y linux-image-extra-$(uname -r) linux-image-extra-virtual apt-get install -y --allow-unauthenticated docker-engine -mkdir /opt/docker +mkdir -p /opt/docker curl -L https://github.com/docker/compose/releases/download/1.9.0/docker-compose-`uname -s`-`uname -m` > /opt/docker/docker-compose chmod +x /opt/docker/docker-compose @@ -117,16 +119,16 @@ wget https://nexus.onap.org/service/local/repositories/raw/content/org.onap.dcae # Rename network interface in openstack Ubuntu 16.04 images. Then, reboot the VM to pick up changes -if [[ $CLOUD_ENV != "rackspace" ]] -then - sed -i "s/GRUB_CMDLINE_LINUX=.*/GRUB_CMDLINE_LINUX=\"net.ifnames=0 biosdevname=0\"/g" /etc/default/grub - grub-mkconfig -o /boot/grub/grub.cfg - sed -i "s/ens[0-9]*/eth0/g" /etc/network/interfaces.d/*.cfg - sed -i "s/ens[0-9]*/eth0/g" /etc/udev/rules.d/70-persistent-net.rules - echo 'network: {config: disabled}' >> /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg - echo "APT::Periodic::Unattended-Upgrade \"0\";" >> /etc/apt/apt.conf.d/10periodic - reboot -fi +#if [[ $CLOUD_ENV != "rackspace" ]] +#then +# sed -i "s/GRUB_CMDLINE_LINUX=.*/GRUB_CMDLINE_LINUX=\"net.ifnames=0 biosdevname=0\"/g" /etc/default/grub +# grub-mkconfig -o /boot/grub/grub.cfg +# sed -i "s/ens[0-9]*/eth0/g" /etc/network/interfaces.d/*.cfg +# sed -i "s/ens[0-9]*/eth0/g" /etc/udev/rules.d/70-persistent-net.rules +# echo 'network: {config: disabled}' >> /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg +# echo "APT::Periodic::Unattended-Upgrade \"0\";" >> /etc/apt/apt.conf.d/10periodic +# reboot +#fi # Run docker containers cd /opt |