Skip to content

Commit

Permalink
fix: docker-push-cd.yml 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
KimChanJin97 authored Jul 18, 2024
1 parent c2354cd commit de1c8f7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/docker-push-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ jobs:
- name: Deploy to Prod
uses: appleboy/ssh-action@master
id: deploy-prod
env:
COMPOSE: "/home/app/compose/docker-compose.yml"
with:
host: ${{ secrets.EC2_HOST }}
username: ${{ secrets.EC2_USERNAME }}
key: ${{ secrets.EC2_PRIVATE_KEY }}
port: 22
envs: GITHUB_SHA
script: |
docker stop facefriend
docker rm facefriend
sudo docker-compose -f $COMPOSE down
sudo docker pull ${{ secrets.DOCKER_REPO }}/facefriend
docker run -d --name facefriend -p 8080:8080 ${{ secrets.DOCKER_REPO }}/facefriend
docker rmi -f $(docker images -f "dangling=true" -q)
sudo docker-compose -f $COMPOSE up -d

0 comments on commit de1c8f7

Please # to comment.