1+ name : Push workflow
2+
3+ on :
4+ push :
5+ branches :
6+ - ' **'
7+
8+ jobs :
9+
10+ housekeeping :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - uses : actions/checkout@v1
14+ - name : Perform housekeeping checks
15+ env :
16+ GCLOUD_CONTAINER_AUTH : ${{ secrets.GCLOUD_CONTAINER_AUTH }}
17+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
18+ run : |
19+ source <(curl -sL http://ci.q-ctrl.com)
20+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-37 /scripts/housekeeping.sh
21+
22+ linting :
23+ runs-on : ubuntu-latest
24+ steps :
25+ - uses : actions/checkout@v1
26+ - name : Install Python dependencies
27+ env :
28+ GCLOUD_CONTAINER_AUTH : ${{ secrets.GCLOUD_CONTAINER_AUTH }}
29+ run : |
30+ source <(curl -sL http://ci.q-ctrl.com)
31+ ./ci vault login -r ${{ secrets.VAULT_ROLE_ID }} -s ${{ secrets.VAULT_SECRET_ID }}
32+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-37 /scripts/install-python-dependencies.sh
33+ - name : Run Pylint
34+ run : |
35+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-37 poetry run pylint_runner || true
36+ - name : Run Pylama
37+ run : |
38+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-37 poetry run pylama || true
39+ - name : Run Markdownlint
40+ run : |
41+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-37 mdl -- -ig . || true
42+
43+ pytest :
44+ runs-on : ubuntu-latest
45+ strategy :
46+ matrix :
47+ python : [36, 37]
48+ steps :
49+ - uses : actions/checkout@v1
50+ - name : Install Python dependencies
51+ env :
52+ GCLOUD_CONTAINER_AUTH : ${{ secrets.GCLOUD_CONTAINER_AUTH }}
53+ run : |
54+ source <(curl -sL http://ci.q-ctrl.com)
55+ ./ci vault login -r ${{ secrets.VAULT_ROLE_ID }} -s ${{ secrets.VAULT_SECRET_ID }}
56+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-${{ matrix.python }} /scripts/install-python-dependencies.sh
57+ - name : Run Pytest
58+ run : |
59+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-${{ matrix.python }} /scripts/pytest.sh
60+
61+ publish_internally :
62+ runs-on : ubuntu-latest
63+ steps :
64+ - uses : actions/checkout@v1
65+ - name : Publish development version
66+ env :
67+ GCLOUD_CONTAINER_AUTH : ${{ secrets.GCLOUD_CONTAINER_AUTH }}
68+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
69+ run : |
70+ source <(curl -sL http://ci.q-ctrl.com)
71+ ./ci vault login -r ${{ secrets.VAULT_ROLE_ID }} -s ${{ secrets.VAULT_SECRET_ID }}
72+ ./ci docker run asia.gcr.io/q-ctrl-api-development/python-37 /scripts/publish-dev-version.sh
0 commit comments