mirror of
https://github.com/zizmorcore/zizmor.git
synced 2025-12-23 08:47:33 +00:00
ci: convert Dockerfile to Wolfi (#667)
This commit is contained in:
parent
aeef8f6ebf
commit
a32d8bde36
1 changed files with 11 additions and 23 deletions
34
Dockerfile
34
Dockerfile
|
|
@ -1,30 +1,18 @@
|
||||||
FROM python:3.13-slim-bullseye AS build
|
|
||||||
|
|
||||||
LABEL org.opencontainers.image.source=https://github.com/woodruffw/zizmor
|
|
||||||
|
|
||||||
# Zizmor version to install (set as an argument to pair with zizmor releases)
|
|
||||||
ARG ZIZMOR_VERSION
|
|
||||||
|
|
||||||
ENV PYTHONUNBUFFERED=1 \
|
|
||||||
PIP_NO_CACHE_DIR=1 \
|
|
||||||
PIP_DISABLE_PIP_VERSION_CHECK=1
|
|
||||||
|
|
||||||
RUN set -eux && \
|
|
||||||
apt-get update && \
|
|
||||||
apt-get clean && \
|
|
||||||
rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
RUN pip install zizmor==${ZIZMOR_VERSION} && \
|
|
||||||
which zizmor
|
|
||||||
|
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
# Runtime image
|
# Runtime image
|
||||||
# ------------------------------------------------------------------------------
|
# ------------------------------------------------------------------------------
|
||||||
|
|
||||||
FROM debian:bullseye-slim
|
FROM cgr.dev/chainguard/wolfi-base:latest
|
||||||
|
|
||||||
# Copy necessary files from build stage
|
# Wolfi zizmor version to install
|
||||||
COPY --from=build /usr/local/bin/zizmor /app/zizmor
|
# https://edu.chainguard.dev/open-source/wolfi/apk-version-selection/
|
||||||
|
# (set as an argument to pair with zizmor releases)
|
||||||
|
ARG ZIZMOR_VERSION
|
||||||
|
|
||||||
|
RUN set -eux && \
|
||||||
|
apk update && \
|
||||||
|
apk add zizmor=~${ZIZMOR_VERSION} && \
|
||||||
|
zizmor --version
|
||||||
|
|
||||||
# Set the entrypoint to zizmor
|
# Set the entrypoint to zizmor
|
||||||
ENTRYPOINT ["/app/zizmor"]
|
ENTRYPOINT ["/usr/bin/zizmor"]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue