-
Notifications
You must be signed in to change notification settings - Fork 2
47 lines (45 loc) · 1.15 KB
/
auth-v1.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
name: django-auth-microservice
on:
push:
branches: [ master, develop, feature/deploy ]
pull_request:
branches: [ master, develop ]
jobs:
build:
runs-on: ubuntu-latest
services:
postgres:
image: postgres:alpine
env:
POSTGRES_USER: root
POSTGRES_PASSWORD: pass
POSTGRES_DB: dan-auth
ports:
- 5432:5432
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
touch /tmp/fake.jwt.key
- name: Static analysis
run: |
./scripts/lint.sh
- name: Run migrations and tests
env:
SECRET_KEY: secret
ALLOWED_HOSTS: 127.0.0.1
DB_NAME: dan-auth
DB_USER: root
DB_PASSWORD: pass
DB_HOST: 127.0.0.1
DB_PORT: 5432
JWT_SIGNING_KEY_FILE_PATH: /tmp/fake.jwt.key
run: |
python manage.py migrate
pytest --ds=core.settings