LEAS-2795 minio: PINS, ignore files, README

This commit is contained in:
Pavlo Ratushnyi
2026-11-14 13:51:30 +01:00
parent b1649c3ab4
commit 46166673cd
4 changed files with 47 additions and 3 deletions
+3
View File
@@ -0,0 +1,3 @@
.git
.gitea
out
+2
View File
@@ -1 +1,3 @@
/src/
/out/
/vezha/SOURCE
+7
View File
@@ -0,0 +1,7 @@
UPSTREAM_RELEASE=RELEASE.2025-09-07T16-13-09Z
UPSTREAM_COMMIT=07c3a429bfed433e49018cb0f78a52145d4bedeb
MODULE=github.com/minio/minio
MODULE_VERSION=v0.0.0-20250907161309-07c3a429bfed
MODULE_SUM=h1:deu0m9BiyqnMbGWfJi1PpVyotSXlDnTmRIme1cUXnxo=
GO_BUILDER=golang:1.27.2-trixie@sha256:47667934874913a449b96faa7ef4777fa285d9ec29126ee80ed61c45b7cccf0e
MC_IMAGE=git.vezha.io/para/minio-mc@sha256:eb4ea9884b77704230e2423e9004d2fa738dc272876b9cc41a297d29443b8780
+35 -3
View File
@@ -1,5 +1,37 @@
# vezha build recipe for minio/minio
This branch carries the build recipe for the container image `git.vezha.io/para/minio`.
The upstream source is minio/minio (AGPL-3.0), imported unmodified with all its tags.
The recipe is built up by the commits on the development branch and fast-forwarded here once it is green.
This branch builds the container image `git.vezha.io/para/minio` from the unmodified upstream source of minio/minio, which is archived upstream and no longer publishes images.
The repository is an imported copy of minio/minio with all its tags. The `vezha` branch is an orphan branch that holds only the recipe.
## Licence and source offer (AGPL-3.0)
The image ships the unmodified minio binary and the unmodified mc binary (copied from `git.vezha.io/para/minio-mc`, pinned in `PINS` as `MC_IMAGE`), both licensed under the GNU Affero General Public License v3.
The complete corresponding source of minio is the tag named in `PINS` (`UPSTREAM_RELEASE`) in this public repository:
`https://git.vezha.io/para/minio/src/tag/<UPSTREAM_RELEASE>`.
Each image carries `/licenses/LICENSE`, `/licenses/CREDITS` and `/licenses/SOURCE`, and the mc licence files and source offer under `/licenses/mc/`.
`SOURCE` names the upstream URL, the release and commit, the tag URL, the recipe commit, the builder image digest, the Go module version and sum, and the sha256 of the binary.
Nothing in this recipe patches the upstream source. A patch would make the binary a modified version and would need its own source offer.
## Files
- `PINS`: every pinned input. Builds refuse a missing, empty, duplicated or unknown key.
- `Dockerfile`: stages `pins`, `build`, `mc` and the final scratch image; no BuildKit-only syntax.
- `gates.sh`, `check-image.sh`, `smoke.sh`: the checks the workflow runs; `SOURCE.tmpl` is rendered into `/licenses/SOURCE`.
- `.gitea/workflows/release.yml`: verify on every push, publish on `vezha`.
## Image notes
The image is `FROM scratch`: the minio and mc binaries, the CA bundle, a root-only passwd and group, a world-writable `/tmp`, and the licence files.
It runs as root because the production data volume is root-owned; changing the user would break existing data.
It has `HEALTHCHECK ["/usr/bin/mc","ready","local"]`, `ENV PATH=/usr/bin` and `ENV MC_CONFIG_DIR=/tmp/.mc`, `ENTRYPOINT ["/usr/bin/minio"]`, `CMD ["server","/data"]`, `VOLUME /data` and `EXPOSE 9000`.
The upstream `docker-entrypoint.sh` and its `*_FILE` environment defaults (`MINIO_ROOT_USER_FILE`, `MINIO_ROOT_PASSWORD_FILE`, `MINIO_ACCESS_KEY_FILE`, `MINIO_SECRET_KEY_FILE`, `MINIO_KMS_SECRET_KEY_FILE`, `MINIO_CONFIG_ENV_FILE`) and the user switch variables are not carried: credentials are passed as `MINIO_ROOT_USER` and `MINIO_ROOT_PASSWORD`.
## Release procedure
A run on a branch other than `vezha` builds and verifies only and reads no secret. A run on `vezha` also publishes `git.vezha.io/para/minio:<tag>`, where the tag is `<lowercased UPSTREAM_RELEASE>-<first 12 of UPSTREAM_COMMIT>-r<first 8 of the recipe commit>`.
Tags are write-once, there is no `latest`, and consumers pin by digest. A run on `vezha` refuses an `MC_IMAGE` that is not a `git.vezha.io/para/minio-mc` digest published by the mc recipe. The run prints one line per image:
`PUBLISHED git.vezha.io/para/minio@sha256:<digest> tag=<tag> binary-sha256=<sha256>`
To bump a pin, edit `PINS` on a branch, let the verify run go green, and fast-forward `vezha`; the new commit publishes a new tag.
The publish step needs the repository secret `REGISTRY_TOKEN` (a Gitea token with the `write:package` scope) and optionally `REGISTRY_USER`.