Skip to content
GitLab
Explore
Sign in
Register
Commits on Source (2)
CI: Provide CSS files as artifacts
· 921b2476
Justin Kromlinger
authored
Sep 12, 2019
921b2476
CI: Add go cache, move coverage to build job
· 9a0669be
Justin Kromlinger
authored
Sep 12, 2019
9a0669be
Show whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
9a0669be
...
...
@@ -5,7 +5,6 @@
stages
:
-
generate
-
build
-
coverage
-
deploy
-
acceptance
-
restore
...
...
@@ -19,29 +18,35 @@ sass:
-
sassc -p 0 -t compressed sass/main.scss sass/main.css
-
sassc -p 0 -t compressed sass/chart.scss sass/chart.css
-
sassc -p 0 -t compressed sass/status.scss sass/status.css
artifacts
:
paths
:
-
sass/*.css
build
:
build
AndTest
:
stage
:
build
image
:
golang:latest
variables
:
CGO_ENABLED
:
0
GOPATH
:
"
$PWD/.go"
script
:
-
test -f sass/main.css
-
test -f sass/chart.css
-
test -f sass/status.css
-
go generate --run "fileb0x"
-
go build -ldflags "-X main.VERSION=$(git describe --tags) -X main.BUILD_DATE=$(date --iso-8601=seconds) -X main.GIN_MODE=release" -o bin/hashworksNET *.go
-
go test --covermode=atomic --coverprofile=coverage.out ./server
-
test -f coverage.out
-
curl -sL https://codecov.io/bash > codecov
-
bash codecov -f coverage.out -t "$CODEGOV_TOKEN"
-
./bin/hashworksNET --version
artifacts
:
paths
:
-
coverage.out
-
bin/hashworksNET
coverage
:
stage
:
coverage
image
:
cosmintitei/bash-curl:latest
script
:
-
test -f coverage.out
-
curl -L https://codecov.io/bash > codecov
-
bash codecov -f coverage.out -t "$CODEGOV_TOKEN"
cache
:
key
:
go
paths
:
-
.go
deploy
:
stage
:
deploy
...
...