Create identity_management.py #2
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: Deploy to Heroku | |
on: | |
push: | |
branches: | |
- main # Change this to your default branch if it's different | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.11' # Specify the Python version you want to use | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Run tests | |
run: | | |
python -m unittest discover -s tests/unit | |
- name: Deploy to Heroku | |
env: | |
HEROKU_API_KEY: ${{ secrets.HEROKU_API_KEY }} # Set this in your GitHub repository secrets | |
run: | | |
curl https://cli-assets.heroku.com/install.sh | sh | |
heroku auth:token | |
heroku git:remote -a your-heroku-app-name # Replace with your Heroku app name | |
git push heroku main # Change 'main' if your default branch is different |