forked from opensourcepos/opensourcepos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
34 lines (34 loc) · 1.2 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
sudo: required
dist: trusty
group: deprecated-2017Q4
branches:
except:
- weblate
services:
- docker
before_install:
- curl -L https://github.com/docker/compose/releases/download/1.7.1/docker-compose-`uname
-s`-`uname -m` > docker-compose
- chmod +x docker-compose
- sudo mv docker-compose /usr/local/bin
- date=`date +%Y%m%d%H%M%S` && branch=${TRAVIS_BRANCH} && rev=`git rev-parse --short=6
HEAD` && sed -i "s/\$1/\$1.$date.$branch.$rev/g" deployment.json
script:
- docker run --rm -v $(pwd):/app composer/composer install
- docker run --rm -v $(pwd):/app -w /app lucor/php7-cli php bin/install.php translations
develop
- docker run --rm -it -v $(pwd):/app -w /app digitallyseamless/nodejs-bower-grunt
sh -c "npm install && bower install && grunt package"
- docker-compose build
env:
- TAG=$(echo ${TRAVIS_BRANCH} | sed s/feature\\///)
after_success: '[ -n ${DOCKER_USERNAME} ] && docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
&& docker tag opensourcepos_php "jekkos/opensourcepos:$TAG" && docker push "jekkos/opensourcepos:$TAG"'
deploy:
file: deployment.json
provider: bintray
skip_cleanup: true
key: ${BINTRAY_API_KEY}
user: jekkos
on:
all_branches: true