fix: repair blue-green deployment architecture
Some checks failed
Deploy to OCIWP / deploy (push) Failing after 54s

This commit is contained in:
jade
2026-07-24 23:24:55 +09:00
parent c38d59887c
commit b5565a4da0
4 changed files with 19 additions and 9 deletions

View File

@@ -1,4 +1,4 @@
name: Deploy to OCIWP
name: Deploy to OCIWP
on:
push:
@@ -64,11 +64,18 @@ jobs:
sleep 5
ACTIVE_PROFILE=dev docker compose up -d tool-payment-$TARGET
# 4.5. ?<3F>거??컨테?<3F><20>?<3F><> (?<3F>트 충돌 방<EFBFBD>?, Nginx ?<3F>외)
# 4.5. 제거할 컨테이너 (포트 충돌 방, Nginx 외)
echo "Finding and killing legacy containers holding our ports..."
for port in 6379 8089 8281 8282 8283 8284 8285 8288; do
cid=$(docker ps -q --filter "publish=$port")
if [ ! -z "$cid" ]; then
echo "Force killing container $cid using port $port"
docker rm -f $cid
fi
done
# 4.6. Nginx 초기 ?<EFBFBD><EFBFBD>?기동
# 4.6. Nginx 초기 ?정 ?기동
mkdir -p ./nginx/conf.d
echo "Initializing Nginx config to $TARGET..."
cp ./nginx/${TARGET}.conf ./nginx/conf.d/default.conf

View File

@@ -46,6 +46,7 @@ services:
nginx:
image: nginx:latest
ports:
- "8281:8281"
- "8282:8282"
- "8283:8283"
- "8284:8284"
@@ -172,8 +173,6 @@ services:
build:
context: .
dockerfile: dap-gateway/Dockerfile
ports:
- "8281:8081"
volumes:
- ./:/src
depends_on:

View File

@@ -6,7 +6,9 @@ server {
listen 8281;
location / {
add_header Content-Type text/html;
return 200 '<html><body><h1>Nginx Static Page</h1></body></html>';
proxy_pass http://gateway;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}

View File

@@ -6,7 +6,9 @@ server {
listen 8281;
location / {
add_header Content-Type text/html;
return 200 '<html><body><h1>Nginx Static Page</h1></body></html>';
proxy_pass http://gateway;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}