This commit is contained in:
+25
-6
@@ -1,17 +1,35 @@
|
||||
kind: pipeline
|
||||
type: docker
|
||||
name: go-lib/util
|
||||
environment:
|
||||
GOVERSION: 1.25.1
|
||||
VERSION: development
|
||||
|
||||
steps:
|
||||
- name: build
|
||||
image: golang
|
||||
- name: prepare
|
||||
image: golang:${GOVERSION}
|
||||
commands:
|
||||
- mkdir -p .build
|
||||
- go install gotest.tools/gotestsum@v1.9.0
|
||||
- go get ./...
|
||||
- gotestsum --format testname --junitfile .build/unittests.xml -- -coverprofile=.build/coverage.txt ./...
|
||||
- go get -v ./...
|
||||
- go install gotest.tools/gotestsum@1.13.0
|
||||
- go install golang.org/x/vuln/cmd/govulncheck@latest
|
||||
- govulncheck -v ./...
|
||||
|
||||
- name: test
|
||||
image: golang:${GOVERSION}
|
||||
commands:
|
||||
- mkdir -p .build
|
||||
- gotestsum --format testname --junitfile .build/unittests.xml -- -coverprofile=.build/coverage.txt ./...
|
||||
- govulncheck ./...
|
||||
depends_on:
|
||||
- prepare
|
||||
|
||||
- name: vulncheck
|
||||
image: golang:${GOVERSION}
|
||||
commands:
|
||||
- govulncheck ./...
|
||||
depends_on:
|
||||
- prepare
|
||||
|
||||
- name: publish
|
||||
image: golang
|
||||
commands:
|
||||
@@ -21,6 +39,7 @@ steps:
|
||||
- main
|
||||
event:
|
||||
- custom
|
||||
|
||||
trigger:
|
||||
event:
|
||||
- push
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
.build/
|
||||
Reference in New Issue
Block a user