Merge pull request #44 from akirachix/staging #54
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: Django CI/CD | |
on: | |
push: | |
branches: | |
- main | |
- staging | |
pull_request: | |
branches: | |
- main | |
- staging | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v3 | |
with: | |
python-version: '3.10' | |
- name: Install dependencies | |
run: | | |
pip install -r requirements.txt | |
- name: Set up Google Cloud Vision Credentials | |
env: | |
GOOGLE_VISION_CREDENTIALS: ${{ secrets.GOOGLE_VISION_CREDENTIALS }} | |
run: | | |
echo "GOOGLE_VISION_CREDENTIALS set successfully." | |
- name: Run migrations | |
run: | | |
python manage.py migrate | |
- name: Run tests | |
run: | | |
python manage.py test |