Skip to content

chore(ci): run the smoke tests on GKE #47

chore(ci): run the smoke tests on GKE

chore(ci): run the smoke tests on GKE #47

Workflow file for this run

name: Build
concurrency:
group: ${{ github.ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
on:
pull_request: {}
push:
branches:
- main
workflow_dispatch: {}
env:
SMOKE_PRODUCT_NAME: "kuma"
SMOKE_PRODUCT_VERSION: "2.9.2"
CI_TOOLS_DIR: "/home/runner/work/kuma-smoke/.ci_tools"
jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- name: make dev/tools
run: make dev/tools
- name: make check
run: make check
- name: golangci-lint
uses: golangci/golangci-lint-action@v6
with:
version: latest
args: --timeout=10m --verbose
skip-cache: true
build-test:
name: Build and test
timeout-minutes: 40
needs:
- check
runs-on: ubuntu-latest
strategy:
matrix:
envPlatform: ${{ fromJSON( github.event_name == 'workflow_dispatch' && '["kind", "gke"]' || '["kind"]' ) }}
fail-fast: false
if: ${{ !contains(github.event.pull_request.labels.*.name, 'ci/skip-test') }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- name: make dev/tools
run: |
make dev/tools
echo "${CI_TOOLS_DIR}/bin" >> $GITHUB_PATH
- name: make build
run: make build
- name: make run
env:
GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }}
GOOGLE_LOCATION: ${{ secrets.GOOGLE_LOCATION }}
GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }}
if: ${{ matrix.envPlatform != 'gke' || env.GOOGLE_PROJECT != '' }}
run: |
SMOKE_ENV_TYPE=${{ matrix.envPlatform }} make run
- name: make cleanup
if: always()
run: make cleanup
- uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
if: always()
with:
name: smoke-report-${{ matrix.envPlatform }}
if-no-files-found: ignore
path: |
raw-report.json
build/debug-output/*.log
retention-days: ${{ github.event_name == 'pull_request' && 7 || 15 }}