X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=installers%2Finstall_lxd.sh;h=960531de07e3a92f4dbb5d4562ca1cb4b03961f3;hb=37d5a5f1213b462f065ef44229681c801ca7efe9;hp=7395c731d8b62e1a1b5c4d4ddda4ae4aef9f98dd;hpb=5671dce4ef9fd497721fe07376d77244d783867f;p=osm%2Fdevops.git diff --git a/installers/install_lxd.sh b/installers/install_lxd.sh index 7395c731..960531de 100755 --- a/installers/install_lxd.sh +++ b/installers/install_lxd.sh @@ -53,22 +53,16 @@ function install_lxd() { if [ -n "${OSM_DEFAULT_IF}" ]; then OSM_DEFAULT_IF=$(ip route list|awk '$1=="default" {print $5; exit}') [ -z "${OSM_DEFAULT_IF}" ] && OSM_DEFAULT_IF=$(route -n |awk '$1~/^0.0.0.0/ {print $8; exit}') - [ -z "${OSM_DEFAULT_IF}" ] && FATAL "Not possible to determine the interface with the default route 0.0.0.0" + [ -z "${OSM_DEFAULT_IF}" ] && FATAL_TRACK lxd "Not possible to determine the interface with the default route 0.0.0.0" fi DEFAULT_MTU=$(ip addr show ${OSM_DEFAULT_IF} | perl -ne 'if (/mtu\s(\d+)/) {print $1;}') OSM_DEFAULT_IP=`ip -o -4 a s ${OSM_DEFAULT_IF} |awk '{split($4,a,"/"); print a[1]; exit}'` - [ -z "$OSM_DEFAULT_IP" ] && FATAL "Not possible to determine the IP address of the interface with the default route" + [ -z "$OSM_DEFAULT_IP" ] && FATAL_TRACK lxd "Not possible to determine the IP address of the interface with the default route" # Configure LXD sudo usermod -a -G lxd `whoami` cat ${OSM_DEVOPS}/installers/lxd-preseed.conf | sed 's/^config: {}/config:\n core.https_address: '$OSM_DEFAULT_IP':8443/' | sg lxd -c "lxd init --preseed" sg lxd -c "lxd waitready" - sg lxd -c "lxc profile device set default eth0 mtu $DEFAULT_MTU" - sg lxd -c "lxc network set lxdbr0 bridge.mtu $DEFAULT_MTU" - # sudo systemctl stop lxd-bridge - # sudo systemctl --system daemon-reload - # sudo systemctl enable lxd-bridge - # sudo systemctl start lxd-bridge # Configure LXD to work behind a proxy if [ -n "${OSM_BEHIND_PROXY}" ] ; then