UNCLASSIFIED

Commit a9752113 authored by WingKwan Lau's avatar WingKwan Lau Committed by Jacob Rohlman
Browse files

Wingkwan.lau development patch 51101

parent 5d5be7ba
ARG BASE_REGISTRY=registry1.dso.mil ARG BASE_REGISTRY=registry1.dso.mil
ARG BASE_IMAGE=redhat/ubi/ubi8 ARG BASE_IMAGE=ironbank/redhat/ubi/ubi8
ARG BASE_TAG=8.4 ARG BASE_TAG=8.4
FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG} FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG} as build
# Set necessary environment variables for python and python development environment # Set necessary environment variables for python and python development environment
ARG APP_ROOT=/opt/app-root ARG APP_ROOT=/opt/app-root
...@@ -30,18 +30,17 @@ RUN chmod a+x /usr/bin/container-entrypoint && \ ...@@ -30,18 +30,17 @@ RUN chmod a+x /usr/bin/container-entrypoint && \
chmod a+x /usr/bin/generate-container-user && \ chmod a+x /usr/bin/generate-container-user && \
chmod a+x /usr/bin/py-enable chmod a+x /usr/bin/py-enable
# yum Updates
RUN yum update -y
# Install packages # Install packages
RUN INSTALL_PKGS="vim-enhanced rsync iputils bind-utils git python38 python38-devel python38-setuptools python38-pip gcc" && \ RUN INSTALL_PKGS="vim-enhanced rsync iputils bind-utils git python38 python38-devel python38-setuptools python38-pip" && \
yum -y update-minimal --setopt=tsflags=nodocs --security && \ yum -y update-minimal --setopt=tsflags=nodocs --security && \
yum -y --setopt=tsflags=nodocs install $INSTALL_PKGS && \ yum -y --setopt=tsflags=nodocs install $INSTALL_PKGS && \
yum -y remove vim-minimal && \ yum -y remove vim-minimal && \
rpm -V $INSTALL_PKGS && \ rpm -V $INSTALL_PKGS && \
yum -y clean all --enablerepo="*" yum -y clean all --enablerepo="*"
# yum Updates
RUN yum update -y
RUN yum update systemd-239-45.el8_4.2
# - Create a Python virtual environment for use by any application to avoid potential conflicts with Python packages # - Create a Python virtual environment for use by any application to avoid potential conflicts with Python packages
# preinstalled in the main Python installation. # preinstalled in the main Python installation.
RUN python$PYTHON_VERSION -m venv ${APP_ROOT} && /usr/bin/py-enable RUN python$PYTHON_VERSION -m venv ${APP_ROOT} && /usr/bin/py-enable
...@@ -60,8 +59,4 @@ RUN chmod g-s /usr/libexec/openssh/ssh-keysign ...@@ -60,8 +59,4 @@ RUN chmod g-s /usr/libexec/openssh/ssh-keysign
# set user to ensure image not running as root # set user to ensure image not running as root
USER 1001 USER 1001
ENTRYPOINT ["/usr/bin/container-entrypoint"] HEALTHCHECK NONE
HEALTHCHECK CMD python --version
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment