-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (40 loc) · 1.28 KB
/
ci.yml
File metadata and controls
42 lines (40 loc) · 1.28 KB
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
name: CI
on:
push:
branches:
- main
paths-ignore:
- "**.md"
jobs:
integration:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Build image
run: docker compose -f docker-compose.test.yml --profile ci build
- name: Run tests
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: ${{ secrets.AWS_REGION }}
CLONE_QUEUE: ${{ secrets.CLONE_QUEUE }}
run: docker compose -f docker-compose.test.yml run --no-TTY test-ci # `--no-TTY` is necessary for showing streaming logs
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage/reports/coverage.xml
fail_ci_if_error: true
deploy:
needs: integration
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Deploy to Heroku
uses: akhileshns/heroku-deploy@v3.12.12
with:
heroku_api_key: ${{ secrets.HEROKU_API_KEY }}
heroku_app_name: codepraise-api-python
heroku_email: as10896@gmail.com
stack: container