Add dynamic dependency args to dockerfile

Add makefile for automating build and push commands
This commit is contained in:
2024-02-28 13:29:20 -05:00
parent 2cc57c32b7
commit 173dc2d719
2 changed files with 22 additions and 2 deletions

View File

@@ -25,6 +25,9 @@ RUN python -m pip wheel \
# ==================================
FROM python:3.11-slim
ARG OPENTOFU_VERSION
ARG SEMAPHORE_VERSION
ENV SEMAPHORE_RUNNER_CONFIG_FILE /semaphore/config.json
COPY --from=build /build/wheels /tmp/wheels
@@ -37,8 +40,8 @@ RUN apt-get update --yes && \
curl \
gnupg && \
mkdir --parents /tmp/apt && \
curl -sSL -o /tmp/apt/opentofu.deb https://github.com/opentofu/opentofu/releases/download/v1.6.2/tofu_1.6.2_amd64.deb && \
curl -sSL -o /tmp/apt/semaphore.deb https://github.com/ansible-semaphore/semaphore/releases/download/v2.9.45/semaphore_2.9.45_linux_amd64.deb && \
curl -sSL -o /tmp/apt/opentofu.deb https://github.com/opentofu/opentofu/releases/download/v${OPENTOFU_VERSION}/tofu_${OPENTOFU_VERSION}_amd64.deb && \
curl -sSL -o /tmp/apt/semaphore.deb https://github.com/ansible-semaphore/semaphore/releases/download/v${SEMAPHORE_VERSION}/semaphore_${SEMAPHORE_VERSION}_linux_amd64.deb && \
apt-get install --yes /tmp/apt/*.deb && \
apt-get clean --yes && \
rm -rf /tmp/apt && \