1
0
Fork 0

Build cross binary only on tags in travis

This commit is contained in:
Michael 2018-01-23 17:00:06 +01:00 committed by Traefiker
parent 00e0571811
commit 3040d9df0d
3 changed files with 7 additions and 28 deletions

View file

@ -1,6 +1,9 @@
sudo: required
dist: trusty
git:
depth: false
services:
- docker
@ -21,12 +24,13 @@ before_deploy:
sudo -E apt-get -yq update;
sudo -E apt-get -yq --no-install-suggests --no-install-recommends --force-yes install docker-ce=${DOCKER_VERSION}*;
docker version;
make -j${N_MAKE_JOBS} crossbinary-parallel;
make image-dirty;
if [ "$TRAVIS_TAG" ]; then
make -j${N_MAKE_JOBS} crossbinary-parallel;
make image-dirty;
fi;
curl -sI https://github.com/containous/structor/releases/latest | grep -Fi Location | tr -d '\r' | sed "s/tag/download/g" | awk -F " " '{ print $2 "/structor_linux-amd64"}' | wget --output-document=$GOPATH/bin/structor -i -;
chmod +x $GOPATH/bin/structor;
structor -o containous -r traefik --dockerfile-url="https://raw.githubusercontent.com/containous/traefik/master/docs.Dockerfile" --menu.js-url="https://raw.githubusercontent.com/containous/structor/master/traefik-menu.js.gotmpl" --exp-branch=master --debug;
tar cfz dist/traefik-${VERSION}.src.tar.gz --exclude-vcs --exclude dist .;
fi
deploy:
- provider: releases
@ -56,4 +60,3 @@ deploy:
on:
repo: containous/traefik
all_branches: true