SHARE
TWEET

Untitled

a guest Aug 12th, 2013 48 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. --- Startup Script ---
  2.  
  3. #!/bin/bash
  4. while true
  5.     do
  6. NOW="$(date +"%Y%m%d")"
  7.         /home/minetest/minetest/worldbackup.sh        
  8.  
  9.             /home/minetest/minetest/bin/minetestserver --config /home/minetest/minetest/private.conf \
  10.                 --worldname Beboh \
  11.                 --port 31000 \
  12.                 --logfile /home/minetest/minetest/logs/Beboh$NOW.txt
  13.  
  14.        sleep 5
  15. done
  16.  
  17.  
  18. --- worldbackup.sh ---
  19.  
  20. #!/bin/bash
  21.  
  22. NOW="$(date +"%Y%m%d-%H%M")"
  23. /bin/cp -Rv /home/minetest/minetest/worlds/Beboh /home/minetest/world-backups/Beboh$NOW
  24.  
  25. # symbolic link to the latest backup
  26. /bin/ln -sfn /home/minetest/world-backups/Beboh$NOW latest
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top