From 5e3913f5666540f97f096295b0a5ee79310946ce Mon Sep 17 00:00:00 2001 From: H0llyW00dzZ Date: Tue, 14 Nov 2023 05:27:45 +0700 Subject: [PATCH] Fix & Feat CI / CD Docker Builder [+] fix(docker-without-tag.yml): fix typo in DockerFile path for building reverse proxy image [+] feat(docker-without-tag.yml): add caching of Go dependencies for reverse proxy build --- .github/workflows/docker-without-tag.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docker-without-tag.yml b/.github/workflows/docker-without-tag.yml index b937e3c8c73..ab46037b695 100644 --- a/.github/workflows/docker-without-tag.yml +++ b/.github/workflows/docker-without-tag.yml @@ -56,6 +56,17 @@ jobs: env: NODE_VERSION: 18 working-directory: ChatGPT-Next-Web/go-reverse-proxy + + - + name: Cache Go dependencies + if: ${{ github.event.inputs.build_reverse_proxy == 'yes' }} + uses: actions/cache@v3 + with: + path: ChatGPT-Next-Web/go-reverse-proxy + key: ${{ runner.os }}-go-${{ hashFiles('ChatGPT-Next-Web/go-reverse-proxy/go.sum') }} + restore-keys: | + ${{ runner.os }}-go- + - name: Log in to GitHub Container Registry uses: docker/login-action@v2 @@ -87,7 +98,7 @@ jobs: if: ${{ github.event.inputs.build_reverse_proxy == 'yes' }} uses: docker/build-push-action@v4 with: - context: ./ChatGPT-Next-Web/go-reverse-proxy/DockerFiles + context: ./ChatGPT-Next-Web/go-reverse-proxy/DockerFile platforms: linux/amd64,linux/arm64 push: true tags: ghcr.io/h0llyw00dzz/chatgpt-next-web:${{ github.event.inputs.go_reverse_proxy_tag }}