From c79367cbf98951cbbab947e55d8e6edce28f8586 Mon Sep 17 00:00:00 2001 From: junseoplee Date: Wed, 11 Sep 2024 15:53:11 +0900 Subject: [PATCH] =?UTF-8?q?chore:=20=EB=A0=88=EB=94=94=EC=8A=A4=20?= =?UTF-8?q?=EA=B4=80=EB=A0=A8=20=EC=84=A4=EC=A0=95=20(#6)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/someup_dev.yml | 1 + docker-compose.yml | 17 +++++++++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.github/workflows/someup_dev.yml b/.github/workflows/someup_dev.yml index 8c774fa..c5d5f79 100644 --- a/.github/workflows/someup_dev.yml +++ b/.github/workflows/someup_dev.yml @@ -90,6 +90,7 @@ jobs: - name: Add GitHub IP to AWS run: | aws ec2 authorize-security-group-ingress --group-id ${{ secrets.AWS_SG_ID }} --protocol tcp --port 22 --cidr ${{ steps.ip.outputs.ipv4 }}/32 + # docker-compose.yml 파일 EC2로 복사 - name: Copy docker-compose.yml to EC2 uses: appleboy/scp-action@master diff --git a/docker-compose.yml b/docker-compose.yml index e2dbe41..942f3d9 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,9 +1,7 @@ -version: '3' - services: springboot: - container_name: someup-dev # ec2내에서 동작하는 컨테이너명 - image: junseoplee/someup:latest + container_name: someup # ec2내에서 동작하는 컨테이너명 + image: someupsite/someup:latest ports: - 8080:8080 environment: @@ -11,6 +9,17 @@ services: networks: - my_network + redis: + image: redis + container_name: redis-cache + environment: + REDIS_PASSWORD: password + command: ["redis-server", "--requirepass", "password", "--port", "6379"] + ports: + - 6379:6379 + networks: + - my_network + networks: my_network: driver: bridge