diff --git a/.github/workflows/deploy_production.yml b/.github/workflows/deploy_production.yml index a42cc051..aa51801f 100644 --- a/.github/workflows/deploy_production.yml +++ b/.github/workflows/deploy_production.yml @@ -59,11 +59,13 @@ jobs: if [ $(sudo docker ps -q -f name=${{ env.CONTAINER_NAME_BLUE }}) ]; then sudo docker pull ${{ env.DOCKER_IMAGE_NAME }} sudo docker run --name ${{ env.CONTAINER_NAME_GREEN }} -d -p ${{ env.GREEN_PORT }}:${{ env.GREEN_PORT }} -e TZ=Asia/Seoul ${{ env.DOCKER_IMAGE_NAME }} + sleep 10 sudo docker stop ${{ env.CONTAINER_NAME_BLUE }} sudo docker rm ${{ env.CONTAINER_NAME_BLUE }} else sudo docker pull ${{ env.DOCKER_IMAGE_NAME }} sudo docker run --name ${{ env.CONTAINER_NAME_BLUE }} -d -p ${{ env.BLUE_PORT }}:${{ env.BLUE_PORT }} -e TZ=Asia/Seoul ${{ env.DOCKER_IMAGE_NAME }} + sleep 10 sudo docker stop ${{ env.CONTAINER_NAME_GREEN }} sudo docker rm ${{ env.CONTAINER_NAME_GREEN }} fi