rendered paste body#!/bin/bash#############DECLARAR VARIABLES/PATHS/COMANDOSgui=/usr/bin/zenitylanpath=/root/lanmap_images/term=/usr/bin/urxvttemp=/tmp/tux_temp_fileapache_main_conf=/etc/apache2/apache2.confapache_site_conf=/etc/apache2/sites-available/defaultzz=sleep 2zzz=sleep 3back=tux-serverwi=300hi=250info_wi=400hide=--hide-column############################3echo -e "\tMenu de opciones de servidor"main_menu=`($gui --width=$wi --height=$hi --list --title="TUX-SERVER" --text="Opciones de servidor Tux.Server" --column="OP" --column="Opciones" "a" "Procesos" "b" "Apache2" "c" "Lanmap" "d" "Servidor FTP" "e" "Darkstat" "f" "Personal")`case $main_menu in a) ps -A | grep apache > $temp ps -A | grep darks >> $temp ps -A | grep lanmap >> $temp ps -A | grep pure >> $temp ps -A | grep sql >> $temp cat $temp | $gui --text-info --title="Procesos de servidor" $back_main ;; b) apache_menu=`($gui --list --width=$wi --height=$hi --title="Opciones servidor Apache2" --text="Escoge opción" --column="OP" --column="Opcines servidor" "a" "Concfiguración servidor" "b" "Configuración site" "c" "Iniciar" "d" "Reiniciar" "e" "Parar" "f" "Volver")` case $apache_menu in a) $term -e vi $apache_main_conf $back ;; b) $term -e vi $apache_site_conf $back ;; c) apache_start=`($gui --question --title="Apache2" --text="Lanzar servidor")` case $apache_start in 0) sh /etc/init.d/apache2 start | $gui --text-info --title="Info Apache2" $back ;; 1) $back ;; esac d) apache_restart=`($gui --question --title="Apache2" --text="Reiniciar servidor")` case $apache_restart in 0) sh /etc/init.d/apache2 force-reload | $gui --text-info --title="Info Apache2" $back ;; 1) $back ;; esac e) apache_stop=`($gui --question --title="Apache2" --text="Parar servidor")` case $apache_stop in 0) sh /etc/init.d/apache2 stop | $gui --text-info --title="Info Apache2" $back ;; 1) $back ;; esac f) $back ;; esacesacrm $temp