ci: 规范项目开发与验证流程
This commit is contained in:
@@ -2,7 +2,10 @@ name: E2E Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
|
||||
@@ -11,7 +14,7 @@ jobs:
|
||||
permissions:
|
||||
contents: read
|
||||
name: Run on Ubuntu
|
||||
runs-on: ubuntu-latest
|
||||
runs-on: self-hosted
|
||||
steps:
|
||||
- name: Clone the code
|
||||
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
@@ -25,14 +28,20 @@ jobs:
|
||||
|
||||
- name: Install the latest version of kind
|
||||
run: |
|
||||
curl -Lo ./kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
|
||||
chmod +x ./kind
|
||||
sudo mv ./kind /usr/local/bin/kind
|
||||
mkdir -p ./bin
|
||||
curl -Lo ./bin/kind https://kind.sigs.k8s.io/dl/latest/kind-linux-$(go env GOARCH)
|
||||
chmod +x ./bin/kind
|
||||
|
||||
- name: Verify kind installation
|
||||
run: kind version
|
||||
- name: Verify Docker and kind
|
||||
run: |
|
||||
docker info
|
||||
./bin/kind version
|
||||
|
||||
- name: Running Test e2e
|
||||
run: |
|
||||
go mod tidy
|
||||
make test-e2e
|
||||
make test-e2e KIND=./bin/kind
|
||||
|
||||
- name: Clean up the Kind cluster
|
||||
if: always()
|
||||
run: make cleanup-test-e2e KIND=./bin/kind
|
||||
|
||||
Reference in New Issue
Block a user