diff options
author | Tulir Asokan <tulir@maunium.net> | 2019-07-25 23:53:45 +0300 |
---|---|---|
committer | Tulir Asokan <tulir@maunium.net> | 2019-07-25 23:53:45 +0300 |
commit | 38f823dc0c4fe956288a80aba716e5fd675ead5c (patch) | |
tree | 24e69e82a88163238d22cab6fc040dc6e18a2d99 | |
parent | 37df8eb454088e61db7a14f382851205bc1806ad (diff) |
Add .gitlab-ci.yml
-rw-r--r-- | .gitlab-ci.yml | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..b52047e --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,65 @@ +image: golang:alpine + +variables: + CGO_ENABLED: "0" + +stages: +- modules +- build + +cache: + paths: + - .cache + +default: + before_script: + - apk add git + - mkdir -p .cache + - export GOPATH="$CI_PROJECT_DIR/.cache" + +modules: + stage: modules + script: + - go get + +.build: &build + stage: build + cache: + paths: + - .cache + script: + - echo "Building... $GOPATH $CGO_ENABLED $GOOS $GOARCH" + - go build -o gomuks + artifacts: + paths: + - gomuks + +build_linux_amd64: + <<: *build + variables: + GOOS: linux + GOARCH: amd64 + +build_linux_386: + <<: *build + variables: + GOOS: linux + GOARCH: "386" + +build_linux_arm: + <<: *build + variables: + GOOS: linux + GOARCH: arm + +build_linux_arm64: + <<: *build + variables: + GOOS: linux + GOARCH: arm64 + +build_darwin_amd64: + <<: *build + variables: + GOOS: darwin + GOARCH: amd64 |