X-Git-Url: https://www.hackdaworld.org/gitweb/?a=blobdiff_plain;f=backup.sh;h=57cb9e39e5a1faeff74e6f36244a9d35163413b2;hb=c3711e092b0b5bed6b27a439dd5a80c1ac89c52c;hp=1a1ebc86d6941c0abb20acfccc01f33701606e61;hpb=d3d8d91ee8fbc0715495bc70388eec68273bb4e3;p=scripts%2Fscripts.git diff --git a/backup.sh b/backup.sh index 1a1ebc8..57cb9e3 100755 --- a/backup.sh +++ b/backup.sh @@ -85,7 +85,7 @@ for i in $kernel_num; do done mkdir ./etc -for i in init.d conf opt ppp cups; do +for i in init.d conf opt ppp cups udev cron.d; do if [ -d /etc/$i ] ; then echo "copying /etc/$i" cp -r /etc/$i ./etc @@ -94,7 +94,8 @@ done for i in dhcpd.conf fstab hosts host.conf hosts.allow hosts.deny lilo.conf \ profile sendmail.cf resolv.conf exports fb.modes inetd.conf \ - xinetd.conf mp3user mp3db.conf; do + xinetd.conf mp3user mp3db.conf modules.conf named.conf \ + modprobe.devfs modprobe.conf devfsd.conf crontab; do if [ -f /etc/$i ] ; then echo "copying /etc/$i" cp /etc/$i ./etc @@ -106,6 +107,11 @@ if [ -f /etc/X11/XF86Config ] ; then echo "copying /etc/X11/XF86Config*" cp /etc/X11/XF86Config* ./etc/X11 fi +if [ -f /etc/X11/xorg.conf ] ; then + mkdir -p ./etc/X11 + echo "copying /etc/X11/xorg.conf*" + cp /etc/X11/xorg.conf* ./etc/X11 +fi # specific config stuff @@ -119,12 +125,37 @@ if [ "$host" = "gate" ] ; then cp -r /etc/mail ./etc fi + # mlsit procmail + if [ -d /home/mlist ] ; then + echo "copying mlist procmail config" + cp -r /home/mlist mlsit_pm_config + fi + # irc stuff mkdir -p ./ircd [ -f /etc/opt/unrealircd/unrealircd.conf ] && \ cp /etc/opt/unrealircd/unrealircd.conf ./ircd + + # minimalist stuff + mkdir -p ./minimalist + [ -f /etc/opt/minimalist/minimalist.conf ] && \ + cp /etc/opt/minimalist/minimalist.conf ./minimalist fi +# right-hand specific config stuff +if [ "$host" = "right-hand" ] ; then + if [ -d /var/named ] ; then + mkdir ./named + echo "copying dns data" + cp -r /var/named/* ./named + fi + if [ -f /etc/opt/apache*/httpd.conf ] ; then + mkdir ./apache + cp /etc/opt/apache*/httpd.conf ./apache + fi +fi + + # data stuff echo "data stuff:" @@ -158,34 +189,37 @@ if [ "$host" = "hackstation" -o "$host" = "mobile" -o "$host" = "hdw" -o "$host" # home of hackbard mkdir -p ./home/hackbard - echo "copying home" - for i in software store; do + echo -n "copying home ..." + for i in temp test; do + echo -n " $i," [ -d /home/hackbard/$i ] && \ cp -r /home/hackbard/$i ./home/hackbard done - if [ "$host" = "hackstation" ]; then - [ -d /home/hackbard/projects ] && \ - cp -r /home/hackbard/projects ./home/hackbard - fi for i in xinitrc_evil xinitrc_wm .xinitrc GNUstep .Xauthority \ - .Xdefaults .signature .directfbrc .bashrc; do - [ -f /home/hackbard/$i ] && \ + .Xdefaults .XHkeys .signature .directfbrc .bashrc \ + sp12 .licq .irssi; do + echo -n " $i," + [ -e /home/hackbard/$i ] && \ cp -r /home/hackbard/$i ./home/hackbard done + [ -d /home/hackbard/.mozilla ] && + cp /home/hackbard/.mozilla/*/*/bookmarks.html \ + mozilla-bookmarks.html [ -d /home/hackbard/.ssh ] && cp -r /home/hackbard/.ssh ./home/hackbard + echo " done." # tftpboot if [ -d /tftpboot ] ; then mkdir -p ./tftpboot - echo "copyinf tftpboot stuff" + echo "copying tftpboot stuff" cp -r /tftpboot/* ./tftpboot fi - # hunz config - for i in prism lucent; do - if [ -f /root/hunz_${i}.sh ]; then + # wlan configs + for i in hunz_prism hunz_lucent roman_orinoco.sh; do + if [ -f /root/${i}.sh ]; then mkdir -p ./root - cp /root/hunz_${i}.sh ./root + cp /root/${i}.sh ./root fi done