Skip to content

Commit b022d11

Browse files
author
Peng Zhefu
committed
upgrade actions and core
1 parent 29fe828 commit b022d11

File tree

8 files changed

+39
-38
lines changed

8 files changed

+39
-38
lines changed

.github/workflows/binary.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ jobs:
99
publish:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- name: "Setup go"
13-
uses: actions/setup-go@v4
14-
1512
- name: checkout
16-
uses: actions/checkout@v3
13+
uses: actions/checkout@v4
1714
with:
1815
fetch-depth: 0
1916

17+
- name: "Setup go"
18+
uses: actions/setup-go@v4
19+
2020
- name: "Build binary"
2121
run: |
2222
make binary

.github/workflows/dockerimage.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,26 +12,29 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- name: checkout
15-
uses: actions/checkout@v3
15+
uses: actions/checkout@v4
1616
with:
1717
fetch-depth: 0
1818

19+
- uses: docker/setup-qemu-action@v3
20+
- uses: docker/setup-buildx-action@v3
21+
1922
- name: Log in to the ghcr
20-
uses: docker/login-action@v1
23+
uses: docker/login-action@v3
2124
with:
2225
registry: ghcr.io
2326
username: ${{ github.actor }}
2427
password: ${{ secrets.GITHUB_TOKEN }}
2528

2629
- name: Log in to the docker
27-
uses: docker/login-action@v1
30+
uses: docker/login-action@v3
2831
with:
2932
username: ${{ secrets.DOCKER_USERNAME }}
3033
password: ${{ secrets.DOCKER_PASSWORD }}
3134

3235
- name: Docker meta
3336
id: meta
34-
uses: docker/metadata-action@v3
37+
uses: docker/metadata-action@v5
3538
with:
3639
images: |
3740
ghcr.io/${{ github.repository }}
@@ -42,7 +45,7 @@ jobs:
4245
- name: Docker meta for debug version
4346
if: ${{ github.ref == 'refs/heads/master' }}
4447
id: debug-meta
45-
uses: docker/metadata-action@v3
48+
uses: docker/metadata-action@v5
4649
with:
4750
images: |
4851
ghcr.io/${{ github.repository }}
@@ -52,15 +55,15 @@ jobs:
5255
5356
- name: Build and push image
5457
if: ${{ steps.meta.outputs.tags != '' }}
55-
uses: docker/build-push-action@v2
58+
uses: docker/build-push-action@v5
5659
with:
5760
context: "."
5861
push: true
5962
tags: ${{ steps.meta.outputs.tags }}
6063

6164
- name: "[debug version] Build and push image"
6265
if: ${{ github.ref == 'refs/heads/master' }}
63-
uses: docker/build-push-action@v2
66+
uses: docker/build-push-action@v5
6467
with:
6568
context: "."
6669
push: true

.github/workflows/golangci-lint.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ jobs:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- name: Checkout
16-
uses: actions/checkout@v3
16+
uses: actions/checkout@v4
1717

1818
- name: Set up Go
19-
uses: actions/setup-go@v3
19+
uses: actions/setup-go@v4
2020
with:
21-
go-version-file: "go.mod"
21+
go-version-file: 'go.mod'
2222

2323
- name: golangci-lint
2424
uses: golangci/golangci-lint-action@v3

.github/workflows/goreleaser.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- name: Checkout
13-
uses: actions/checkout@v3
13+
uses: actions/checkout@v4
1414
with:
1515
fetch-depth: 0
1616

@@ -19,14 +19,14 @@ jobs:
1919
echo "VERSION=$(git describe --tags $(git rev-list --tags --max-count=1))" >> $GITHUB_ENV
2020
2121
- name: Set up Go
22-
uses: actions/setup-go@v3
22+
uses: actions/setup-go@v4
2323
with:
24-
go-version-file: "go.mod"
24+
go-version-file: 'go.mod'
2525

2626
- name: Run GoReleaser
27-
uses: goreleaser/goreleaser-action@v2
27+
uses: goreleaser/goreleaser-action@v5
2828
with:
2929
version: latest
30-
args: release --rm-dist
30+
args: release --clean
3131
env:
3232
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/test.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,10 @@ on:
1111
jobs:
1212
unittests:
1313
runs-on: ubuntu-latest
14-
1514
steps:
16-
- uses: actions/checkout@v3
17-
- uses: actions/setup-go@v3
15+
- uses: actions/checkout@v4
16+
- uses: actions/setup-go@v4
1817
with:
19-
go-version-file: "go.mod"
18+
go-version-file: 'go.mod'
2019
- name: unit tests
2120
run: make test

.goreleaser.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,14 @@ builds:
5151
- amd64
5252

