-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
42 lines (42 loc) · 1.29 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
dist: xenail
language: python
python:
- '3.8'
#install:
#- pip install .
#- pip install -r requirements.txt
sudo: required
notifications:
webhooks:
urls:
- https://app.johnstratoudakis.com/hooks/redeploy
on_success: always # default: always
services:
- docker
script:
# Run Unit Tests for Flask App
- make unit_tests
- git config --global user.email "johnstratoudakis@egmail.com"
- git config --global user.name "Bumpversion after CI"
- bumpversion --config-file .bumpversion.cfg --verbose patch
- chmod 600 travis_deploy_key
- eval `ssh-agent -s`
- ssh-add travis_deploy_key
- git config --global push.default simple
- git remote add deploy $(git remote -v | sed -nre 's#^origin.*https://([^/]*)/([^
]*) *.*push.*#git@\1:\2#p')
- git push deploy HEAD:master
- docker build -t johnstratoudakis/ontheroad_flask:latest ./OnTheRoad
- docker build -t johnstratoudakis/ontheroad_ui:latest ./ontheroad_ui
#- cd ontheroad_ui
#- yarn install
#- yarn run build
- cd ..
after_success:
- docker login -u $DOCKER_USER -p $DOCKER_PASS
- docker push johnstratoudakis/ontheroad_flask:latest
- docker push johnstratoudakis/ontheroad_ui:latest
before_install:
- openssl aes-256-cbc -K $encrypted_3bc2bd3e7847_key -iv $encrypted_3bc2bd3e7847_iv
-in secret-files.tar.enc -out secret-files.tar -d
- tar xvf secret-files.tar