From 261c54e5492aa48edde342614f05c97853e5aa61 Mon Sep 17 00:00:00 2001 From: wjdtkdgns Date: Mon, 20 Nov 2023 13:21:16 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20workflow=20job=20=ED=86=B5=ED=95=A9=20#3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/Deploy.yml | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/.github/workflows/Deploy.yml b/.github/workflows/Deploy.yml index b21107be..13b89df7 100644 --- a/.github/workflows/Deploy.yml +++ b/.github/workflows/Deploy.yml @@ -48,13 +48,6 @@ jobs: docker build -t $DOCKERHUB_USERNAME/$DOCKERHUB_IMAGE_NAME:${{env.IMAGE_TAG}} . docker push $DOCKERHUB_USERNAME/$DOCKERHUB_IMAGE_NAME:${{env.IMAGE_TAG}} - deploy: - needs: build_and_push - runs-on: ubuntu-latest - steps: - - name: Set image tag from Output - run: echo "IMAGE_TAG=${{ needs.build_and_push.outputs.image_tag }}" >> $GITHUB_ENV - - name: Get Public IP id: publicip run: | @@ -92,7 +85,7 @@ jobs: sudo docker pull $DOCKERHUB_USERNAME/$DOCKERHUB_IMAGE_NAME:${{env.IMAGE_TAG}} sudo docker pull $DOCKERHUB_USERNAME/susu-nginx:0.0.1 sudo docker run --restart unless-stopped --name server --hostname server --env-file ~/susu/.env -e TZ=Asia/Seoul --expose 8080 --log-driver=awslogs --log-opt awslogs-group=susu --log-opt awslogs-region=ap-northeast-2 --log-opt awslogs-stream=server $DOCKERHUB_USERNAME/$DOCKERHUB_IMAGE_NAME:${{env.IMAGE_TAG}} -d - sudo docker run --name nginx --restart always -p 80:80 --depends-on server $DOCKERHUB_USERNAME/susu-nginx:0.0.1 -d + sudo docker run --name nginx --restart always -p 80:80 $DOCKERHUB_USERNAME/susu-nginx:0.0.1 -d sudo docker system prune --all -f