tangled
alpha
login
or
join now
evan.jarrett.net
/
at-container-registry
66
fork
atom
A container registry that uses the AT Protocol for manifest storage and S3 for blob storage.
atcr.io
docker
container
atproto
go
66
fork
atom
overview
issues
1
pulls
pipelines
update workflow for buildah
evan.jarrett.net
4 months ago
d7eba25f
7a005023
verified
This commit was signed with the committer's
known signature
.
evan.jarrett.net
SSH Key Fingerprint:
SHA256:bznk0uVPp7XFOl67P0uTM1pCjf2A4ojeP/lsUE7uauQ=
1/1
tests.yml
success
1m 10s
+38
-34
1 changed file
expand all
collapse all
unified
split
.tangled
workflows
release.yml
+38
-34
.tangled/workflows/release.yml
···
1
1
# ATCR Release Pipeline for Tangled.org
2
2
-
# Triggers on version tags and builds cross-platform binaries using GoReleaser
2
2
+
# Triggers on version tags and builds cross-platform binaries using buildah
3
3
4
4
when:
5
5
- event: ["manual"]
···
10
10
11
11
dependencies:
12
12
nixpkgs:
13
13
-
- git
14
14
-
- go
15
15
-
#- goreleaser
16
16
-
- podman
13
13
+
- buildah
14
14
+
- chroot
17
15
18
18
-
steps:
19
19
-
- name: Fetch git tags
20
20
-
command: git fetch --tags --force
16
16
+
environment:
17
17
+
IMAGE_REGISTRY: atcr.io
18
18
+
IMAGE_USER: evan.jarrett.net
21
19
22
22
-
- name: Checkout tag for current commit
20
20
+
steps:
21
21
+
- name: Setup build environment
23
22
command: |
24
24
-
CURRENT_COMMIT=$(git rev-parse HEAD)
25
25
-
export TAG=$(git tag --points-at $CURRENT_COMMIT --sort=-version:refname | head -n1)
26
26
-
if [ -z "$TAG" ]; then
27
27
-
echo "Error: No tag found for commit $CURRENT_COMMIT"
28
28
-
exit 1
23
23
+
if ! grep -q "^root:" /etc/passwd 2>/dev/null; then
24
24
+
echo "root:x:0:0:root:/root:/bin/sh" >> /etc/passwd
29
25
fi
30
30
-
echo "Found tag $TAG for commit $CURRENT_COMMIT"
31
31
-
git checkout $TAG
32
26
33
33
-
- name: Build AppView Docker image
27
27
+
- name: Login to registry
34
28
command: |
35
35
-
TAG=$(git describe --tags --exact-match 2>/dev/null || git tag --points-at HEAD | head -n1)
36
36
-
podman login atcr.io -u evan.jarrett.net -p ${APP_PASSWORD}
37
37
-
podman build -f Dockerfile.appview -t atcr.io/evan.jarrett.net/atcr-appview:${TAG} .
38
38
-
podman push atcr.io/evan.jarrett.net/atcr-appview:${TAG}
29
29
+
echo "${APP_PASSWORD}" | buildah login \
30
30
+
--storage-driver vfs \
31
31
+
-u "${IMAGE_USER}" \
32
32
+
--password-stdin \
33
33
+
${IMAGE_REGISTRY}
39
34
40
40
-
- name: Build Hold Docker image
35
35
+
- name: Build and push AppView image
41
36
command: |
42
42
-
TAG=$(git describe --tags --exact-match 2>/dev/null || git tag --points-at HEAD | head -n1)
43
43
-
podman login atcr.io -u evan.jarrett.net -p ${APP_PASSWORD}
44
44
-
podman build -f Dockerfile.hold -t atcr.io/evan.jarrett.net/atcr-hold:${TAG} .
45
45
-
podman push atcr.io/evan.jarrett.net/atcr-hold:${TAG}
46
46
-
47
47
-
# disable for now
48
48
-
# - name: Tidy Go modules
49
49
-
# command: go mod tidy
37
37
+
buildah bud \
38
38
+
--storage-driver vfs \
39
39
+
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-appview:${TAG} \
40
40
+
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-appview:latest \
41
41
+
--file ./Dockerfile.appview \
42
42
+
.
50
43
51
51
-
# - name: Install Goat
52
52
-
# command: go install github.com/bluesky-social/goat@latest
44
44
+
buildah push \
45
45
+
--storage-driver vfs \
46
46
+
${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-appview:latest
53
47
54
54
-
# - name: Run GoReleaser
55
55
-
# command: goreleaser release --clean
48
48
+
- name: Build and push Hold image
49
49
+
command: |
50
50
+
buildah bud \
51
51
+
--storage-driver vfs \
52
52
+
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-hold:${TAG} \
53
53
+
--tag ${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-hold:latest \
54
54
+
--file ./Dockerfile.hold \
55
55
+
.
56
56
+
57
57
+
buildah push \
58
58
+
--storage-driver vfs \
59
59
+
${IMAGE_REGISTRY}/${IMAGE_USER}/atcr-hold:latest