forked from CodeForPoznan/pah-fm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
30 lines (28 loc) · 793 Bytes
/
.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
sudo: required
services:
- docker
language: python
python:
- 3.5
install:
- pip install -r backend/requirements/dev.txt
- nvm install 8.12.0
- cd frontend && npm install && cd -
script:
- cd backend
- pycodestyle --exclude='fleet_management/migrations/*' .
- cd ..
- cd frontend
- npm run lint
- cd ..
after_success:
- if [ "$TRAVIS_BRANCH" == "master" ] && [ "$TRAVIS_PULL_REQUEST" = false ]; then
docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD;
cd backend;
docker build -f Dockerfile -t codeforpoznan/pah-fm-backend:latest .;
docker push codeforpoznan/pah-fm-backend;
cd ../frontend;
docker build -f Dockerfile -t codeforpoznan/pah-fm-frontend:latest .;
docker push codeforpoznan/pah-fm-frontend;
cd ..;
fi