gosec/format on CI merge_requestsC
This commit is contained in:
parent
97fe8febfa
commit
2cf00ce152
1 changed files with 6 additions and 2 deletions
|
@ -6,7 +6,7 @@ stages:
|
||||||
- test
|
- test
|
||||||
- build
|
- build
|
||||||
|
|
||||||
format:
|
check-format:
|
||||||
image: golang:latest
|
image: golang:latest
|
||||||
stage: test
|
stage: test
|
||||||
before_script:
|
before_script:
|
||||||
|
@ -17,8 +17,10 @@ format:
|
||||||
- go fmt $(go list ./... | grep -v /vendor/)
|
- go fmt $(go list ./... | grep -v /vendor/)
|
||||||
- go vet $(go list ./... | grep -v /vendor/)
|
- go vet $(go list ./... | grep -v /vendor/)
|
||||||
- go test -race $(go list ./... | grep -v /vendor/)
|
- go test -race $(go list ./... | grep -v /vendor/)
|
||||||
|
only:
|
||||||
|
- merge_requests
|
||||||
|
|
||||||
gosec:
|
check-gosec:
|
||||||
image: golang:latest
|
image: golang:latest
|
||||||
before_script:
|
before_script:
|
||||||
- mkdir -p $GOPATH/src/$(dirname $REPO_NAME)
|
- mkdir -p $GOPATH/src/$(dirname $REPO_NAME)
|
||||||
|
@ -28,6 +30,8 @@ gosec:
|
||||||
- go install github.com/securego/gosec/v2/cmd/gosec@latest
|
- go install github.com/securego/gosec/v2/cmd/gosec@latest
|
||||||
- go get -v -d .
|
- go get -v -d .
|
||||||
- gosec ./...
|
- gosec ./...
|
||||||
|
only:
|
||||||
|
- merge_requests
|
||||||
|
|
||||||
docker-build-prod-latest:
|
docker-build-prod-latest:
|
||||||
image: ezkrg/buildx
|
image: ezkrg/buildx
|
||||||
|
|
Loading…
Reference in a new issue