Skip to content

Commit

Permalink
Bump Python and action versions to fix main ci action work.
Browse files Browse the repository at this point in the history
Signed-off-by: Xun Jiang <[email protected]>
  • Loading branch information
blackpiglet committed Dec 18, 2024
1 parent 7e5760e commit 69d5be5
Showing 1 changed file with 22 additions and 18 deletions.
40 changes: 22 additions & 18 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
name: Main CI

on:
push:
# This change is for debug.
#push:
pull_request:
branches:
- 'main'
- 'release-**'
tags:
- '*'
#tags:
# - '*'

jobs:

Expand All @@ -16,35 +18,37 @@ jobs:
steps:

- name: Set up Go
uses: actions/setup-go@v2
uses: actions/setup-go@v5
with:
go-version: '1.22.8'
id: go
go-version-file: 'go.mod'

- name: Check out code into the Go module directory
uses: actions/checkout@v3
uses: actions/checkout@v4

# Fix issue of setup-gcloud
- run: |
sudo apt-get install python2.7
export CLOUDSDK_PYTHON="/usr/bin/python2"
sudo apt-get install python3
export CLOUDSDK_PYTHON="/usr/bin/python3"
- uses: google-github-actions/setup-gcloud@v0
- id: 'auth'
uses: google-github-actions/auth@v2
with:
version: '285.0.0'
service_account_key: ${{ secrets.GCS_SA_KEY }}
export_default_credentials: true
credentials_json: '${{ secrets.GCS_SA_KEY }}'

- name: 'set up GCloud SDK'
uses: google-github-actions/setup-gcloud@v2

- run: gcloud info

- name: Set up QEMU
id: qemu
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3
with:
platforms: all

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3
with:
version: latest

Expand All @@ -55,14 +59,14 @@ jobs:
run: make test

- name: Upload test coverage
uses: codecov/codecov-action@v2
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.out
verbose: true

# Use the JSON key in secret to login gcr.io
- uses: 'docker/login-action@v2'
- uses: 'docker/login-action@v3'
with:
registry: 'gcr.io' # or REGION.docker.pkg.dev
username: '_json_key'
Expand Down

0 comments on commit 69d5be5

Please sign in to comment.