2
0
Fork 0
mirror of https://github.com/ii64/sonic.git synced 2026-06-21 00:46:43 +08:00

chore(ci): setup self-hosted runner for ci (#158)

This commit is contained in:
Pure White 2021-12-20 19:56:07 +08:00 committed by GitHub
parent 8203bbac35
commit 188e829dd7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 25 additions and 16 deletions

View file

@ -23,7 +23,7 @@ on:
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
runs-on: self-hosted
permissions:
actions: read
contents: read
@ -44,7 +44,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.16
go-version: 1.17
- uses: actions/cache@v2
with:

14
.github/workflows/license-check.yml vendored Normal file
View file

@ -0,0 +1,14 @@
name: License Check
on: push
jobs:
build:
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
- name: Check License Header
uses: apache/skywalking-eyes@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View file

@ -4,7 +4,7 @@ on: pull_request
jobs:
build:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
@ -14,7 +14,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.16
go-version: 1.17
- uses: actions/cache@v2
with:
@ -24,4 +24,4 @@ jobs:
${{ runner.os }}-go-
- name: Benchmark
run: go test -bench=. -benchmem -run=none ./...
run: GOMAXPROCS=4 go test -bench=. -benchmem -run=none ./...

View file

@ -4,7 +4,7 @@ on: push
jobs:
build:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
@ -21,4 +21,4 @@ jobs:
${{ runner.os }}-go-
- name: Unit Test
run: go test -v -covermode=atomic -coverprofile=coverage.out ./...
run: GOMAXPROCS=4 go test -v -covermode=atomic -coverprofile=coverage.out ./...

View file

@ -4,7 +4,7 @@ on: push
jobs:
build:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
@ -21,4 +21,4 @@ jobs:
${{ runner.os }}-go-
- name: Unit Test
run: go test -v -race -covermode=atomic -coverprofile=coverage.out ./...
run: GOMAXPROCS=4 go test -v -race -covermode=atomic -coverprofile=coverage.out ./...

View file

@ -4,7 +4,7 @@ on: push
jobs:
build:
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
@ -20,10 +20,5 @@ jobs:
restore-keys: |
${{ runner.os }}-go-
- name: Check License Header
uses: apache/skywalking-eyes@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Unit Test
run: go test -v -race -covermode=atomic -coverprofile=coverage.out ./...
run: GOMAXPROCS=4 go test -v -race -covermode=atomic -coverprofile=coverage.out ./...