diff --git a/.gitignore b/.gitignore index 7ace852..357e9e6 100644 --- a/.gitignore +++ b/.gitignore @@ -4,7 +4,6 @@ node_modules/ *.db *.db-shm *.db-wal -client/build/ .DS_Store npm-debug.log* yarn-debug.log* @@ -13,3 +12,4 @@ yarn-error.log* .idea/ deploy-package/ data/*.db +# Note: client/build/ is included for low-memory deployments diff --git a/install-ubuntu.sh b/install-ubuntu.sh index dccf763..ee7a91d 100644 --- a/install-ubuntu.sh +++ b/install-ubuntu.sh @@ -77,13 +77,18 @@ echo "" echo "Step 5: Installing dependencies..." npm install --production -# Build client +# Build client (skip if build folder exists - for low-memory servers) echo "" -echo "Step 6: Building frontend..." -cd client -npm install -npm run build -cd .. +echo "Step 6: Setting up frontend..." +if [ ! -d "client/build" ]; then + echo "Building frontend (this may take 10-15 minutes on low-memory servers)..." + cd client + npm install + npm run build + cd .. +else + echo "Using pre-built frontend" +fi # Setup configuration echo ""