-
Notifications
You must be signed in to change notification settings - Fork 2
/
.travis.yml
55 lines (49 loc) · 2.11 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
matrix:
include:
- language: python
services:
- docker
before_install:
- curl https://cli-assets.heroku.com/install.sh | sh
- echo $DOCKER_PASSWORD | docker login -u $DOCKER_USERNAME --password-stdin
- docker login -u $HEROKU_USERNAME --password=$(heroku auth:token) registry.heroku.com
script:
- docker build -t $DOCKER_USERNAME/backend ./backend
- docker tag $DOCKER_USERNAME/backend registry.heroku.com/$HEROKU_BACKEND_APP/web
deploy:
provider: script
script:
docker push $DOCKER_USERNAME/backend;
docker push registry.heroku.com/$HEROKU_BACKEND_APP/web;
heroku container:release web --app $HEROKU_BACKEND_APP
on:
branch: main
- language: node_js
services:
- docker
before_install:
- curl https://cli-assets.heroku.com/install.sh | sh
- echo $DOCKER_PASSWORD | docker login -u $DOCKER_USERNAME --password-stdin
- docker login -u $HEROKU_USERNAME --password=$(heroku auth:token) registry.heroku.com
script:
- >
docker build
--build-arg react_app_firebase_key=$REACT_APP_FIREBASE_KEY
--build-arg react_app_firebase_domain=$REACT_APP_FIREBASE_DOMAIN
--build-arg react_app_firebase_database=$REACT_APP_FIREBASE_DATABASE
--build-arg react_app_firebase_project_id=$REACT_APP_FIREBASE_PROJECT_ID
--build-arg react_app_firebase_storage_bucket=$REACT_APP_FIREBASE_STORAGE_BUCKET
--build-arg react_app_firebase_sender_id=$REACT_APP_FIREBASE_SENDER_ID
--build-arg frontend_name=$FRONTEND_NAME
--build-arg backend_url=$BACKEND_URL
-t $DOCKER_USERNAME/frontend
./frontend
- docker tag $DOCKER_USERNAME/frontend registry.heroku.com/$HEROKU_FRONTEND_APP/web
deploy:
provider: script
script:
docker push $DOCKER_USERNAME/frontend;
docker push registry.heroku.com/$HEROKU_FRONTEND_APP/web;
heroku container:release web --app $HEROKU_FRONTEND_APP
on:
branch: main