summaryrefslogtreecommitdiffstats
path: root/vnfs/vCPE/scripts/v_dhcp_install.sh
diff options
context:
space:
mode:
authorMarco Platania <platania@research.att.com>2017-08-11 14:33:52 -0400
committerMarco Platania <platania@research.att.com>2017-08-11 14:33:52 -0400
commite346c99db30654950e119621e87786e0541fe84b (patch)
tree25b1982dd52d9311253ff5785176c30361531d2a /vnfs/vCPE/scripts/v_dhcp_install.sh
parent731f2eedda9f3bca960c4a404f02b9b450e67828 (diff)
Fix vDHCP start
Change-Id: I68c8a27b27892fb3a1433f73c7a4e199f3d27a3b Signed-off-by: Marco Platania <platania@research.att.com>
Diffstat (limited to 'vnfs/vCPE/scripts/v_dhcp_install.sh')
-rw-r--r--vnfs/vCPE/scripts/v_dhcp_install.sh15
1 files changed, 12 insertions, 3 deletions
diff --git a/vnfs/vCPE/scripts/v_dhcp_install.sh b/vnfs/vCPE/scripts/v_dhcp_install.sh
index 025b1980..d88ed509 100644
--- a/vnfs/vCPE/scripts/v_dhcp_install.sh
+++ b/vnfs/vCPE/scripts/v_dhcp_install.sh
@@ -56,20 +56,27 @@ sleep 1
# download the kea hook
cd /opt
wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/vcpe/kea-sdnc-notify-mod/$DEMO_ARTIFACTS_VERSION/kea-sdnc-notify-mod-$DEMO_ARTIFACTS_VERSION-demo.tar.gz
-tar -zxvf kea-sdnc-notify-mod.tar.gz
-mv kea-sdnc-notify-mod VDHCP
+tar -zxvf kea-sdnc-notify-mod-$DEMO_ARTIFACTS_VERSION-demo.tar.gz
+mv kea-sdnc-notify-mod-$DEMO_ARTIFACTS_VERSION VDHCP
rm *.tar.gz
cd VDHCP
# build.sh takes a minute or two to run
./build.sh
-mv kea-sdnc-notify.so /usr/local/lib
+mv build/kea-sdnc-notify.so /usr/local/lib
# Download DHCP config files
cd /opt
wget $REPO_URL_BLOB/org.onap.demo/vnfs/vcpe/$INSTALL_SCRIPT_VERSION/kea-dhcp4.conf
wget $REPO_URL_BLOB/org.onap.demo/vnfs/vcpe/$INSTALL_SCRIPT_VERSION/kea-sdnc-notify.conf
+wget $REPO_URL_BLOB/org.onap.demo/vnfs/vcpe/$INSTALL_SCRIPT_VERSION/v_dhcp_init.sh
+wget $REPO_URL_BLOB/org.onap.demo/vnfs/vcpe/$INSTALL_SCRIPT_VERSION/v_dhcp.sh
+chmod +x v_dhcp_init.sh
+chmod +x v_dhcp.sh
+mv v_dhcp.sh /etc/init.d
+update-rc.d v_dhcp.sh defaults
# Configure DHCP
+cp kea-dhcp4.conf /etc/kea-dhcp4-server.conf
mv kea-dhcp4.conf /etc/kea/kea-dhcp4.conf
mv kea-sdnc-notify.conf /etc/kea/kea-sdnc-notify.conf
sleep 1
@@ -96,3 +103,5 @@ then
echo "APT::Periodic::Unattended-Upgrade \"0\";" >> /etc/apt/apt.conf.d/10periodic
reboot
fi
+
+./v_dhcp_init.sh \ No newline at end of file