Files
debian-latest/Dockerfile
Renovate Bot 6e02fef8df
All checks were successful
Build Docker Image / build-docker (push) Successful in 27m59s
chore(deps): update debian:trixie-slim docker digest to 66b37a5
2025-10-21 10:43:38 +00:00

70 lines
1.7 KiB
Docker

# =========================
# Stage 1: Builder
# =========================
FROM debian:trixie-slim@sha256:66b37a5078a77098bfc80175fb5eb881a3196809242fd295b25502854e12cbec AS builder
ENV DEBIAN_FRONTEND=noninteractive \
LANG=C.UTF-8
# Install build dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
curl \
git \
bash \
openssh-client \
ca-certificates \
procps \
iproute2 \
netcat-traditional \
unzip \
iputils-ping \
python3 \
python3-venv \
build-essential \
zlib1g-dev \
libffi-dev \
libssl-dev \
ruby-full \
&& rm -rf /var/lib/apt/lists/*
# Install Node.js 22
RUN curl -fsSL https://deb.nodesource.com/setup_22.x | bash - \
&& apt-get install -y nodejs \
&& npm install -g npm \
&& rm -rf /var/lib/apt/lists/*
# Create Python virtual environment for Ansible
RUN python3 -m venv /opt/venv \
&& /opt/venv/bin/pip install --no-cache-dir --upgrade pip ansible
# =========================
# Stage 2: Final runtime image
# =========================
FROM debian:trixie-slim@sha256:66b37a5078a77098bfc80175fb5eb881a3196809242fd295b25502854e12cbec
ENV DEBIAN_FRONTEND=noninteractive \
LANG=C.UTF-8 \
PATH=/opt/venv/bin:$PATH
# Install runtime dependencies only
RUN apt-get update && apt-get install -y --no-install-recommends \
bash \
openssh-client \
ca-certificates \
iputils-ping \
python3 \
python3-venv \
ruby-full \
nodejs \
git \
&& rm -rf /var/lib/apt/lists/*
# Copy built Python venv from builder
COPY --from=builder /opt/venv /opt/venv
# Set working directory
WORKDIR /workspace
# Default shell
SHELL ["/bin/bash", "-c"]