summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKali Kaneko (leap communications) <kali@leap.se>2019-09-15 00:15:00 +0200
committerKali Kaneko (leap communications) <kali@leap.se>2019-09-15 00:22:49 +0200
commit2bc076641485c8d52a86441898d62c0fb86231fb (patch)
treed4ef8e5532f0c0c89882d7302d88763a5251f622
parent2027a761fd43300551490f32468f51523394e8c2 (diff)
[pkg] entrypoint for all vendored builds
-rw-r--r--.gitlab-ci.yml14
-rw-r--r--Makefile7
-rwxr-xr-xbranding/scripts/build-all-providers17
-rwxr-xr-xbranding/templates/makefile/Makefile2
4 files changed, 39 insertions, 1 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 1430603..518cb2c 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -3,6 +3,7 @@ stages:
- build
- push
- trigger
+ - vendor
variables:
GOPATH: /go
@@ -149,3 +150,16 @@ trigger_deb:
stage: trigger
script:
- "curl -X POST -F token=$RISEUP_VPN_DEB_TRIGGER_TOKEN -F ref=master https://0xacab.org/api/v4/projects/1916/trigger/pipeline"
+
+vendorize:
+ image: 0xacab.org:4567/leap/docker/bitmask-vpn:latest
+ stage: vendor
+ script:
+ - PROVIDERS="riseup" make build_all_providers
+ artifacts:
+ name: installers-$CI_COMMIT_REF_NAME
+ paths:
+ - deploy/RiseupVPN-*.exe
+ - deploy/RiseupVPN-*.pkg
+ - deploy/riseup-vpn-*.deb
+ expire_in: 1 month
diff --git a/Makefile b/Makefile
index 0023324..bfcb174 100644
--- a/Makefile
+++ b/Makefile
@@ -110,6 +110,13 @@ clean:
@unlink branding/assets/default
#########################################################################
+# build them all
+#########################################################################
+
+build_all_providers:
+ branding/scripts/build-all-providers
+
+#########################################################################
# packaging templates
#########################################################################
diff --git a/branding/scripts/build-all-providers b/branding/scripts/build-all-providers
new file mode 100755
index 0000000..2efcfc5
--- /dev/null
+++ b/branding/scripts/build-all-providers
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+# run the build process for all the providers passed
+# on a environment variable
+
+: "${PROVIDERS:=riseup}"
+
+set -e
+
+export XBUILD=yes
+
+for _provider in $PROVIDERS; do
+ export PROVIDER=$_provider;
+ make prepare
+ make build
+ make packages
+done
diff --git a/branding/templates/makefile/Makefile b/branding/templates/makefile/Makefile
index 3e6332f..39c4a50 100755
--- a/branding/templates/makefile/Makefile
+++ b/branding/templates/makefile/Makefile
@@ -54,8 +54,8 @@ pkg_osx:
echo "[+] Building osx package..."
cp ../bin/darwin/bitmask-vpn dist/$(APPNAME).app/Contents/MacOS/
cp ../bin/darwin/bitmask-helper dist/$(APPNAME).app/Contents/MacOS/
- chmod +x $(STAGING)/openvpn-osx
cp $(STAGING)/openvpn-osx dist/$(APPNAME).app/Contents/Resources/openvpn.leap
+ chmod +x dist/$(APPNAME).app/Contents/Resources/openvpn.leap
ifeq ($(SYSTEM), Darwin)
osx/quickpkg --output dist/$(APPNAME)-$(VERSION)_unsigned.pkg --scripts osx/scripts/ dist/$(APPNAME).app/
@if [ $(BUILD_RELEASE) = no ]; then\