diff options
author | Sudhakar Reddy <Sudhakar.Reddy@amdocs.com> | 2019-03-09 04:26:05 +0000 |
---|---|---|
committer | Sudhakar Reddy <Sudhakar.Reddy@amdocs.com> | 2019-03-09 04:39:43 +0000 |
commit | 658602b4808bd093b75adb6a151982a7b44c7f0a (patch) | |
tree | e26a6118331ad163e23e78842d55466e8d62d0e6 | |
parent | 71816fa7c8eeeab52db7945ec3b319817d6a7eb9 (diff) |
Run multicloud-azure docker as non-root user
Change-Id: I4e5f13a1794bf1910ed485a86fa156cb226be7c1
Issue-ID: MULTICLOUD-498
Signed-off-by: Sudhakar Reddy <Sudhakar.Reddy@amdocs.com>
-rw-r--r-- | azure/docker/Dockerfile | 7 | ||||
-rwxr-xr-x[-rw-r--r--] | azure/docker/build_image.sh | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | azure/docker/docker-entrypoint.sh | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | azure/docker/instance-config.sh | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | azure/docker/instance-init.sh | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | azure/docker/instance-run.sh | 0 |
6 files changed, 6 insertions, 1 deletions
diff --git a/azure/docker/Dockerfile b/azure/docker/Dockerfile index cc2647e..9fd35da 100644 --- a/azure/docker/Dockerfile +++ b/azure/docker/Dockerfile @@ -18,6 +18,7 @@ RUN apt-get update && \ apt-get install -y wget RUN apt-get install -y python-dev gcc libffi-dev libssl-dev make +RUN groupadd -r onap && useradd -r -g onap onap # ARIA orchestrator addition RUN pip install -U pip setuptools COPY /aria/ /tmp/ @@ -48,8 +49,12 @@ RUN cd /opt/ && \ wget -q -O multicloud-azure.zip 'https://nexus.onap.org/service/local/artifact/maven/redirect?r=snapshots&g=org.onap.multicloud.azure&a=multicloud-azure&v=LATEST&e=zip' && \ unzip multicloud-azure.zip && \ rm -rf multicloud-azure.zip && \ - pip install -r multicloud_azure/requirements.txt + pip install -r multicloud_azure/requirements.txt && \ + chown onap:onap /opt/multicloud_azure -R + +RUN mkdir /home/onap && chown onap:onap /home/onap -R WORKDIR /opt RUN chmod +x multicloud_azure/docker/*.sh && chmod +x multicloud_azure/*.sh +USER onap ENTRYPOINT multicloud_azure/docker/docker-entrypoint.sh diff --git a/azure/docker/build_image.sh b/azure/docker/build_image.sh index 582d736..582d736 100644..100755 --- a/azure/docker/build_image.sh +++ b/azure/docker/build_image.sh diff --git a/azure/docker/docker-entrypoint.sh b/azure/docker/docker-entrypoint.sh index 26219d2..26219d2 100644..100755 --- a/azure/docker/docker-entrypoint.sh +++ b/azure/docker/docker-entrypoint.sh diff --git a/azure/docker/instance-config.sh b/azure/docker/instance-config.sh index f3b98b0..f3b98b0 100644..100755 --- a/azure/docker/instance-config.sh +++ b/azure/docker/instance-config.sh diff --git a/azure/docker/instance-init.sh b/azure/docker/instance-init.sh index 304bdd5..304bdd5 100644..100755 --- a/azure/docker/instance-init.sh +++ b/azure/docker/instance-init.sh diff --git a/azure/docker/instance-run.sh b/azure/docker/instance-run.sh index 10fd81e..10fd81e 100644..100755 --- a/azure/docker/instance-run.sh +++ b/azure/docker/instance-run.sh |