Current Path : /usr/local/ispmgr/sbin/ |
Current File : //usr/local/ispmgr/sbin/ispmgr-update.sh |
#!/bin/sh killall ispmgr sleep 2 killall -9 ispmgr chmod -f 600 /usr/local/ispmgr/etc/ispmgr.conf chmod -f 600 /etc/shadow chmod -f 600 /etc/master.passwd rm -f lib/pkgisp-www.so grep -v '^www:' etc/pkg-ispmgr.conf > etc/pkg-ispmgr.conf.tmp rm etc/pkg-ispmgr.conf mv etc/pkg-ispmgr.conf.tmp etc/pkg-ispmgr.conf chmod -fR 755 etc/www.skel if [ -f skins/userdata/mindterm.jar ]; then grep "extaction mindterm" etc/ispmgr.conf > /dev/null if [ $? -ne 0 ]; then echo "extaction mindterm /mancgi/mindterm" >> etc/ispmgr.conf fi fi if [ ! -s etc/filemgr.enc ]; then iconv -l | cut -f1 -d\ | tr -d / > etc/filemgr.enc fi if [ `uname` = "FreeBSD" ]; then grep security.bsd.hardlink_check_uid /etc/sysctl.conf if [ $? -ne 0 ]; then echo "security.bsd.hardlink_check_uid=1" >> /etc/sysctl.conf fi grep security.bsd.hardlink_check_gid /etc/sysctl.conf if [ $? -ne 0 ]; then echo "security.bsd.hardlink_check_gid=1" >> /etc/sysctl.conf fi sysctl security.bsd.hardlink_check_uid=1 sysctl security.bsd.hardlink_check_gid=1 fi rm -f lib/pkgisp-ihttpd.so /usr/local/ispmgr/sbin/mgrctl -m ispmgr promote.vote if [ `uname` = "FreeBSD" ]; then find /usr/local/ispmgr/etc -type f -iname '*.html' | xargs sed -I '' -r 's|href="http://ispsystem.com"|href="http://ispsystem.com/external/ispmanager.html"|' else find /usr/local/ispmgr/etc -type f -iname '*.html' | xargs sed -i -r 's|href="http://ispsystem.com"|href="http://ispsystem.com/external/ispmanager.html"|' fi