src | ||
.gitignore | ||
build-image.sh | ||
LICENSE | ||
README.md |
gen-alpine-oci
Simple tool to generate OCI container build files for Alpine Linux locally without relying on container registries. Solves the bootstrap problem.
Requirements
- curl
- go
- gpg
- Ability to reach an Alpine Linux mirror containing release manifest and artifacts
Usage
Run build-image.sh
to retrieve/generate build files for the latest stable version of Alpine Linux for x86_64. Pass -h
to see additional command-line options.
How it works
This tool builds a small Go application that pulls the latest-releases.yaml manifest from an Alpine Linux's mirror and returns the URL of the rootfs tarball. This tarball and it's corresponding signature are then downloaded and verified against the release signing key. If the file download and verification are successful, a Containerfile
is generated. This Containerfile and it's corresponding artifacts are copied to alpine-ct/
in the current directory. The generated Containerfile
is functionally identical to the upstream variant, but the image hashes will differ.