diff options
Diffstat (limited to 'linux-build-farm')
-rwxr-xr-x | linux-build-farm/build.sh | 42 | ||||
-rw-r--r-- | linux-build-farm/debian-jessie/x64/Dockerfile | 10 | ||||
-rw-r--r-- | linux-build-farm/debian-jessie/x86/Dockerfile | 10 | ||||
-rw-r--r-- | linux-build-farm/ubuntu-trusty/x64/Dockerfile | 10 | ||||
-rw-r--r-- | linux-build-farm/ubuntu-trusty/x86/Dockerfile | 10 |
5 files changed, 82 insertions, 0 deletions
diff --git a/linux-build-farm/build.sh b/linux-build-farm/build.sh new file mode 100755 index 00000000..b0526ceb --- /dev/null +++ b/linux-build-farm/build.sh @@ -0,0 +1,42 @@ +#!/bin/bash + +export PATH=/bin:/usr/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/sbin + +if [ $# = 0 ]; then + echo 'Usage: ./build.sh <distribution-name> [<distribution-name>] ...' + exit 1 +fi + +if [ ! -d ./ubuntu-trusty ]; then + echo 'Must run from linux-build-farm subfolder.' + exit 1 +fi + +rm -f zt1-src.tar.gz +cd .. +git archive --format=tar.gz --prefix=ZeroTierOne/ -o linux-build-farm/zt1-src.tar.gz HEAD +cd linux-build-farm + +for distro in $*; do + cd $distro + + cd x64 + mv ../../zt1-src.tar.gz . + docker build -t zt1-build-${distro}-x64 . + mv zt1-src.tar.gz ../.. + cd .. + + docker run --rm -v `pwd`:/artifacts --privileged -it zt1-build-${distro}-x64 /bin/bash -c 'cd /ZeroTierOne ; make debian ; cd .. ; cp *.deb /artifacts ; ls -l /artifacts' + + cd x86 + mv ../../zt1-src.tar.gz . + docker build -t zt1-build-${distro}-x86 . + mv zt1-src.tar.gz ../.. + cd .. + + docker run --rm -v `pwd`:/artifacts --privileged -it zt1-build-${distro}-x86 /bin/bash -c 'cd /ZeroTierOne ; make debian ; cd .. ; cp *.deb /artifacts ; ls -l /artifacts' + + cd .. +done + +rm -f zt1-src.tar.gz diff --git a/linux-build-farm/debian-jessie/x64/Dockerfile b/linux-build-farm/debian-jessie/x64/Dockerfile new file mode 100644 index 00000000..721fc2a3 --- /dev/null +++ b/linux-build-farm/debian-jessie/x64/Dockerfile @@ -0,0 +1,10 @@ +FROM debian:jessie +MAINTAINER Adam Ierymenko <adam.ierymenko@zerotier.com> + +RUN apt-get update +RUN apt-get install -y build-essential debhelper libhttp-parser-dev liblz4-dev libnatpmp-dev dh-systemd ruby-ronn g++ make devscripts clang-3.5 + +ADD zt1-src.tar.gz / + +RUN ln -sf /usr/bin/clang++-3.5 /usr/bin/clang++ +RUN ln -sf /usr/bin/clang-3.5 /usr/bin/clang diff --git a/linux-build-farm/debian-jessie/x86/Dockerfile b/linux-build-farm/debian-jessie/x86/Dockerfile new file mode 100644 index 00000000..70ccd74a --- /dev/null +++ b/linux-build-farm/debian-jessie/x86/Dockerfile @@ -0,0 +1,10 @@ +FROM 32bit/debian:jessie +MAINTAINER Adam Ierymenko <adam.ierymenko@zerotier.com> + +RUN apt-get update +RUN apt-get install -y build-essential debhelper libhttp-parser-dev liblz4-dev libnatpmp-dev dh-systemd ruby-ronn g++ make devscripts clang-3.5 + +ADD zt1-src.tar.gz / + +RUN ln -sf /usr/bin/clang++-3.5 /usr/bin/clang++ +RUN ln -sf /usr/bin/clang-3.5 /usr/bin/clang diff --git a/linux-build-farm/ubuntu-trusty/x64/Dockerfile b/linux-build-farm/ubuntu-trusty/x64/Dockerfile new file mode 100644 index 00000000..c31c3ee4 --- /dev/null +++ b/linux-build-farm/ubuntu-trusty/x64/Dockerfile @@ -0,0 +1,10 @@ +FROM ubuntu:14.04 +MAINTAINER Adam Ierymenko <adam.ierymenko@zerotier.com> + +RUN apt-get update +RUN apt-get install -y build-essential debhelper libhttp-parser-dev liblz4-dev libnatpmp-dev dh-systemd ruby-ronn g++ make devscripts clang-3.6 + +ADD zt1-src.tar.gz / + +RUN ln -sf /usr/bin/clang++-3.6 /usr/bin/clang++ +RUN ln -sf /usr/bin/clang-3.6 /usr/bin/clang diff --git a/linux-build-farm/ubuntu-trusty/x86/Dockerfile b/linux-build-farm/ubuntu-trusty/x86/Dockerfile new file mode 100644 index 00000000..48f34c29 --- /dev/null +++ b/linux-build-farm/ubuntu-trusty/x86/Dockerfile @@ -0,0 +1,10 @@ +FROM 32bit/ubuntu:14.04 +MAINTAINER Adam Ierymenko <adam.ierymenko@zerotier.com> + +RUN apt-get update +RUN apt-get install -y build-essential debhelper libhttp-parser-dev liblz4-dev libnatpmp-dev dh-systemd ruby-ronn g++ make devscripts clang-3.6 + +ADD zt1-src.tar.gz / + +RUN ln -sf /usr/bin/clang++-3.6 /usr/bin/clang++ +RUN ln -sf /usr/bin/clang-3.6 /usr/bin/clang |