From a1897871430b9bd31e12ea0144ea881beabe9e9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mikl=C3=B3s=20T=C3=B3th?= <tothmiklostibor@gmail.com> Date: Sun, 25 Jun 2023 01:32:38 +0200 Subject: [PATCH] Add CI --- .gitlab-ci.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..65aaab8 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,34 @@ +stages: + - 🔨 + +variables: + GO_IN: . + GO_OUT: app + GOPATH: /cache/.gopath + GOCACHE: /cache/.gocache + CGO_ENABLED: "0" + + +go build (amd64): + stage: 🔨 + image: golang + before_script: + - mkdir -p $GOPATH + - mkdir -p $GOCACHE + script: + - GOARCH=amd64 go build -v -o "$GO_OUT-linux-amd64" "$GO_IN" + artifacts: + paths: + - "$GO_OUT-linux-amd64" + +go build (arm64): + stage: 🔨 + image: golang + before_script: + - mkdir -p $GOPATH + - mkdir -p $GOCACHE + script: + - GOARCH=arm64 go build -v -o "$GO_OUT-linux-arm64" "$GO_IN" + artifacts: + paths: + - "$GO_OUT-linux-arm64" -- GitLab