-
Notifications
You must be signed in to change notification settings - Fork 55
72 lines (67 loc) · 2.06 KB
/
ci.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: Django CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: ['py38']
django-version: ['django42']
db-version: ['mysql80']
steps:
- uses: actions/checkout@v2
- name: Start container
run: |
docker-compose -f .ci/docker-compose-ci.yml up -d
- name: Install Dependencies
run: |
docker exec -e TOXENV=${{ matrix.python-version }}-${{ matrix.django-version }} --env DB_HOST=${{ matrix.db-version }} -u root edx_notes_api \
/bin/bash -c "apt-get update && apt-get install python3-dev default-libmysqlclient-dev build-essential pkg-config"
- name: Run Tests
run: |
docker exec -e TOXENV=${{ matrix.python-version }}-${{ matrix.django-version }} --env DB_HOST=${{ matrix.db-version }} -u root edx_notes_api /edx/app/edx_notes_api/edx_notes_api/.ci/run_tests.sh
- name: Run PII Check
run: |
docker exec -e TOXENV=${{ matrix.python-version }}-${{ matrix.django-version }} -u root edx_notes_api /edx/app/edx_notes_api/edx_notes_api/.ci/run_pii_checker.sh
- name: Run Reserved Keywords Check
run: |
docker exec -e TOXENV=${{ matrix.python-version }}-${{ matrix.django-version }} -u root edx_notes_api /edx/app/edx_notes_api/edx_notes_api/.ci/run_check_keywords.sh
#name: Python CI
#
#on:
# push:
# branches: [ master ]
# pull_request:
# branches: [ master ]
#
#jobs:
# build:
#
# runs-on: ubuntu-latest
# strategy:
# max-parallel: 4
# matrix:
# python-version: ['3.8']
# db-version: ['mysql80']
# toxenv: [django42]
#
# steps:
# - uses: actions/checkout@v2
#
# - name: Python setup
# uses: actions/setup-python@v2
# with:
# python-version: ${{ matrix.python-version }}
#
# - name: Install Requirements
# run: |
# pip install -r requirements/pip.txt
# pip install -r requirements/ci.txt
#
# - name: Run Tests
# run: tox -e ${{ matrix.toxenv }}