aboutsummaryrefslogtreecommitdiffstats
path: root/sdc-os-chef/scripts/k8s/build_nsenter_exec.sh
diff options
context:
space:
mode:
authorAreli Fuss <af732p@att.com>2018-02-01 13:09:07 +0200
committerMichael Lando <ml636r@att.com>2018-02-06 17:57:29 +0000
commit471a29706bfc3ed50a6c66f96ee6575fc2e3087b (patch)
treecce1286f59676a2f7097cb34146cfa94940d65b4 /sdc-os-chef/scripts/k8s/build_nsenter_exec.sh
parent00c6ec7d386bd27c7752cf86e4692669e8b850ab (diff)
Add K8S deployment above Vagrant
Set deployment manifest files and scripts for deploy SDC over Kubernetes inside Vagrant Preparation for OOM integration Change-Id: I1f54b95067538f42d2d68fa3366b512dc9134f43 Issue-ID: SDC-907 Signed-off-by: Areli Fuss <af732p@att.com>
Diffstat (limited to 'sdc-os-chef/scripts/k8s/build_nsenter_exec.sh')
-rw-r--r--sdc-os-chef/scripts/k8s/build_nsenter_exec.sh22
1 files changed, 22 insertions, 0 deletions
diff --git a/sdc-os-chef/scripts/k8s/build_nsenter_exec.sh b/sdc-os-chef/scripts/k8s/build_nsenter_exec.sh
new file mode 100644
index 0000000000..7ee1196d98
--- /dev/null
+++ b/sdc-os-chef/scripts/k8s/build_nsenter_exec.sh
@@ -0,0 +1,22 @@
+# Ubuntu 14.04 don't have nsenter - the straight forward way required me to install build tools and etc.
+# I preferred to keep the system clean and install nsenter in a container and then copy the command to the host
+# Note - its also possible to run nsenter from a container (didn't tried) https://github.com/jpetazzo/nsenter
+
+# start a container
+docker run --name nsenter -it ubuntu:14.04 bash
+
+## in the docker
+apt-get update
+apt-get install git build-essential libncurses5-dev libslang2-dev gettext zlib1g-dev libselinux1-dev debhelper lsb-release pkg-config po-debconf autoconf automake autopoint libtool bison
+
+git clone git://git.kernel.org/pub/scm/utils/util-linux/util-linux.git util-linux
+cd util-linux/
+
+./autogen.sh
+./configure --without-python --disable-all-programs --enable-nsenter
+make
+
+## from different shell - on the host
+echo "[Action requires] From different shell on the host run the following:"
+docker cp nsenter:/util-linux/nsenter /usr/local/bin/
+docker cp nsenter:/util-linux/bash-completion/nsenter /etc/bash_completion.d/nsenter \ No newline at end of file