-
Notifications
You must be signed in to change notification settings - Fork 5
/
.travis.yml
59 lines (52 loc) · 5.3 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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
language: node_js
node_js:
- "6"
# Install client dependencies also before building
install:
- npm install
- npm run install:client
# Build the app and a docker image
script:
- npm run release
- docker build -t ${TRAVIS_COMMIT} --build-arg KILLRVIDEO_YOUTUBE_API_KEY=$KILLRVIDEO_YOUTUBE_API_KEY .
# If successful, see if we need to publish also
after_success:
- test -z $TRAVIS_TAG && travis_terminate 0
- docker tag ${TRAVIS_COMMIT} killrvideo/killrvideo-web:${TRAVIS_TAG}
- docker login -u $DOCKER_USER -p $DOCKER_PASS
- docker push killrvideo/killrvideo-web:${TRAVIS_TAG}
- "[ \"$(git tag --sort=-v:refname | grep -P \"^\\d+.\\d+.\\d+$\" | head -n1)\" == \"$TRAVIS_TAG\" ] && { docker tag ${TRAVIS_COMMIT} killrvideo/killrvideo-web:latest; docker push killrvideo/killrvideo-web:latest; }"
- "[ \"$(git tag --sort=-v:refname | grep -P \"^\\d+.\\d+.\\d+$\" | head -n1)\" == \"$TRAVIS_TAG\" ] && { docker tag ${TRAVIS_COMMIT} killrvideo/killrvideo-web:$(echo $TRAVIS_TAG | cut -d'.' -f 1); docker push killrvideo/killrvideo-web:$(echo $TRAVIS_TAG | cut -d'.' -f 1); }"
- "[ \"$(git tag --sort=-v:refname | grep -P \"^\\d+.\\d+.\\d+$\" | head -n1)\" == \"$TRAVIS_TAG\" ] && { docker tag ${TRAVIS_COMMIT} killrvideo/killrvideo-web:$(echo $TRAVIS_TAG | cut -d'.' -f 1).$(echo $TRAVIS_TAG | cut -d'.' -f 2); docker push killrvideo/killrvideo-web:$(echo $TRAVIS_TAG | cut -d'.' -f 1).$(echo $TRAVIS_TAG | cut -d'.' -f 2); }"
# Sudo required for doing docker build
sudo: required
services:
- docker
env:
global:
# Needed to compile native modules
- CXX=g++-4.8
# DOCKER_USER
- secure: SDWt42nKhpjRhtcbSKAsbK+Wy+TlElAGGTCL7ZRF/IZpjJx7FTciVDhnhNYQ7/+P84AF5HNOEKl1w5MqMfOnX9m5Tuq6ukq1qPH2fMl4OH/CoNZtnoctKB5qQNJSU36XWPY3fP2O+M8N+xv10mck9CcaJ0VpYsAzKPnTLsnoR2M6yQgfOQqZmCaHU1BudAvl2uD7s53MaXlzvgB49rcKScb1SDo8TOqwjobnMSjNUxN6b6Z7oxSK0LONG8YzppQibVIi836YWiKqxOHIi1NJWu2MQ4e/2YHihgbDxW5bYIL95MPiZY7j61FhIhDsqTXarIv8/ZLB1O1DjXXAeLrSTkAAt2DH+XA1yl67zznAYMsmF44H/2rAm4EIYQc9fI6k+ZVvVm7JfNYv+yPSW0On+cGmhkywNLUXUjq3JYsKRJrAiuf8fiMcNH/Xb2DS0MrQcW5ozGJS/zGPj5OMeXDvQj71hdVJFwNQH2D0RqsNclh8QreO/6WbPDRYiD1J5TSQ4lCmLSIRxtWdwr7Z0tTjdOQlpFUsQdCcA/hMdUXDDBKrQdIEB03dM39v8r2/yzadiIZvqWS6wDwy1uwbwsUs43rfiK6dj/yBiSseveDd08g3OncCw97fFLLuWLrGccL8bclOuQFDl/wZYstgpXWKg6GfC4M1bGhvkuTNVRHq/jI=
# DOCKER_PASS
- secure: C6F3VGcNRecXI/Ts4Psry4CLc3Fcb8/iHl9KeKGTgz4HElMBeviPW8HwxAtIOymDW3rDv2SMJ7bwe4Iwn/1En+8FfIOgIbGQ7guNo5fRxR8aLigWWUXkI3EGggalabixgSRGbPWaAy7QKw9lqz6tq7dJ9WUnl/sWQVhgFpYF6yEm1BJ3ntBIXtNBx+GoAZyfsPeFDnFF3guprQxeZPhOIeT/yfoCjNDK2jqXg7QOiUQkL/tRAUDYK8h57lL1Rl3AjGdyTZOGbpowSnxnxGbvHjhH/Ryvg+g8w5s7r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diLdKrbItvWSA2ZPXg12ggxRtZO5MaLU=
# KILLRVIDEO_YOUTUBE_API_KEY
- secure: flbr/mYfKeJrrr8QTQXvwdYzEw2GwY1BM+wgFUZ8nHdDqI2Yw1kyrZ84/Q9REEZy0ruc8OaKZXETHUar7WNT0N+RFhptj4BpLCoVJM4sCujbDi5HHkW7wlYEyWi2xzt3Q2f3i9+tbmJEBGq6LIS3buQ2xLJTPi1QC8EHll3+m8xNGRQ93azx2VhPjFGyG1uwcZUsrCkXRTJR+A8Ld4el7/BbvX4+ZBDIBcMOj80PcIzSUf4U4d26uoQGczaojbGs6pe7Dkv6vzXvk94QkqtYSl+0504qPi0uzpYAF9SZTnphLh899V1MEIlDU4um1aKqIJol+MNLU94uTFzVHhpA6DlHuaQMnLaKAV93Z3o7Mfek0riCMt4gzxWSEn+cJrtkVdgkqqCywgLA1ySry073566m4I3UEa8Myb/BbALHLF4tJbuJIdtO9nCYP4nxpS38iYQRv0TJf0WGAJVsHbB5JrXyMMnwWAVfJpfuD+a0MAA9NBZJ2Dqvec1Zv5KeTkKomrLzxwqQq5EYJ+WsMoJHuJpUyMMvM3+uenmLAemEHnEwYYVXn7nEuzEL04L/N4mSoO0dRDRW18CWCKZP4K/+ibHe0eomD4rRu2/B8CjtkFD/Yh0hBoOsC9lA1IdcoupGW6mt2LAntqLFvaL+DjGOnCqOk8ifXvvuxsCMGXgIEok=
# Also needed to compile native modules
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-4.8
# Cache node_modules between builds to try and speed things up
cache:
directories:
- node_modules
- src/client/node_modules
notifications:
slack:
rooms:
secure: EOJ+6cPVtzHMtAJNS5agU2Ea3sG9jldwwV13ngl3erCLe//8qurRmFwntU5O34xSGD3HITeftSPEySJt84W2ck3n4UF0sdu3JtEOoMyCyOOJ7BTSx85A9Zr7Kuv6otgVFYGahikT4X6SBtpkLVziD0kpQHa2DderHEcLgPqwCfkkS+zewXjLYHdfJT+FTQcHf2LbZKsDHZ9Vj7VBIFajTRA5SViTDRUL89GwCwyeJHTS1DV+bEb9iEUHErpgk2Lql4INJNvd4SsK24+dQHcPA3lngpBPgtYYJObX359PB00b5zDpoyGFL6g1xaziEUmB7VJ4dsuYZmrqo4ITJJalkaEW+5+x5x4k+J7agSlCqsJ4k1m+JlUMr3H9fcebSajzxPefmXqByaVY9t0xspqJkfKf1YJOqA6wPh5SXzWfwCakc1lAmwHYgQLxb5C4JCBCq0ez0pnjNlC5UqNS/xUMnv7/9AyhnqS7aRWcpRjsZuPcNVA7OWLHe8IyXkh7dfhmPxobypUOXzAnA4gXiWXHTea3Eta6mNSo6XLPFimp/hTfnvvU9K+KoxzuXnzrFau1DGP65Sri1jWQ6yj6fglHW905cRYre7nc9bQectBnm+HY0xwRJJ68IWwxb9BQ4mAFxBxy1L1XPZxwbbLrd7h2OF7TSDB57T+QSBZeQ1oCqsc=