X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=docker%2FNG-UI%2FDockerfile;h=628e3daf3b4b1e1d978ed2b12afd572b1e87a1fe;hb=ecc48d92ff04fceca0b31c65a294cfbe7091056b;hp=6e9e79d0f9bc01fb48edb5ec03074f2cd26a3f89;hpb=b147d7129db4f7cae26a31230af184c958b20683;p=osm%2Fdevops.git diff --git a/docker/NG-UI/Dockerfile b/docker/NG-UI/Dockerfile index 6e9e79d0..628e3daf 100644 --- a/docker/NG-UI/Dockerfile +++ b/docker/NG-UI/Dockerfile @@ -15,7 +15,7 @@ # limitations under the License. ####################################################################################### -FROM ubuntu:20.04 as INSTALL +FROM ubuntu:22.04 as INSTALL ARG APT_PROXY RUN if [ ! -z $APT_PROXY ] ; then \ @@ -25,17 +25,18 @@ RUN if [ ! -z $APT_PROXY ] ; then \ RUN DEBIAN_FRONTEND=noninteractive apt-get --yes update && \ DEBIAN_FRONTEND=noninteractive apt-get --yes install \ - apt-transport-https=2.0.* \ - curl=7.68.* \ + apt-transport-https=2.4.* \ + curl=7.81.* \ gnupg2=2.2.* \ nginx=1.18.* \ software-properties-common=0.99.* \ - xz-utils=5.2.* + xz-utils=5.2.* \ + && rm -rf /var/lib/apt/lists/* RUN curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \ - echo "deb https://deb.nodesource.com/node_10.x focal main" | tee -a /etc/apt/sources.list.d/nodesource.list && \ + echo "deb https://deb.nodesource.com/node_14.x jammy main" | tee -a /etc/apt/sources.list.d/nodesource.list && \ DEBIAN_FRONTEND=noninteractive apt-get update && \ - DEBIAN_FRONTEND=noninteractive apt-get install -y nodejs=10.24.* + DEBIAN_FRONTEND=noninteractive apt-get install -y nodejs ARG OSM_NGUI_URL @@ -49,7 +50,7 @@ RUN npm install RUN npm run build ####################################################################################### -FROM ubuntu:20.04 AS FINAL +FROM ubuntu:22.04 AS FINAL ARG APT_PROXY RUN if [ ! -z $APT_PROXY ] ; then \ @@ -62,17 +63,11 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get --yes update && \ nginx=1.18.* && \ rm -rf /var/lib/apt/lists/* +RUN rm -f /etc/apt/apt.conf.d/proxy.conf + # Removing the Nginx default page. RUN rm -rf /usr/share/nginx/html/* -# Creating the user for the app -RUN groupadd -g 1000 appuser && \ - useradd -u 1000 -g 1000 -d /usr appuser && \ - chown -R appuser:appuser /usr /var/lib/nginx /var/log/nginx /etc/nginx /run - -# Changing the security context -USER appuser - # Copying Nginx configuration COPY --from=INSTALL /usr/share/osm-ngui/nginx/nginx.conf /etc/nginx/sites-available/default