Skip to content
Snippets Groups Projects
Unverified Commit 8dd79bac authored by meskio's avatar meskio :tent: Committed by Kali Kaneko
Browse files

[ci] run only the tests and compile in the CI

parent 45781102
Branches
Tags
1 merge request!108Qt snap2
......@@ -5,76 +5,67 @@ stages:
- trigger
- vendor
variables:
GOPATH: /go
APP_PATH: /go/src/0xacab.org/leap/bitmask-vpn
build_test:
image: registry.0xacab.org/leap/docker/bitmask-vpn:latest
stage: build
script:
- mkdir -p /go/src/0xacab.org/leap/
- ln -s "$(pwd)" ${APP_PATH}
- cd ${APP_PATH}
- make get
- apt update
- apt install -y qtbase5-dev qttools5-dev-tools qt5-qmake g++ qtdeclarative5-dev qt5-default
- make generate
- make test
- make build_bitmaskd
- make build
- ./build.sh
tags:
- linux
artifacts:
paths:
- 'bitmask-vpn'
- 'bitmask-helper'
- 'bitmask-connect'
- 'qtbuild/release/riseup-vpn'
expire_in: 1 month
branded_push:
image: registry.0xacab.org/leap/docker/bitmask-vpn:latest
stage: push
only:
- master
script:
# install the command-line openssh client to manage private keys
- apt install -y openssh-client
# activate the ssh-agent
- eval $(ssh-agent -s)
# load the private key, which is accessed vi a gitlab CI secret environment variable
# We're using tr to fix line endings which makes ed25519 keys work
# without extra base64 encoding.
- ssh-add <(echo "$RISEUP_VPN_PACKAGE_SSH_KEY")
- mkdir -p ~/.ssh
# ensure that ssh will trust a new host, instead of asking
- echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config
# we also need to configure name and email for git user
- git config user.name "Gitlab CI"
- git config user.email "gitlabci@0xacab.org"
# Add the remote repository and push to it - sometimes it already exists, and it causes the pipeline to fail, so we only add if its not already there
- git remote -v |grep -q riseup-vpn || git remote add riseup-vpn git@0xacab.org:leap/riseup-vpn_package.git
- git push --force riseup-vpn HEAD:incoming
# branded_push:
# image: registry.0xacab.org/leap/docker/bitmask-vpn:latest
# stage: push
# only:
# - master
# script:
# # install the command-line openssh client to manage private keys
# - apt install -y openssh-client
# # activate the ssh-agent
# - eval $(ssh-agent -s)
# # load the private key, which is accessed vi a gitlab CI secret environment variable
# # We're using tr to fix line endings which makes ed25519 keys work
# # without extra base64 encoding.
# - ssh-add <(echo "$RISEUP_VPN_PACKAGE_SSH_KEY")
# - mkdir -p ~/.ssh
# # ensure that ssh will trust a new host, instead of asking
# - echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config
# # we also need to configure name and email for git user
# - git config user.name "Gitlab CI"
# - git config user.email "gitlabci@0xacab.org"
# # Add the remote repository and push to it - sometimes it already exists, and it causes the pipeline to fail, so we only add if its not already there
# - git remote -v |grep -q riseup-vpn || git remote add riseup-vpn git@0xacab.org:leap/riseup-vpn_package.git
# - git push --force riseup-vpn HEAD:incoming
trigger_deb:
image: registry.0xacab.org/leap/docker/buster_amd64:latest
stage: trigger
script:
- echo "Triggering CI pipeline on https://0xacab.org/leap/riseup-vpn_package/pipelines"
- "curl -X POST -F token=$RISEUP_VPN_DEB_TRIGGER_TOKEN -F ref=master https://0xacab.org/api/v4/projects/1916/trigger/pipeline"
# trigger_deb:
# image: registry.0xacab.org/leap/docker/buster_amd64:latest
# stage: trigger
# script:
# - echo "Triggering CI pipeline on https://0xacab.org/leap/riseup-vpn_package/pipelines"
# - "curl -X POST -F token=$RISEUP_VPN_DEB_TRIGGER_TOKEN -F ref=master https://0xacab.org/api/v4/projects/1916/trigger/pipeline"
vendorize:
image: registry.0xacab.org/leap/docker/bitmask-vpn:latest
stage: vendor
script:
#- 'PROVIDERS="riseup calyx" make build_all_providers'
- 'PROVIDERS="riseup" make build_all_providers'
artifacts:
name: installers-$CI_COMMIT_REF_NAME
paths:
- 'deploy/*.snap'
- 'deploy/RiseupVPN-*.exe'
- 'deploy/RiseupVPN-*.pkg'
- 'deploy/riseup-vpn_*.deb'
- 'deploy/CalyxVPN-*.exe'
- 'deploy/CalyxVPN-*.pkg'
- 'deploy/calyx-vpn_*.deb'
expire_in: 1 month
# vendorize:
# image: registry.0xacab.org/leap/docker/bitmask-vpn:latest
# stage: vendor
# script:
# - 'PROVIDERS="riseup calyx" make build_all_providers'
# artifacts:
# name: installers-$CI_COMMIT_REF_NAME
# paths:
# - 'deploy/*.snap'
# - 'deploy/RiseupVPN-*.exe'
# - 'deploy/RiseupVPN-*.pkg'
# - 'deploy/riseup-vpn_*.deb'
# - 'deploy/CalyxVPN-*.exe'
# - 'deploy/CalyxVPN-*.pkg'
# - 'deploy/calyx-vpn_*.deb'
# expire_in: 1 month
......@@ -79,7 +79,7 @@ build_%:
-@ln -s ../../../bin/${PLATFORM}/$* build/${PROVIDER}/staging/${PLATFORM}/$*
test:
@go test -tags "integration $(TAGS)" ./...
@go test -tags "integration $(TAGS)" ./pkg/...
golib:
CGO_ENABLED=1 go build -buildmode=c-archive -o ${TARGET_GOLIB} ${SOURCE_GOLIB}
......@@ -148,6 +148,7 @@ endif
generate:
@go generate gui/backend.go
@go generate pkg/config/version/genver/gen.go
relink_default:
ifneq (,$(wildcard ${DEFAULT_PROVIDER}))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment