From 1e9b3cde27bc28e5a43f5fe1a9a29b3a2b952b26 Mon Sep 17 00:00:00 2001 From: Erik M Jacobs Date: Wed, 26 Apr 2023 14:06:14 -0400 Subject: [PATCH] s2i-built containerfile --- Containerfile | 14 ++++++++++++++ app.py => app-src/app.py | 0 gunicorn_config.py => app-src/gunicorn_config.py | 0 requirements.txt => app-src/requirements.txt | 0 4 files changed, 14 insertions(+) create mode 100644 Containerfile rename app.py => app-src/app.py (100%) rename gunicorn_config.py => app-src/gunicorn_config.py (100%) rename requirements.txt => app-src/requirements.txt (100%) diff --git a/Containerfile b/Containerfile new file mode 100644 index 0000000..0ca56ed --- /dev/null +++ b/Containerfile @@ -0,0 +1,14 @@ +FROM registry.access.redhat.com/ubi8/python-39 + +# Add application sources to a directory that the assemble script expects them +# and set permissions so that the container runs without root access +USER 0 +ADD app-src /tmp/src +RUN /usr/bin/fix-permissions /tmp/src +USER 1001 + +# Install the dependencies +RUN /usr/libexec/s2i/assemble + +# Set the default command for the resulting image +CMD /usr/libexec/s2i/run \ No newline at end of file diff --git a/app.py b/app-src/app.py similarity index 100% rename from app.py rename to app-src/app.py diff --git a/gunicorn_config.py b/app-src/gunicorn_config.py similarity index 100% rename from gunicorn_config.py rename to app-src/gunicorn_config.py diff --git a/requirements.txt b/app-src/requirements.txt similarity index 100% rename from requirements.txt rename to app-src/requirements.txt