diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 03db7cf..8138c6b 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -5,19 +5,49 @@ before_script: - chmod +x packaging/build-package.sh stages: + - init - build - package -build: - stage: build +cache: + key: "PIPELINE-$CI_PIPELINE_ID" + paths: + - src/meow.tf/deb-simple/vendor + +glide-install: + stage: init script: - export GOPATH=`pwd` - cd $CI_PROJECT_DIR/src/meow.tf/deb-simple - glide install - cd $CI_PROJECT_DIR - mkdir -p build/i386 build/amd64 build/armv7 + +build-i386: + stage: build + script: + - mkdir -p build/i386 - go build -o build/amd64/deb-simple - GOOS=linux GOARCH=386 go build -o build/i386/deb-simple + artifacts: + paths: + - build + +build-amd64: + stage: build + script: + - mkdir -p build/amd64 + - go build -o build/amd64/deb-simple + - GOOS=linux GOARCH=386 go build -o build/i386/deb-simple + - GOOS=linux GOARCH=arm GOARM=7 go build -o build/armv7/deb-simple + artifacts: + paths: + - build + +build-armv7: + stage: build + script: + - mkdir -p build/armv7 - GOOS=linux GOARCH=arm GOARM=7 go build -o build/armv7/deb-simple artifacts: paths: