forked from bugy/script-server
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
69 lines (67 loc) · 3.36 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
60
61
62
63
64
65
66
67
68
69
if: tag IS blank
sudo: required
dist: xenial
language: node_js
node_js:
- '11'
cache:
directories:
- web-src/node_modules
addons:
chrome: stable
env:
global:
- OWNER=${TRAVIS_REPO_SLUG%/*}
# GITHUB_TOKEN
- secure: GtWCiMPNz3MDDTvXqaVsgZBvlxYRZuTY6sUEhWTL37zJZHgRLlxTCTD27hHZp2P4B6G6KGV/0iEvMYxqzo6jMrzcEnt7TlGetteqI18dhV1dIQGH6uy8Y/PktkK2g2FuJeGV3FRK4+a21v6zzSuUaFa26k97mPapa4LS83XXj7rc13ll23HhhtObVF/a1n3U0Xwe4FkdoxbKlecJUnNujESxFk4xQl4N1tFv15fldDlFq0XWs26eEp3LU/n7wkMzbg9WEqPvDeaYlvir9VpvcYWpVvf8Uz+wpvW1jnE2R6bK1TDv5BNzQwbf2JtN284yZ8I1nwZtOJkc1RUr5wUFxCD0p8tc30sAlKemI385v2t1ccoBYMwH8LHFIUoSXoolHZBsnZeADqpo3a0d8hVFWv4AcxC27Q6SfMCltl0+ogAoQ7wVfkRT++044p415Ar4raEqIkqTm64FaRNMS0v2y5mS2634PMSGMRnK+NBrWz1yFKxsiuPKypIWygtrJ4pyiL2yPBZupnCluEgqva3q6AmMDlNuSUmcTEnCRGB01U2if6/oSEgISH1VK2lsRSxuoG5dFFuezwv90YENh/7pw0/hgge7EOse6OzDsU3uNRWcTuXF7eEBhjM1wBHWHlaAwV9vfHMZX4sHWP4R4CZhPjVEPRz6HPEg1tFCs2EvkuI=
# DOCKER_USER
- secure: 0AUrT+5xg+JGjAeZQfeCyVFHYw04YDSzCpeQILtt7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BZ+9yAwzuZmj0GYFOQTuczAqncyj/3BuOEqfIkkQ5BLAS5BUuzSEbHOjwasqbTVcWM1H3cv2ZYATXQQN8KhcZ5c5lxy8eD0NXHKvBFlS3HOXOXn3P6PqGgFHzjL+yyHMvzIXBJY4jEr8FIH16dwbXDqb4gi4lrrCZHDeIhVKsmLSUJjhmiKeP7dWcfUOGMxzLRmqA8r58TXcN3OvBrqNN63nUSG+Wb6XxmzLwE4PrlBy0fTRymG8WXrdE/Z2lglBhc8J3A8ER9c46s=
before_install:
- sudo apt-get -y install python3-pip python3-setuptools apache2-utils
install:
- sudo pip3 install -r requirements.txt
- sudo pip3 install ldap3 parameterized bcrypt
- sudo pip3 install requests --upgrade
- sudo pip3 install pyasn1 --upgrade
- cd web-src
- npm install
- cd ..
before_script:
- cd src
- python3 -m unittest discover -s tests -p "*.py" -t .
- cd ../web-src
- npm run test:unit-ci
- cd ..
script:
- python3 tools/build.py
before_deploy:
- if ! [ "$BEFORE_DEPLOY_RUN" ]; then
export BEFORE_DEPLOY_RUN=1;
. tools/add_git_tag.sh
fi
deploy:
- provider: releases
name: dev
api_key: "$GITHUB_TOKEN"
file: build/script-server.zip
prerelease: true
overwrite: true
skip_cleanup: true
on:
branch: master
- provider: releases
name: $(unzip -qc build/script-server.zip version.txt)
api_key: "$GITHUB_TOKEN"
file: build/script-server.zip
skip_cleanup: true
on:
branch: stable
- provider: script
script: tools/deploy_docker.sh
skip_cleanup: true
on:
tags: false
all_branches: true
condition: $TRAVIS_BRANCH =~ ^stable|master$