diff --git a/crane/README.md b/crane/README.md new file mode 100644 index 0000000..c9d8d52 --- /dev/null +++ b/crane/README.md @@ -0,0 +1,3 @@ +# crane + +The [crane](https://gitea.elara.ws/Elara6331/-/packages/container/crane/latest) image contains Google's [crane](https://github.com/google/go-containerregistry/tree/main/cmd/crane) project. diff --git a/crane/build.sh b/crane/build.sh new file mode 100755 index 0000000..57fa3e1 --- /dev/null +++ b/crane/build.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +set -e + +# Clone go-containerregistry and enter crane's directory +git clone --depth=1 https://github.com/google/go-containerregistry.git +pushd go-containerregistry/cmd/crane + +# Build and publish the image +KO_DOCKER_REPO=gitea.elara.ws/elara6331 \ +KO_DEFAULTBASEIMAGE=gitea.elara.ws/elara6331/busybox \ +ko build -B \ + --platform=linux/amd64,linux/arm64,linux/riscv64 \ + --sbom=none + +# Leave crane's directory +popd