#
##############################################################################
FROM ubuntu:18.04
-RUN apt-get update && apt-get -y install curl ca-certificates wget
+RUN apt-get update && apt-get -y install ca-certificates wget
# often times out during LF jenkins build
+ARG USERNAME=ubuntu
+ARG USER_UID=1000
+ARG USER_GID=$USER_UID
+# Create the user
+RUN groupadd --gid $USER_GID $USERNAME \
+ && useradd --uid $USER_UID --gid $USER_GID -m $USERNAME \
+ && apt-get install -y sudo \
+ && echo $USERNAME ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/$USERNAME \
+ && chmod 0440 /etc/sudoers.d/$USERNAME
+
+USER $USERNAME
ARG TGT=/tmp/it-dep
-COPY . $TGT
+COPY --chown=$USERNAME:$USERNAME . $TGT
RUN ls -latr /tmp/it-dep
# Remove the smo-install as this one will be verified in another verify job
RUN $TGT/bin/verify-smo-install
## Quick Installation on existing kubernetes
* Ensure you have at least 20GB Memory, 6VCPU, 60GB of disk space.
-* Execute the following commands being logged as root:
```git clone --recursive "https://gerrit.o-ran-sc.org/r/it/dep"```
cd /tmp
wget https://get.helm.sh/chartmuseum-v0.13.1-linux-amd64.tar.gz
tar xvfz chartmuseum-v0.13.1-linux-amd64.tar.gz
-mv /tmp/linux-amd64/chartmuseum /usr/local/bin/chartmuseum
+sudo mv /tmp/linux-amd64/chartmuseum /usr/local/bin/chartmuseum
chartmuseum --port=18080 --storage="local" --storage-local-rootdir=$SCRIPT_PATH"/../../../chartstorage" &
# ===================================================================
#
###
-
#Helm package
+cd /tmp
wget https://get.helm.sh/helm-v3.5.4-linux-amd64.tar.gz
-mv helm-v3.5.4-linux-amd64.tar.gz /tmp/helm-v3.5.4-linux-amd64.tar.gz
-cd /tmp/
tar xvfz /tmp/helm-v3.5.4-linux-amd64.tar.gz
-mv linux-amd64/helm /usr/local/bin/helm
-apt-get install git -y
+sudo mv linux-amd64/helm /usr/local/bin/helm
+sudo apt-get install git -y
echo "Checking HELM ..."
SCRIPT_PATH=$(dirname "$SCRIPT")
cd $SCRIPT_PATH
-apt-get install make -y
+sudo apt-get install make -y
helm plugin install ../../onap_oom/kubernetes/helm/plugins/undeploy/
helm plugin install ../../onap_oom/kubernetes/helm/plugins/deploy/
SCRIPT_PATH=$(dirname "$SCRIPT")
cd $SCRIPT_PATH
-apt-get install make -y
+sudo apt-get install make -y
echo '### Building ORAN part ###'
(cd ../../oran_oom && make all)
SCRIPT_PATH=$(dirname "$SCRIPT")
cd $SCRIPT_PATH
-apt-get install make -y
+sudo apt-get install make -y
echo '### Building ORAN tests part ###'
(cd ../../tests_oom && make all)