HEX
Server: nginx/1.22.0
System: Linux iZuf6jdxbygmf6cco977lcZ 5.10.84-10.4.al8.x86_64 #1 SMP Tue Apr 12 12:31:07 CST 2022 x86_64
User: root (0)
PHP: 7.4.29
Disabled: passthru,exec,system,chroot,chgrp,chown,shell_exec,proc_open,proc_get_status,ini_alter,ini_restore,dl,readlink,symlink,popepassthru,stream_socket_server,fsocket,popen
Upload Files
File: //usr/local/aegis/aegis_update/aegis_gentoo
#!/sbin/runscript
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

AEGIS_INSTALL_DIR="/usr/local/aegis"

if [ `id -u` -ne "0" ]; then
	echo "ERROR: Permission denied." 1>&2
	exit 1
fi

start() {
     "${AEGIS_INSTALL_DIR}"/aegis_update/AliYunDunUpdate -f agx_update.cfg
      sleep 1
      status
}

stop() {
	if [ -n "$1" ]; then
		killall -9 AliYunDunUpdate 2>/dev/null
		killall -9 AliYunDun 2>/dev/null
		killall -9 AliHids 2>/dev/null
	else
		echo "Disable Stop Aegis"
	fi
	
	sleep 1
	status
}

restart(){
	stop 1
	start
}

status(){
	if [ -n "$(ps -ef | grep AliYunDunUpdate | grep -v grep)" ]; then
		echo "Aegis is running"
	else
		echo "Aegis stopped"
	fi
}