forked from mtusi2026/mtusi2026lab6
20 lines
849 B
Docker
20 lines
849 B
Docker
# Local MinIO Client (mc) from the official GitHub release binary (pinned).
|
|
# Fallback when docker.io/minio/mc cannot be pulled.
|
|
FROM ubuntu:24.04
|
|
|
|
ARG MC_VERSION=RELEASE.2025-04-16T18-13-26Z
|
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
ca-certificates curl \
|
|
&& curl -fsSL -o /tmp/mc.bin \
|
|
"https://github.com/minio/mc/releases/download/${MC_VERSION}/mc.linux-amd64.${MC_VERSION}" \
|
|
&& curl -fsSL -o /tmp/mc.sha256sum \
|
|
"https://github.com/minio/mc/releases/download/${MC_VERSION}/mc.linux-amd64.${MC_VERSION}.sha256sum" \
|
|
&& expected="$(awk '{print $1}' /tmp/mc.sha256sum)" \
|
|
&& echo "${expected} /tmp/mc.bin" | sha256sum -c - \
|
|
&& install -m 0755 /tmp/mc.bin /usr/local/bin/mc \
|
|
&& rm -f /tmp/mc.bin /tmp/mc.sha256sum \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
ENTRYPOINT ["mc"]
|