summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitlab-ci.yml12
-rwxr-xr-xpkg/build_bundle_with_venv.sh19
-rw-r--r--pkg/pyinst/app.spec4
-rw-r--r--src/leap/bitmask/gui/app.py1
4 files changed, 33 insertions, 3 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index f9959e7f..44888716 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -1,7 +1,7 @@
-# Todo: move test stage to the top once it succeeds again
stages:
- - build
- test
+ - build
+ - bundle
test:
image: leapcode/soledad:latest
@@ -19,3 +19,11 @@ build:
- mkdir -p /root/.config/leap/
- bitmaskd
- bitmaskctl status
+
+bundle:
+ image: leapcode/bitmask-dev:latest
+ stage: bundle
+ script: pkg/build_bundle_with_venv.sh
+ artifacts:
+ paths:
+ - dist/*.tar.gz
diff --git a/pkg/build_bundle_with_venv.sh b/pkg/build_bundle_with_venv.sh
new file mode 100755
index 00000000..929710ad
--- /dev/null
+++ b/pkg/build_bundle_with_venv.sh
@@ -0,0 +1,19 @@
+#!/bin/bash
+virtualenv venv
+source venv/bin/activate
+$VIRTUAL_ENV/bin/pip install -U pyinstaller==3.1 packaging
+$VIRTUAL_ENV/bin/pip install zope.interface zope.proxy
+$VIRTUAL_ENV/bin/pip install leap.soledad.common
+$VIRTUAL_ENV/bin/pip install leap.soledad.client
+
+# XXX hack for the namespace package not being properly handled by pyinstaller
+touch $VIRTUAL_ENV/lib/python2.7/site-packages/zope/__init__.py
+touch $VIRTUAL_ENV/lib/python2.7/site-packages/leap/soledad/__init__.py
+
+make dev-all
+
+$VIRTUAL_ENV/bin/pip uninstall leap.bitmask
+$VIRTUAL_ENV/bin/pip install .
+
+make bundle
+make bundle_tar
diff --git a/pkg/pyinst/app.spec b/pkg/pyinst/app.spec
index 5869b604..347a50e4 100644
--- a/pkg/pyinst/app.spec
+++ b/pkg/pyinst/app.spec
@@ -9,7 +9,9 @@ hiddenimports = [
'leap.common', 'leap.bitmask',
'leap.bitmask.core.logs',
'leap.soledad.common.document',
- 'leap.bitmask_js']
+ 'leap.bitmask_js',
+ 'packaging', 'packaging.version', 'packaging.specifiers',
+ 'packaging.requirements']
if platform.system() == 'Windows':
print "Platform=Windows, using pyside..."
diff --git a/src/leap/bitmask/gui/app.py b/src/leap/bitmask/gui/app.py
index d70c238f..2c8d188f 100644
--- a/src/leap/bitmask/gui/app.py
+++ b/src/leap/bitmask/gui/app.py
@@ -45,6 +45,7 @@ else:
from PyQt5.QtWidgets import QDialog
from PyQt5.QtWidgets import QApplication
from PyQt5.QtWebKitWidgets import QWebView
+ from PyQt5.QtCore import QSize
BITMASK_URI = 'http://localhost:7070'