5353
archives:
54-
- replacements:
55-
darwin: Darwin
56-
linux: Linux
57-
windows: Windows
58-
386: i386
59-
amd64: x86_64
54+
- id: agent
55+
name_template: >-
56+
{{- .ProjectName }}_{{- .Version }}_
57+
{{- title .Os }}_
58+
{{- if eq .Arch "amd64" }}x86_64
59+
{{- else if eq .Arch "386" }}i386
60+
{{- else }}{{ .Arch }}{{ end }}
61+
{{- if .Arm }}v{{ .Arm }}{{ end -}}
6062
6163
checksum:
6264
name_template: 'checksums.txt'

go.mod

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ require (
1313
github.com/panjf2000/ants/v2 v2.7.3
1414
github.com/patrickmn/go-cache v2.1.0+incompatible
1515
github.com/pkg/errors v0.9.1
16-
github.com/projecteru2/core v0.0.0-20230515031536-7fdaea78417e
17-
github.com/projecteru2/libyavirt v0.0.0-20230725071905-9785e974d625
16+
github.com/projecteru2/core v0.0.0-20231011045726-f834c8786ef0
17+
github.com/projecteru2/libyavirt v0.0.0-20230921032447-a617cf0c746c
1818
github.com/prometheus/client_golang v1.15.0
1919
github.com/rs/zerolog v1.29.1
2020
github.com/shirou/gopsutil v3.21.11+incompatible
@@ -45,7 +45,6 @@ require (
4545
github.com/gogo/protobuf v1.3.2 // indirect
4646
github.com/golang/protobuf v1.5.3 // indirect
4747
github.com/google/uuid v1.3.0 // indirect
48-
github.com/juju/errors v1.0.0 // indirect
4948
github.com/kr/pretty v0.3.1 // indirect
5049
github.com/kr/text v0.2.0 // indirect
5150
github.com/mattn/go-colorable v0.1.13 // indirect

go.sum

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,6 @@ github.com/jinzhu/configor v1.2.1/go.mod h1:nX89/MOmDba7ZX7GCyU/VIaQ2Ar2aizBl2d3
145145
github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU=
146146
github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4=
147147
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
148-
github.com/juju/errors v1.0.0 h1:yiq7kjCLll1BiaRuNY53MGI0+EQ3rF6GB+wvboZDefM=
149-
github.com/juju/errors v1.0.0/go.mod h1:B5x9thDqx0wIMH3+aLIMP9HjItInYWObRovoCFM5Qe8=
150148
github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k=
151149
github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8=
152150
github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE=
@@ -224,10 +222,10 @@ github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE
224222
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
225223
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
226224
github.com/prashantv/gostub v1.1.0 h1:BTyx3RfQjRHnUWaGF9oQos79AlQ5k8WNktv7VGvVH4g=
227-
github.com/projecteru2/core v0.0.0-20230515031536-7fdaea78417e h1:7gx3ZANhgXc3yPjecJi/dPhZrOh3LGjn8SI/VK4siQY=
228-
github.com/projecteru2/core v0.0.0-20230515031536-7fdaea78417e/go.mod h1:H7AOnfGM0xI7hYMLG8JpqRVCI+flEX2w/Ro29zSwrQw=
229-
github.com/projecteru2/libyavirt v0.0.0-20230725071905-9785e974d625 h1:liDnxQ0JxvOLC0/tUVRlz4tG9r/xbcp1NXgNVNBJsLQ=
230-
github.com/projecteru2/libyavirt v0.0.0-20230725071905-9785e974d625/go.mod h1:N41KaKmqbailweGs4x/mt2H0O0Y7MizObZQ+igLdzpw=
225+
github.com/projecteru2/core v0.0.0-20231011045726-f834c8786ef0 h1:+DdklqQduXehUGnJUiiFrjyDDuQnODEyvSGYSbAtIdc=
226+
github.com/projecteru2/core v0.0.0-20231011045726-f834c8786ef0/go.mod h1:fxKSjK6GhlCiV+e1eBtnJpAB7RqM021ZKIB0iZeYOXo=
227+
github.com/projecteru2/libyavirt v0.0.0-20230921032447-a617cf0c746c h1:zwbTS+K8aKgXHU/7YVU4okk7fqrAE3W+yJjMRE3qdQA=
228+
github.com/projecteru2/libyavirt v0.0.0-20230921032447-a617cf0c746c/go.mod h1:+EcdWF8KyTf2u8Zxu3397nSmalCSmpuxvGwcX1g3RL0=
231229
github.com/prometheus/client_golang v1.15.0 h1:5fCgGYogn0hFdhyhLbw7hEsWxufKtY9klyvdNfFlFhM=
232230
github.com/prometheus/client_golang v1.15.0/go.mod h1:e9yaBhRPU2pPNsZwE+JdQl0KEt1N9XgF6zxWmaC0xOk=
233231
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=

0 commit comments

Comments
 (0)