-
Notifications
You must be signed in to change notification settings - Fork 48
89 lines (78 loc) · 2.69 KB
/
docker-publish.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
name: docker-publish
on: push
defaults:
run:
# Enable fail-fast behavior
shell: bash -e {0}
jobs:
rivet-local-binary-artifact-runner:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build rivet-local-binary-artifact-runner
run: |
GHCR_TAG="ghcr.io/rivet-gg/rivet-local-binary-artifact-runner:$(git rev-parse --short HEAD)"
docker build -t "$GHCR_TAG" -f infra/docker/rivet_local_binary_artifact_runner/Dockerfile .
docker push "$GHCR_TAG"
golang-migrate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build golang-migrate
run: |
GHCR_TAG="ghcr.io/rivet-gg/golang-migrate:$(git rev-parse --short HEAD)"
cd infra/docker/golang_migrate
docker build -t "$GHCR_TAG" .
docker push "$GHCR_TAG"
redis:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build redis
run: |
GHCR_TAG="ghcr.io/rivet-gg/redis:$(git rev-parse --short HEAD)"
cd infra/docker/redis
docker build -t "$GHCR_TAG" .
docker push "$GHCR_TAG"
# HACK: Disabled by default because of how long it takes to rebuild.
# apache-traffic-server:
# runs-on: ubuntu-latest
# steps:
# - name: Install Nix
# run: |
# curl -L https://nixos.org/nix/install | sh
# . /home/runner/.nix-profile/etc/profile.d/nix.sh
# - uses: actions/checkout@v2
# - name: Login to GitHub Container Registry
# uses: docker/login-action@v2
# with:
# registry: ghcr.io
# username: ${{github.actor}}
# password: ${{secrets.GITHUB_TOKEN}}
# - name: Build apache-traffic-server
# run: |
# # Build
# . /home/runner/.nix-profile/etc/profile.d/nix.sh
# cd infra/docker/traffic_server
# nix-build docker.nix --option system-features kvm
# docker load < result
# # Push
# GHCR_TAG="ghcr.io/rivet-gg/apache-traffic-server:$(git rev-parse --short HEAD)"
# echo "Tagging: $GHCR_TAG"
# docker tag apache-traffic-server:latest "$GHCR_TAG"
# docker push "$GHCR_TAG"