feat(deployment): add automated swap space configuration
- Create `scripts/setup-swap.sh` to dynamically detect and allocate a 4GB swap file to prevent OOM errors on low-RAM servers. - Integrate the swap check gracefully into the `run.sh` orchestrator flow. - Update `README.md` to document new sudo/disk space prerequisites and the updated deployment steps.
This commit is contained in:
9
run.sh
9
run.sh
@@ -44,6 +44,15 @@ fi
|
||||
|
||||
echo -e "${GREEN}[OK] Critical variables are valid.${NC}\n"
|
||||
|
||||
echo -e "${GREEN}[OK] Critical variables are valid.${NC}\n"
|
||||
|
||||
if [ -f "./scripts/setup-swap.sh" ]; then
|
||||
bash ./scripts/setup-swap.sh
|
||||
else
|
||||
echo -e "${YELLOW}[WARNING] ./scripts/setup-swap.sh not found. Skipping swap check.${NC}"
|
||||
fi
|
||||
echo ""
|
||||
|
||||
read -p "Do you want to run the auto-tune script to optimize GitLab for this server's RAM/CPU? (y/n): " -n 1 -r
|
||||
echo
|
||||
if [[ $REPLY =~ ^[Yy]$ ]]; then
|
||||
|
||||
Reference in New Issue
Block a user