From ac2cc89b4c04916a8ce540b0723e1e6ea6222e0b Mon Sep 17 00:00:00 2001 From: viet nguyen Date: Sat, 9 Dec 2023 19:03:02 -0800 Subject: [PATCH 1/3] fix: build break --- .github/workflows/nodejs.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 9d4c773a..7504e5af 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -13,15 +13,15 @@ on: jobs: # deploy to staging by commiting to api-server-deployment repo deploy-staging: - runs-on: ubuntu-latest - if: github.ref_name == 'develop' + runs-on: ubuntu-22.04 + # if: github.ref_name == 'develop' # Temporarily disable this needs: docker steps: - name: 'Checkout Project' uses: 'actions/checkout@v4' with: fetch-depth: 1 - repository: 'api-server-deployment' + repository: 'openbeta/api-server-deployment' token: ${{ secrets.GH_DEPLOYMENT_REPO_TOKEN }} - uses: imranismail/setup-kustomize@v2 - run: | @@ -40,7 +40,7 @@ jobs: # deploy to prod by commiting to api-server-deployment repo deploy-prod: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 if: startsWith(github.ref, 'refs/tags/v') needs: docker steps: @@ -48,7 +48,7 @@ jobs: uses: 'actions/checkout@v4' with: fetch-depth: 1 - repository: 'api-server-deployment' + repository: 'openbeta/api-server-deployment' token: ${{ secrets.GH_DEPLOYMENT_REPO_TOKEN }} - uses: imranismail/setup-kustomize@v2 - run: | @@ -66,7 +66,7 @@ jobs: # build docker image and push to registry docker: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 needs: test steps: - name: 'Checkout Project' @@ -106,7 +106,7 @@ jobs: # setup basic machine to run all kinds of tests: lint, unit, integration, types test: - runs-on: 'ubuntu-latest' + runs-on: 'ubuntu-22.04' steps: - name: 'Checkout Project' uses: 'actions/checkout@v3' From 69836cef3e8cc4f4f6d87798d90bed5ae4e6273d Mon Sep 17 00:00:00 2001 From: viet nguyen Date: Sat, 9 Dec 2023 19:40:46 -0800 Subject: [PATCH 2/3] don't push docker img on pr --- .github/workflows/nodejs.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 7504e5af..95989644 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -14,7 +14,7 @@ jobs: # deploy to staging by commiting to api-server-deployment repo deploy-staging: runs-on: ubuntu-22.04 - # if: github.ref_name == 'develop' # Temporarily disable this + # if: github.ref_name == 'develop' needs: docker steps: - name: 'Checkout Project' @@ -67,6 +67,7 @@ jobs: # build docker image and push to registry docker: runs-on: ubuntu-22.04 + if: github.event_name != 'pull_request' needs: test steps: - name: 'Checkout Project' From 39c77bc78ae7b425f4bbb8d64f5236c1e7f788d0 Mon Sep 17 00:00:00 2001 From: viet nguyen Date: Sat, 9 Dec 2023 19:44:42 -0800 Subject: [PATCH 3/3] don't push docker img on pr --- .github/workflows/nodejs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 95989644..93b8f37a 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -14,7 +14,7 @@ jobs: # deploy to staging by commiting to api-server-deployment repo deploy-staging: runs-on: ubuntu-22.04 - # if: github.ref_name == 'develop' + if: github.ref_name == 'develop' needs: docker steps: - name: 'Checkout Project'