UNCLASSIFIED
Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Ironbank Containers
DIAT
AAP Python
Commits
a9752113
Commit
a9752113
authored
Aug 18, 2021
by
WingKwan Lau
Committed by
Jacob Rohlman
Aug 18, 2021
Browse files
Wingkwan.lau development patch 51101
parent
5d5be7ba
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
12 deletions
+7
-12
Dockerfile
Dockerfile
+7
-12
No files found.
Dockerfile
View file @
a9752113
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
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment