Skip to content

Commit

Permalink
Update deploy.yml without Docker
Browse files Browse the repository at this point in the history
  • Loading branch information
SaM-92 authored May 13, 2024
1 parent 88beff1 commit 2b4c5fd
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI/CD to Heroku with Docker
name: CI/CD to Heroku

on:
push:
Expand All @@ -13,20 +13,19 @@ jobs:
steps:
- uses: actions/checkout@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.8'

- name: Login to Heroku Container Registry
env:
HEROKU_API_KEY: ${{ secrets.HEROKU_API_KEY }}
run: echo $HEROKU_API_KEY | docker login --username=_ --password-stdin registry.heroku.com

- name: Build and push Docker image
- name: Install dependencies
run: |
docker buildx build --platform linux/amd64 --push -t registry.heroku.com/${{ secrets.HEROKU_APP_NAME }}/web .
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Release the Docker image
- name: Deploy to Heroku
env:
HEROKU_API_KEY: ${{ secrets.HEROKU_API_KEY }}
run: |
heroku container:release web -a ${{ secrets.HEROKU_APP_NAME }}
heroku git:remote -a ${{ secrets.HEROKU_APP_NAME }}
git push heroku main

0 comments on commit 2b4c5fd

Please sign in to comment.