-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (34 loc) · 1.19 KB
/
app_workflow.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
name: App workflow
on:
push:
branches:
- main
env:
PYTHON_VERSION: 3.11
jobs:
app_workflow:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Install Poetry
run: |
curl -sSL https://install.python-poetry.org | python${{ env.PYTHON_VERSION }} - && \
$HOME/.local/bin/poetry config virtualenvs.in-project true && \
$HOME/.local/bin/poetry config virtualenvs.options.always-copy true && \
$HOME/.local/bin/poetry config virtualenvs.path "venv"
- name: Install project dependencies
run: |
$HOME/.local/bin/poetry install
- name: Run unittests
run: |
. .venv/bin/activate && \
python -m unittest discover --start-directory './console' --pattern 'test_*.py' --verbose
- name: Deploy app
run: |
deployment_trigger_api_response=$(curl -s "${{ secrets.RENDER_PLATFORM_DEPLOY_HOOK }}") && \
echo "Deployment trigger API response: $deployment_trigger_api_response"