Update README.md #39
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: SaroPay Github Action | |
on: push | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
max-parallel: 2 | |
matrix: | |
python-version: [3.x] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set Python Version ${{ matrix.python-version }} | |
uses: actions/setup-python@v4.7.0 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Lint with flake8 | |
run: | | |
flake8 . | |
- name: Run migrations | |
run: | | |
python manage.py migrate | |
- name: Runing the tests | |
run: | | |
python manage.py test | |
deploy: | |
runs-on: ubuntu-latest | |
name: deploy our django application to heroku | |
needs: [build] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Deploy app | |
uses: akhileshns/heroku-deploy@v3.12.14 # This is the action | |
with: | |
heroku_api_key: ${{secrets.HEROKU_API_KEY}} | |
heroku_app_name: ${{secrets.HEROKU_APP_NAME}} #Must be unique in Heroku | |
heroku_email: "johndbizz@gmail.com" | |
branch: "master" |