mirror of
https://tangled.org/evan.jarrett.net/at-container-registry
synced 2026-09-19 00:34:16 +00:00
60 lines
1.5 KiB
YAML
60 lines
1.5 KiB
YAML
# ATCR Release Pipeline for Tangled.org
|
|
# Triggers on version tags and builds cross-platform binaries using buildah
|
|
|
|
when:
|
|
- event: ["manual"]
|
|
# TODO: Trigger only on version tags (v1.0.0, v2.1.3, etc.)
|
|
branch: ["main"]
|
|
|
|
engine: "nixery"
|
|
|
|
dependencies:
|
|
nixpkgs:
|
|
- buildah
|
|
- chroot
|
|
|
|
environment:
|
|
IMAGE_REGISTRY: atcr.io
|
|
IMAGE_USER: evan.jarrett.net
|
|
|
|
steps:
|
|
- name: Setup build environment
|
|
command: |
|
|
if ! grep -q "^root:" /etc/passwd 2>/dev/null; then
|
|
echo "root:x:0:0:root:/root:/bin/sh" >> /etc/passwd
|
|
fi
|
|
|
|
- name: Login to registry
|
|
command: |
|
|
echo "${APP_PASSWORD}" | buildah login \
|
|
--storage-driver vfs \
|
|
-u "${IMAGE_USER}" \
|
|
--password-stdin \
|
|
${IMAGE_REGISTRY}
|
|
|
|
- name: Build and push AppView image
|
|
command: |
|
|
buildah bud \
|
|
--storage-driver vfs \
|
|
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-appview:${TAG} \
|
|
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-appview:latest \
|
|
--file ./Dockerfile.appview \
|
|
.
|
|
|
|
buildah push \
|
|
--storage-driver vfs \
|
|
${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-appview:latest
|
|
|
|
- name: Build and push Hold image
|
|
command: |
|
|
buildah bud \
|
|
--storage-driver vfs \
|
|
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-hold:${TAG} \
|
|
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-hold:latest \
|
|
--file ./Dockerfile.hold \
|
|
.
|
|
|
|
buildah push \
|
|
--storage-driver vfs \
|
|
${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-hold:latest
|