diff --git a/package-lock.json b/package-lock.json index 0616cab..5149a62 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "my-weekly-todo-list", - "version": "1.10.4", + "version": "1.10.5", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "my-weekly-todo-list", - "version": "1.10.4", + "version": "1.10.5", "license": "MIT", "dependencies": { "@auth/prisma-adapter": "^2.11.1", diff --git a/package.json b/package.json index fc9d4c3..3b62a02 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "my-weekly-todo-list", - "version": "1.10.4", + "version": "1.10.5", "description": "A web-based weekly task management application that organizes to-dos and calendar events in a single, intuitive weekly view", "main": "index.js", "scripts": { diff --git a/scripts/boot-update.sh b/scripts/boot-update.sh index 10992e6..98130fa 100755 --- a/scripts/boot-update.sh +++ b/scripts/boot-update.sh @@ -52,6 +52,11 @@ if [ ! -d "$NEXT_DIR" ] || [ "$LOCAL" != "$REMOTE" ]; then log "Building application..." npm run build 2>&1 | tee -a "$LOG_FILE" + + log "Preparing standalone directory (copying static assets)..." + cp -r public .next/standalone/ 2>&1 | tee -a "$LOG_FILE" + mkdir -p .next/standalone/.next/static 2>&1 | tee -a "$LOG_FILE" + cp -r .next/static .next/standalone/.next/ 2>&1 | tee -a "$LOG_FILE" fi log "=== Boot update finished (verified/rebuilt) ===" diff --git a/scripts/update-server.sh b/scripts/update-server.sh index ad12f95..f593c43 100755 --- a/scripts/update-server.sh +++ b/scripts/update-server.sh @@ -23,6 +23,11 @@ npx prisma generate echo -e "${YELLOW}Step 5: Building application...${NC}" npm run build +echo -e "${YELLOW}Step 5.5: Preparing standalone directory (copying static assets)...${NC}" +cp -r public .next/standalone/ +mkdir -p .next/standalone/.next/static +cp -r .next/static .next/standalone/.next/ + echo -e "${YELLOW}Step 6: Restarting server with PM2 (Standalone Mode)...${NC}" # Delete old process if it exists to ensure fresh config pm2 delete my-weekly-todo || true