summaryrefslogtreecommitdiff
path: root/docker
diff options
context:
space:
mode:
authorkali kaneko (leap communications) <kali@leap.se>2020-04-24 18:57:01 +0200
committerkali kaneko (leap communications) <kali@leap.se>2020-04-30 22:10:31 +0200
commita14b4ac6507b65d9b2d5e22ff89cf89c689cd936 (patch)
tree7eaecf9f82d703e3da30e9efe3a63a4d56b39368 /docker
parent3a9f65fb9ccb32e6ef0e3f3c471cc50f1c3ee505 (diff)
[bug] do not use cross-compiling for the helper in win
- add -H windowsgui to avoid console popping up
Diffstat (limited to 'docker')
-rw-r--r--docker/Makefile4
-rwxr-xr-xdocker/builder.sh12
2 files changed, 9 insertions, 7 deletions
diff --git a/docker/Makefile b/docker/Makefile
index bdcc2b8..80ca9dd 100644
--- a/docker/Makefile
+++ b/docker/Makefile
@@ -14,10 +14,10 @@ package_win:
docker run \
-e XBUILD=win \
-e PROVIDER=riseup \
- -v `python3 -c 'import os; print(os.path.abspath(".."))'`:/bitmask-vpn.orig \
+ -v `python3 -c 'import os; print(os.path.abspath(".."))'`:/bitmask-vpn.host \
--cpus="4" \
-it --rm \
$(REGISTRY)/$(IMAGE):latest \
/builder.sh
shell:
- docker run -v `python3 -c 'import os; print(os.path.abspath(".."))'`:/bitmask-vpn.orig -it --rm $(REGISTRY)/$(IMAGE):latest /bin/bash
+ docker run -v `python3 -c 'import os; print(os.path.abspath(".."))'`:/bitmask-vpn.host -it --rm $(REGISTRY)/$(IMAGE):latest /bin/bash
diff --git a/docker/builder.sh b/docker/builder.sh
index dad7800..2767d61 100755
--- a/docker/builder.sh
+++ b/docker/builder.sh
@@ -1,9 +1,11 @@
#!/bin/bash
set -e
-export DESTDIR=/bitmask-vpn.orig/deploy/
-rm -rf /bitmask-vpn
-cp -r /bitmask-vpn.orig /bitmask-vpn
-cd /bitmask-vpn
+export HOSTDIR=/bitmask-vpn.host
+export GUESTDIR=/bitmask-vpn
+export DESTDIR="${HOSTDIR}"/deploy/
+rm -rf "${GUESTDIR}"
+cp -r "${HOSTDIR}" "${GUESTDIR}"
+cd "${GUESTDIR}"
make prepare
make build
case $XBUILD in
@@ -17,4 +19,4 @@ case $XBUILD in
make packages
;;
esac
-cp /bitmask-vpn/deploy/* $DESTDIR
+cp "${GUESTDIR}"/deploy/* $DESTDIR