Skip to content

Commit

Permalink
feat : deploy.yml 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
jsilver01 committed Jul 30, 2024
1 parent d9ae68b commit 8866139
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,14 @@ jobs:
key: ${{ secrets.PRIVATE_KEY }}
port: ${{ secrets.WAS_PORT }}
script: |
echo "Checking Docker installation..."
CONTAINER_ID=$(sudo docker ps -q --filter ancestor=${{ secrets.DOCKER_HUB_USERNAME }}/${{ secrets.DOCKER_HUB_REPO_NAME }})
if [ ! -z "$CONTAINER_ID" ]; then
echo "Docker could not be found, installing Docker"
sudo docker stop $CONTAINER_ID
sudo docker rm $CONTAINER_ID
fi
echo "Pulling Docker image..."
sudo docker pull ${{ secrets.DOCKER_HUB_USERNAME }}/${{ secrets.DOCKER_HUB_REPO_NAME }}
sudo docker run -d -e PROFILE=${{ secrets.PROFILE }} \
-e DB_PROD_HOST=${{ secrets.DB_PROD_HOST }} \
Expand Down

0 comments on commit 8866139

Please sign in to comment.