-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update go version, switch to Makefile-based gosec
- Loading branch information
Showing
2 changed files
with
34 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,18 +10,15 @@ on: | |
branches: | ||
- "*" | ||
|
||
env: | ||
GOLANG_VERSION: "1.21" | ||
|
||
jobs: | ||
unit-tests: | ||
name: Unit tests running | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Go | ||
uses: actions/setup-go@v3 | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ env.GOLANG_VERSION }} | ||
go-version-file: './go.mod' | ||
|
||
- name: Checkout code | ||
uses: actions/[email protected] | ||
|
@@ -31,13 +28,13 @@ jobs: | |
make test | ||
linting: | ||
name: Go code linting | ||
name: Go code lint and gosec | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Go | ||
uses: actions/setup-go@v3 | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ env.GOLANG_VERSION }} | ||
go-version-file: './go.mod' | ||
|
||
- name: Checkout code | ||
uses: actions/[email protected] | ||
|
@@ -48,31 +45,22 @@ jobs: | |
version: latest | ||
args: --verbose --timeout 6m | ||
|
||
- name: Run gosec | ||
run: | | ||
make gosec | ||
build: | ||
name: Build creation | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Go | ||
uses: actions/setup-go@v3 | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ env.GOLANG_VERSION }} | ||
go-version-file: './go.mod' | ||
|
||
- name: Checkout code | ||
uses: actions/[email protected] | ||
|
||
- name: Build creation | ||
run: | | ||
make build | ||
gosec: | ||
runs-on: ubuntu-latest | ||
env: | ||
GO111MODULE: on | ||
GOFLAGS: -buildvcs=false | ||
steps: | ||
- name: Checkout Source | ||
uses: actions/checkout@v3 | ||
- name: Run Gosec Security Scanner | ||
uses: securego/gosec@master | ||
with: | ||
args: ./... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters