1
0
Fork 0
mirror of https://github.com/shouptech/tempgopher.git synced 2026-02-03 16:49:42 +00:00
tempgopher/.gitlab-ci.yml
Mike Shoup a2a25c953b Update README.md with new instructions
This adds documentation for using the automated install script
2018-10-11 18:54:06 -06:00

37 lines
742 B
YAML

image: golang:1.11
variables:
binary_name: tempgopher
project_prefix: gitlab.com/shouptech
project_path: $project_prefix/tempgopher
stages:
- test
- build
before_script:
- mkdir -p ${GOPATH}/src/${project_prefix}
- cp -r ${CI_PROJECT_DIR} ${GOPATH}/src/${project_path}
- cd ${GOPATH}/src/${project_path}
- go get -v ./...
test:
stage: test
variables:
GIN_MODE: debug
script:
- go get -v -t ./...
- go test -v
build:
stage: build
variables:
build_binary: $CI_PROJECT_DIR/${binary_name}
script:
- go get -v github.com/gobuffalo/packr/...
- GOOS=linux GOARCH=arm GOARM=6 packr build -v -a -ldflags '-s -w -extldflags "-static"' -o ${build_binary}
artifacts:
paths:
- tempgopher
- install.sh