File tree 4 files changed +94
-0
lines changed
actions/setup-docker-environment
4 files changed +94
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : " Setup Docker"
2
+
3
+ outputs :
4
+ sha_short :
5
+ description : " The short SHA used for image builds"
6
+ value : ${{ steps.vars.outputs.sha_short }}
7
+
8
+ runs :
9
+ using : " composite"
10
+ steps :
11
+ - name : Get Short SHA
12
+ id : vars
13
+ run : |
14
+ echo ::set-output name=sha_short::${GITHUB_SHA::7}
15
+ shell : bash
16
+
17
+ - name : Set up QEMU
18
+ uses : docker/setup-qemu-action@v1
19
+
20
+ - name : Set up Docker Buildx
21
+ uses : docker/setup-buildx-action@v1
22
+ with :
23
+ version : latest
24
+
25
+ # - name: Login to DockerHub
26
+ # if: ${{ github.ref == 'main' && github.event.pull_request.merged == true }}
27
+ # uses: docker/login-action@v1
28
+ # with:
29
+ # username: ${{ inputs.username }}
30
+ # password: ${{ inputs.password }}
Original file line number Diff line number Diff line change
1
+ name : Publish Canary Images
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ paths-ignore :
8
+ - .github/workflows/ci.yml
9
+ - .github/workflows/lock.yml
10
+ - " docs/**"
11
+ - " hack/**"
12
+ - " **.md"
13
+ - " .gitignore"
14
+ - " Makefile"
15
+
16
+ jobs :
17
+ build :
18
+ runs-on : ubuntu-latest
19
+ permissions :
20
+ contents : read
21
+ packages : write
22
+ name : Build and Publish Canary Images
23
+ env :
24
+ DOCKERHUB_USERNAME : ${{ secrets.DOCKER_USER }}
25
+ steps :
26
+ - name : Checkout
27
+ uses : actions/checkout@v3
28
+
29
+ - name : Setup Docker Environment
30
+ id : vars
31
+ uses : ./.github/actions/setup-docker-environment
32
+
33
+ - name : Login to GitHub Container Registry
34
+ uses : docker/login-action@v1
35
+ with :
36
+ registry : ghcr.io
37
+ username : ${{ github.actor }}
38
+ password : ${{ secrets.GITHUB_TOKEN }}
39
+
40
+ - name : Build and Push
41
+ uses : docker/build-push-action@v2
42
+ with :
43
+ file : Dockerfile
44
+ platforms : linux/amd64,linux/arm64
45
+ push : true
46
+ tags : |
47
+ ghcr.io/${{ github.repository }}:canary
48
+ cache-from : type=gha
49
+ cache-to : type=gha,mode=max
50
+
51
+ - name : Build and Push (debian stable-slim)
52
+ uses : docker/build-push-action@v2
53
+ with :
54
+ file : Dockerfile.debian
55
+ platforms : linux/amd64,linux/arm64
56
+ push : true
57
+ tags : |
58
+ ghcr.io/${{ github.repository }}-debian-stable-slim:canary
59
+ cache-from : type=gha
60
+ cache-to : type=gha,mode=max
Original file line number Diff line number Diff line change @@ -9,6 +9,8 @@ RUN make static-linux
9
9
10
10
FROM alpine:3.13
11
11
12
+ LABEL org.opencontainers.image.source https://github.com/helmfile/helmfile
13
+
12
14
RUN apk add --no-cache ca-certificates git bash curl jq
13
15
14
16
ARG HELM_VERSION="v3.7.2"
Original file line number Diff line number Diff line change @@ -15,6 +15,8 @@ RUN make static-linux
15
15
16
16
FROM debian:stable-slim
17
17
18
+ LABEL org.opencontainers.image.source https://github.com/helmfile/helmfile
19
+
18
20
RUN apt-get update \
19
21
&& apt-get install -y --no-install-recommends \
20
22
ca-certificates \
You can’t perform that action at this time.
0 commit comments