image tag #35
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Python CI | |
on: [push, pull_request] | |
jobs: | |
build: | |
environment: | |
name: testing | |
runs-on: ubuntu-latest | |
steps: | |
- name: pulling git repo | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.8 | |
- name: Install Chromium | |
run: sudo apt-get install -y chromium-browser | |
- name: update pip | |
run: python -m pip install --upgrade pip | |
- name: Install dependencies | |
run: pip install -r requirements.txt | |
- name: Start Flask App | |
run: gunicorn main:app --bind=0.0.0.0:5000 & | |
- name: Wait for Flask App to Start | |
run: sleep 10 | |
- name: Check Flask App Status | |
run: curl http://localhost:5000 | |
- name: test with pytest | |
run: pytest | |