Files
phishingclub/frontend/dev.sh
Ronni Skansing 0504602ff5 update build for lower mem
Signed-off-by: Ronni Skansing <rskansing@gmail.com>
2026-06-14 21:17:23 +02:00

14 lines
481 B
Bash
Executable File

#/bin/bash
# install dependencies when the vite binary is missing.
# checking for the binary instead of the node_modules directory means a partial
# install (for example one killed by the OOM killer) is retried instead of being
# skipped forever, which would leave the dev server crash looping on "vite: not found"
if [ ! -x "node_modules/.bin/vite" ]; then
npm install
fi
while true; do \
npm run dev; \
echo "Process crashed! Restarting in 10 seconds..."; \
sleep 10; \
done