260304:1240 20260304:1200 update app to lcbp3 #2
Some checks failed
Build and Deploy / deploy (push) Failing after 1m6s

This commit is contained in:
admin
2026-03-04 12:40:27 +07:00
parent ad77a2ae94
commit c58b02f6b5
2 changed files with 8 additions and 6 deletions

View File

@@ -48,7 +48,7 @@ jobs:
cp /share/np-dms/app/source/lcbp3/specs/04-Infrastructure-OPS/04-00-docker-compose/docker-compose-app.yml /share/np-dms/app/docker-compose-app.yml cp /share/np-dms/app/source/lcbp3/specs/04-Infrastructure-OPS/04-00-docker-compose/docker-compose-app.yml /share/np-dms/app/docker-compose-app.yml
cd /share/np-dms/app cd /share/np-dms/app
# ⚠️ ลบ container เดิมที่อาจสร้างจาก Container Station # ⚠️ ลบ container เดิมที่อาจสร้างจาก Container Station
docker rm -f lcbp3-backend lcbp3-frontend 2>/dev/null || true docker rm -f backend frontend 2>/dev/null || true
# 4a. Start Backend ก่อน # 4a. Start Backend ก่อน
echo "🟢 Starting Backend..." echo "🟢 Starting Backend..."
@@ -57,7 +57,7 @@ jobs:
# 4b. รอ Backend healthy (ทุก 5 วิ สูงสุด 60 วิ) # 4b. รอ Backend healthy (ทุก 5 วิ สูงสุด 60 วิ)
echo "⏳ Waiting for Backend health check..." echo "⏳ Waiting for Backend health check..."
for i in $(seq 1 12); do for i in $(seq 1 12); do
if docker inspect --format='{{.State.Health.Status}}' lcbp3-backend 2>/dev/null | grep -q healthy; then if docker inspect --format='{{.State.Health.Status}}' backend 2>/dev/null | grep -q healthy; then
echo "✅ Backend is healthy!" echo "✅ Backend is healthy!"
break break
fi fi

View File

@@ -13,6 +13,8 @@
# ใช้ Environment Variables ใน Container Station UI # ใช้ Environment Variables ใน Container Station UI
# ============================================================ # ============================================================
name: lcbp3
x-restart: &restart_policy x-restart: &restart_policy
restart: unless-stopped restart: unless-stopped
@@ -30,12 +32,12 @@ networks:
services: services:
# ---------------------------------------------------------------- # ----------------------------------------------------------------
# 1. Backend API (NestJS) # 1. Backend API (NestJS)
# Service Name: backend (ตามที่ NPM อ้างอิง → lcbp3-backend:3000) # Service Name: backend (ตามที่ NPM อ้างอิง → backend:3000)
# ---------------------------------------------------------------- # ----------------------------------------------------------------
backend: backend:
<<: [*restart_policy, *default_logging] <<: [*restart_policy, *default_logging]
image: lcbp3-backend:latest image: lcbp3-backend:latest
container_name: lcbp3-backend container_name: backend
stdin_open: true stdin_open: true
tty: true tty: true
deploy: deploy:
@@ -89,12 +91,12 @@ services:
# ---------------------------------------------------------------- # ----------------------------------------------------------------
# 2. Frontend Web App (Next.js) # 2. Frontend Web App (Next.js)
# Service Name: frontend (ตามที่ NPM อ้างอิง → lcbp3-frontend:3000) # Service Name: frontend (ตามที่ NPM อ้างอิง → frontend:3000)
# ---------------------------------------------------------------- # ----------------------------------------------------------------
frontend: frontend:
<<: [*restart_policy, *default_logging] <<: [*restart_policy, *default_logging]
image: lcbp3-frontend:latest image: lcbp3-frontend:latest
container_name: lcbp3-frontend container_name: frontend
stdin_open: true stdin_open: true
tty: true tty: true
deploy: deploy: