-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy path.travis.yml
40 lines (34 loc) · 1.09 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
language: python
python:
- "3.6"
services:
- docker
env:
- DOCKER_COMPOSE_VERSION="1.20.0"
install:
- pip install coverage
- pip install codecov
- cp template.env .env
- touch app/static/index.html
- mkdir saml/certs
- openssl req -x509 -nodes -days 365 -newkey rsa:2048 -subj "/C=US/ST=New York/L=Rochester/O=RIT/OU=SG Services/CN=sg.rit.edu" -keyout saml/certs/sp.key -out saml/certs/sp.crt
- sudo rm /usr/local/bin/docker-compose
- curl -L https://github.com/docker/compose/releases/download/${DOCKER_COMPOSE_VERSION}/docker-compose-`uname -s`-`uname -m` > docker-compose
- chmod +x docker-compose
- sudo mv docker-compose /usr/local/bin
before_script:
- docker-compose run -d --name flask_web flask
script:
- docker exec -it flask_web py.test --cov=./app
- docker exec -it flask_web coverage xml
after_script:
- codecov
after_success:
- |
if [ $TRAVIS_BRANCH == "master" ]; then
curl http://tigertracker.rit.edu:9988/deploy/TAK9Nu7g4GXIS8jfwzn8
fi
- |
if [ $TRAVIS_BRANCH == "develop" ]; then
curl http://tigertrackerstage.rit.edu:9988/deploy/JjttpRkSfMkX5ma3l7jL
fi