Skip to content

Commit

Permalink
Feat(#98): apply blue green deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
versatile0010 committed Feb 23, 2024
1 parent a97e6a5 commit 04dce63
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/jib-build-depoly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: NumberOne-Backend-JIB-BUILD-DEPLOY
# event trigger
on:
push:
branches: [ "dev", "dev-check", "feat/multi-module" ]
branches: [ "dev", "dev-check", "feat/deploy" ]

permissions: write-all

Expand Down Expand Up @@ -120,9 +120,10 @@ jobs:
key: ${{ secrets.EC2_PRIVATE_KEY }}
envs: GITHUB_SHA
script: |
sudo docker rm -f $(docker ps -qa)
sudo docker pull ${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_IMAGE }}:latest
docker-compose up -d
sudo docker pull ${{ secrets.DOCKER_USERNAME }}/${{ secrets.DOCKER_IMAGE }}
sudo chmod 777 ./scripts/deploy.sh
cp ./scripts/deploy.sh ./deploy.sh
./deploy.sh
docker image prune -f
## notify at Slack
Expand Down

0 comments on commit 04dce63

Please sign in to comment.