From 8b0ce3bdbc7d510f28358be2770e1757359a9ccd Mon Sep 17 00:00:00 2001 From: Zibi Mandziejewicz Date: Tue, 1 Apr 2025 16:44:41 +0700 Subject: [PATCH 1/2] feat: github ci image build --- .github/workflows/ci.yaml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 .github/workflows/ci.yaml diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 0000000..35685f2 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,22 @@ +name: ci + +on: + push: + +jobs: + buildx: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + with: + platforms: linux/amd64,linux/arm64 + - name: Run Skaffold pipeline as action + uses: hiberbee/github-action-skaffold@1.19.0 + with: + skaffold-version: 2.14.1 + command: build \ No newline at end of file From d55b8b2d3c2d65422957f9782a0de4549f841936 Mon Sep 17 00:00:00 2001 From: Zibi Mandziejewicz Date: Tue, 1 Apr 2025 16:44:41 +0700 Subject: [PATCH 2/2] chore: add GHCR login --- .github/workflows/ci.yaml | 19 ++++++++++++++++--- .gitignore | 1 + go.mod | 1 + go.sum | 4 ++-- 4 files changed, 20 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 35685f2..5ed940d 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -4,7 +4,8 @@ on: push: jobs: - buildx: + image-build: + name: Image Build runs-on: ubuntu-latest steps: - name: Checkout @@ -15,8 +16,20 @@ jobs: uses: docker/setup-buildx-action@v3 with: platforms: linux/amd64,linux/arm64 - - name: Run Skaffold pipeline as action + - name: Login to GitHub Container Registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Build images uses: hiberbee/github-action-skaffold@1.19.0 with: skaffold-version: 2.14.1 - command: build \ No newline at end of file + command: build + file-output: build/images.json + - name: Archive image tags + uses: actions/upload-artifact@v4 + with: + name: images + path: build/images.json \ No newline at end of file diff --git a/.gitignore b/.gitignore index 420e19b..97a4997 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,7 @@ build/ go.work.sum coverage.xml +build.json # editor and IDE paraphernalia .idea/ diff --git a/go.mod b/go.mod index 8201c73..ebc4f9d 100644 --- a/go.mod +++ b/go.mod @@ -83,6 +83,7 @@ require ( golang.org/x/term v0.29.0 // indirect golang.org/x/text v0.22.0 // indirect golang.org/x/time v0.5.0 // indirect + golang.org/x/tools v0.30.0 // indirect gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20250218202821-56aae31c358a // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20250218202821-56aae31c358a // indirect diff --git a/go.sum b/go.sum index 7d21ab0..bc1eb91 100644 --- a/go.sum +++ b/go.sum @@ -253,8 +253,8 @@ golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roY golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d h1:vU5i/LfpvrRCpgM/VPfJLg5KjxD3E+hfT1SH+d9zLwg= -golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d/go.mod h1:aiJjzUbINMkxbQROHiO6hDPo2LHcIPhhQsa9DLh0yGk= +golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= +golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=