slitaz-tools diff tinyutils/serverbox @ rev 709
tazkeymap: typo (thanks Darjeeling)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Mar 14 09:44:20 2012 +0100 (2012-03-14) |
parents | 7fdb586cf6bf |
children |
line diff
1.1 --- a/tinyutils/serverbox Mon Feb 07 12:08:47 2011 +0100 1.2 +++ b/tinyutils/serverbox Wed Mar 14 09:44:20 2012 +0100 1.3 @@ -23,16 +23,14 @@ 1.4 tab_status_servers() 1.5 { 1.6 local servers 1.7 -servers="dropbear sshd inetd dhcpd dnsd named rsync httpd mbd vnc pppd knock postfix fetchmail cyrus perdition slapd sql squid" 1.8 +servers="dropbear sshd inetd dhcpd dnsd named rsync httpd mbd vnc pppd \ 1.9 +knock postfix fetchmail cyrus perdition slapd sql squid slim cron ntp nfsd \ 1.10 +ftpd cups" 1.11 cat <<EOT 1.12 -<frame Servers> 1.13 - <text use-markup="true"> 1.14 - <label>"<b>Running servers :</b>"</label> 1.15 - </text> 1.16 - <text wrap="false" width-chars="58"> 1.17 - <input>for i in $servers; do ps ww | grep \$i | grep -v grep | fold -s; done</input> 1.18 - </text> 1.19 -</frame> 1.20 +<tree> 1.21 + <label>Server processes</label> 1.22 + <input>for i in $servers; do ps ww | grep \$i | grep -v grep; done</input> 1.23 +</tree> 1.24 EOT 1.25 } 1.26 1.27 @@ -89,7 +87,7 @@ 1.28 1.29 cat <<EOT 1.30 <frame Dropbear> 1.31 -$(helpdaemon dropbear 80x30 DROPBEAR_OPTIONS DROPBEAR_OPTS) 1.32 +$(helpdaemon dropbear 80x35 DROPBEAR_OPTIONS DROPBEAR_OPTS) 1.33 $(datafile /etc/dropbear/banner DROPBEAR_BANNER 'Banner :') 1.34 $(sshremote DROPBEAR_PEER 'dbclient -i /etc/dropbear/dropbear_rsa_host_key') 1.35 <hbox> 1.36 @@ -139,13 +137,13 @@ 1.37 { 1.38 cat <<EOT 1.39 <frame Inetd (busybox)> 1.40 -$(helpdaemon inetd 60x14 INETD_OPTIONS INETD_OPTS) 1.41 +$(helpdaemon inetd 60x20 INETD_OPTIONS INETD_OPTS) 1.42 $(configfile /etc/inetd.conf INETD_CONF) 1.43 <hbox> 1.44 EOT 1.45 for i in $(grep bin /etc/inetd.conf | awk '{ print $6}'); do 1.46 i=$(basename $i) 1.47 - helpbutton $i 60x19 $i 1.48 + helpbutton $i 60x24 $i 1.49 done 1.50 cat <<EOT 1.51 $(startstopdaemon inetd) 1.52 @@ -171,7 +169,7 @@ 1.53 fi 1.54 cat <<EOT 1.55 <frame Zcip (busybox)> 1.56 -$(helpdaemon zcip 60x14 ZCIP_OPTIONS ZCIP_OPTS) 1.57 +$(helpdaemon zcip 60x20 ZCIP_OPTIONS ZCIP_OPTS) 1.58 $(datafile /etc/zcip.script CZIP_SCRIPT 'Script :') 1.59 <hbox> 1.60 $(startstopdaemon zcip) 1.61 @@ -203,7 +201,7 @@ 1.62 { 1.63 cat <<EOT 1.64 <frame Udhcpd (busybox)> 1.65 -$(helpdaemon udhcpd 60x14 UDHCPD_OPTIONS UDHCPD_OPTS) 1.66 +$(helpdaemon udhcpd 60x18 UDHCPD_OPTIONS UDHCPD_OPTS) 1.67 $(configfile /etc/udhcpd.conf UDHCPD_CONF) 1.68 <hbox> 1.69 $(startstopdaemon udhcpd busybox) 1.70 @@ -346,7 +344,7 @@ 1.71 { 1.72 cat <<EOT 1.73 <frame Dnsd (busybox master dns)> 1.74 -$(helpdaemon dnsd 80x15 DNSD_OPTIONS DNSD_OPTS) 1.75 +$(helpdaemon dnsd 80x24 DNSD_OPTIONS DNSD_OPTS) 1.76 $(configfile /etc/dnsd.conf DNSD_CONF) 1.77 <hbox> 1.78 $(startstopdaemon dnsd busybox) 1.79 @@ -412,7 +410,6 @@ 1.80 { 1.81 cat <<EOT 1.82 <frame Postfix> 1.83 -$(webbutton postfix) 1.84 $(configfile /etc/postfix/main.cf POSTFIX_CONF) 1.85 <hbox> 1.86 $(startstopdaemon postfix) 1.87 @@ -428,7 +425,6 @@ 1.88 { 1.89 cat <<EOT 1.90 <frame Fetchmail> 1.91 -$(webbutton fetchmail) 1.92 $(helpdaemon fetchmail 100x34 FETCHMAIL_OPTIONS FETCHMAIL_OPTS) 1.93 $(configfile /etc/fetchmail.conf FETCHMAIL_CONF) 1.94 <hbox> 1.95 @@ -446,7 +442,6 @@ 1.96 cat <<EOT 1.97 <frame Postgrey (SMTP grey list)> 1.98 $(helpdaemon postgrey 100x34 POSTGREY_OPTIONS POSTGREY_OPTS) 1.99 -$(webbutton postgrey) 1.100 <hbox> 1.101 $(startstopdaemon postgrey) 1.102 </hbox> 1.103 @@ -477,8 +472,7 @@ 1.104 tab_cyrus() 1.105 { 1.106 cat <<EOT 1.107 - <frame Cyrus IMAP> 1.108 -$(webbutton cyrus-imapd) 1.109 + <frame Cyrus IMAP/POP3> 1.110 $(configfile /etc/imapd.conf IMAPD_CONF) 1.111 $(configfile /etc/cyrus.conf CYRUS_CONF) 1.112 <hbox> 1.113 @@ -494,8 +488,7 @@ 1.114 tab_perdition() 1.115 { 1.116 cat <<EOT 1.117 - <frame Perdition proxy> 1.118 -$(webbutton perdition) 1.119 + <frame Perdition IMAP/POP3 proxy> 1.120 $(helpdaemon perdition 100x34 PERDITION_OPTIONS PERDITION_OPTS) 1.121 $(configfile /etc/perdition/perdition.imap4.conf PROXY_IMAP_CONF) 1.122 $(configfile /etc/perdition/perdition.pop3.conf PROXY_POP3_CONF) 1.123 @@ -529,8 +522,7 @@ 1.124 { 1.125 cat <<EOT 1.126 <frame Squid> 1.127 -$(helpdaemon squid 100x34 SQUID_OPTIONS SQUID_OPTS) 1.128 -$(webbutton squid) 1.129 +$(helpdaemon squid 100x26 SQUID_OPTIONS SQUID_OPTS) 1.130 $(configfile /etc/squid.conf SQUID_CONF) 1.131 $([ -s /etc/squidGuard/squidGuard.conf ] && configfile /etc/squidGuard/squidGuard.conf SQUIDGUARD_CONF) 1.132 <hbox> 1.133 @@ -547,7 +539,6 @@ 1.134 { 1.135 cat <<EOT 1.136 <frame Asterisk telephony> 1.137 -$(webbutton asterisk) 1.138 $(configfile /etc/asterisk/extensions.conf ASTERISK_CONF) 1.139 <hbox> 1.140 $(startstopdaemon asterisk) 1.141 @@ -563,8 +554,6 @@ 1.142 { 1.143 cat <<EOT 1.144 <frame OpenLDAP> 1.145 -$(helpdaemon /usr/libexec/slapd 100x34 LDAP_OPTIONS LDAP_OPTS) 1.146 -$(webbutton openldap) 1.147 $(configfile /etc/openldap/slapd.conf LDAP_CONF) 1.148 <hbox> 1.149 $(startstopdaemon openldap) 1.150 @@ -580,8 +569,7 @@ 1.151 { 1.152 cat <<EOT 1.153 <frame MySQL> 1.154 -$(helpdaemon mysqld_safe 100x34 MYSQL_OPTIONS MYSQL_OPTS) 1.155 -$(webbutton mysql) 1.156 +$(helpdaemon mysqld_safe 100x24 MYSQL_OPTIONS MYSQL_OPTS) 1.157 $(configfile /etc/my.conf MYSQL_CONF) 1.158 <hbox> 1.159 $(startstopdaemon mysql) 1.160 @@ -598,7 +586,6 @@ 1.161 cat <<EOT 1.162 <frame PostgreSQL> 1.163 $(helpdaemon postgres 100x34 PGSQL_OPTIONS PGSQL_OPTS) 1.164 -$(webbutton postgresql) 1.165 $(configfile /etc/postgresql.conf POSTGRESQL_CONF) 1.166 <hbox> 1.167 $(startstopdaemon postgresql) 1.168 @@ -624,6 +611,179 @@ 1.169 } 1.170 1.171 # 1.172 +# Slim display manager 1.173 +# 1.174 +tab_slim() 1.175 +{ 1.176 +cat <<EOT 1.177 + <frame Slim display manager> 1.178 +$(helpdaemon slim 80x10 SLIM_OPTIONS SLIM_OPTS) 1.179 +$(configfile /etc/slim.conf SLIM_CONF) 1.180 + <hbox> 1.181 + $(startstopdaemon slim) 1.182 + </hbox> 1.183 + </frame> 1.184 +EOT 1.185 +} 1.186 + 1.187 +# 1.188 +# Cron 1.189 +# 1.190 +tab_cron() 1.191 +{ 1.192 +cat <<EOT 1.193 + <frame Crond (busybox)> 1.194 +$(helpdaemon crond 80x15 CROND_OPTIONS CROND_OPTS) 1.195 + <hbox> 1.196 + $(startstopdaemon crond) 1.197 + </hbox> 1.198 + </frame> 1.199 +EOT 1.200 +} 1.201 + 1.202 +# 1.203 +# NTP 1.204 +# 1.205 +tab_ntp() 1.206 +{ 1.207 +cat <<EOT 1.208 + <frame Ntpd> 1.209 +$(helpdaemon ntpd 100x34 NTP_OPTIONS NTP_OPTS) 1.210 +$(configfile /etc/ntp.conf NTP_CONF) 1.211 + <hbox> 1.212 + $(startstopdaemon ntp) 1.213 + </hbox> 1.214 + </frame> 1.215 +EOT 1.216 +} 1.217 + 1.218 +# 1.219 +# nfsd 1.220 +# 1.221 +tab_nfsd() 1.222 +{ 1.223 +cat <<EOT 1.224 + <frame Nfsd> 1.225 +$(configfile /etc/exports EXPORTS) 1.226 + <hbox> 1.227 + $(startstopdaemon nfsd nfs-utils) 1.228 + </hbox> 1.229 + </frame> 1.230 +EOT 1.231 +} 1.232 + 1.233 +# 1.234 +# unfsd 1.235 +# 1.236 +tab_unfsd() 1.237 +{ 1.238 +cat <<EOT 1.239 + <frame Unfsd> 1.240 +$(helpdaemon ntpd 80x20 UNFSD_OPTIONS UNFSD_OPTS) 1.241 +$(configfile /etc/exports EXPORTS) 1.242 + <hbox> 1.243 + $(startstopdaemon unfsd unfs3) 1.244 + </hbox> 1.245 + </frame> 1.246 +EOT 1.247 +} 1.248 + 1.249 +data_nfs() 1.250 +{ 1.251 +cat <<EOT 1.252 +rpc.nfsd Nfsd tab_nfsd 1.253 +unfsd Unfsd tab_unfsd 1.254 +EOT 1.255 +} 1.256 + 1.257 +# 1.258 +# nfs tab 1.259 +# 1.260 +tab_nfs() 1.261 +{ 1.262 +use_tab data_nfs 1.263 +} 1.264 + 1.265 +# 1.266 +# ftpd 1.267 +# 1.268 +tab_ftpd() 1.269 +{ 1.270 +cat <<EOT 1.271 + <frame ftpd> 1.272 +$(helpdaemon ftpd 100x34 FTPD_OPTIONS FTPD_OPTS) 1.273 + <hbox> 1.274 + $(startstopdaemon ftpd) 1.275 + </hbox> 1.276 + </frame> 1.277 +EOT 1.278 +} 1.279 + 1.280 +# 1.281 +# pure-ftpd 1.282 +# 1.283 +tab_pureftpd() 1.284 +{ 1.285 +cat <<EOT 1.286 + <frame pure-ftpd> 1.287 +$(helpdaemon pure-ftpd 80x34 PUREFTPD_OPTIONS PUREFTPD_OPTS) 1.288 + <hbox> 1.289 + $(startstopdaemon pure-ftpd) 1.290 + </hbox> 1.291 + </frame> 1.292 +EOT 1.293 +} 1.294 + 1.295 +data_ftp() 1.296 +{ 1.297 +cat <<EOT 1.298 +$(readlink /usr/bin/ftpd | grep -q busybox && echo "true" || 1.299 +echo "#") Busybox\ ftpd tab_ftpd 1.300 +pure-ftpd pure-ftpd tab_pureftpd 1.301 +EOT 1.302 +} 1.303 + 1.304 +# 1.305 +# ftp tab 1.306 +# 1.307 +tab_ftp() 1.308 +{ 1.309 +use_tab data_ftp 1.310 +} 1.311 + 1.312 +# 1.313 +# NTP 1.314 +# 1.315 +tab_ntp() 1.316 +{ 1.317 +cat <<EOT 1.318 + <frame Ntpd> 1.319 +$(helpdaemon ntpd 80x20 NTP_OPTIONS NTP_OPTS) 1.320 +$(configfile /etc/ntp.conf NTP_CONF) 1.321 + <hbox> 1.322 + $(startstopdaemon ntp) 1.323 + </hbox> 1.324 + </frame> 1.325 +EOT 1.326 +} 1.327 + 1.328 +# 1.329 +# cups 1.330 +# 1.331 +tab_cups() 1.332 +{ 1.333 +cat <<EOT 1.334 + <frame Cupsd> 1.335 +$(helpdaemon cupsd 80x12 CUPSD_OPTIONS CUPSD_OPTS) 1.336 +$(configfile /etc/cups/cupsd.conf CUPSD_CONF) 1.337 + <hbox> 1.338 + $(startstopdaemon cupsd) 1.339 + </hbox> 1.340 + </frame> 1.341 +EOT 1.342 +} 1.343 + 1.344 +# 1.345 # rsync server 1.346 # 1.347 tab_rsync() 1.348 @@ -705,6 +865,7 @@ 1.349 /etc/apache/httpd.conf Apache tab_apache 1.350 lighttpd Lighttpd tab_lighttpd 1.351 /etc/httpd.conf Busybox\ httpd tab_httpd 1.352 +squid Web\ cache tab_squid 1.353 EOT 1.354 } 1.355 1.356 @@ -788,31 +949,37 @@ 1.357 [ -x /usr/sbin/dnsmasq ] && pxe="true" 1.358 [ -f /usr/share/boot/pxelinux.0.lzma -o /usr/share/boot/gpxe.pxe ] || pxe="#" 1.359 cat <<EOT 1.360 -$([ -x /usr/sbin/dropbear -o -x /usr/sbin/sshd ] && echo "true" || 1.361 -echo "#") SSH tab_sshd 1.362 -$([ -x /usr/sbin/lighttpd -o -x /usr/bin/httpd ] && echo "true" || 1.363 -echo "#") HTTP tab_http 1.364 -rsync Rsync tab_rsync 1.365 -smbd SAMBA tab_wins 1.366 +slim Slim tab_slim 1.367 +crond Crond tab_cron 1.368 inetd Inetd tab_inetd 1.369 zcip ZeroConf tab_zcip 1.370 $([ -x /usr/sbin/udhcpd -o -x /usr/sbin/dhcpd -o -x /usr/sbin/dnsmasq ] && 1.371 echo "true" || 1.372 echo "#") DHCP tab_dhcpd 1.373 $pxe PXE tab_pxe 1.374 -dnsmasq tftpd tab_dnsmasq 1.375 $([ -x /usr/sbin/dnsd -o -x /usr/sbin/named -o -x /usr/sbin/dnsmasq ] && 1.376 echo "true" || 1.377 echo "#") DNS tab_dns 1.378 +ntpd NTP tab_ntp 1.379 +cupsd CUPS tab_cups 1.380 +$([ -x /usr/bin/mysqld_safe -o -x /usr/bin/postgres ] && echo "true" || 1.381 +echo "#") SQL tab_sql 1.382 +knockd Knock tab_knockd 1.383 +$([ -x /usr/sbin/dropbear -o -x /usr/sbin/sshd ] && echo "true" || 1.384 +echo "#") SSH tab_sshd 1.385 x11vnc VNC tab_vnc 1.386 -knockd Knock tab_knockd 1.387 -$([ -x /usr/bin/mysqld_safe -o -x /usr/bin/postgres ] && 1.388 -echo "true" || 1.389 -echo "#") SQL tab_sql 1.390 +dnsmasq TFTP tab_dnsmasq 1.391 +$([ -x /usr/bin/ftpd -o -x /usr/sbin/pure-ftpd ] && echo "true" || 1.392 +echo "#") FTP tab_ftp 1.393 +$([ -x /usr/sbin/lighttpd -o -x /usr/bin/httpd -o -x /usr/sbin/squid ] && echo "true" || 1.394 +echo "#") HTTP tab_http 1.395 +rsync Rsync tab_rsync 1.396 +$([ -x /usr/sbin/rpc.nfsd -o -x /usr/bin/unfsd ] && echo "true" || 1.397 +echo "#") NFS tab_nfs 1.398 +smbd SAMBA tab_wins 1.399 slapcat LDAP tab_openldap 1.400 postfix SMTP tab_smtp 1.401 -cyradm IMAP/POP3 tab_imap 1.402 -squid Web\ cache tab_squid 1.403 +cyradm IMAP tab_imap 1.404 asterisk Telephony tab_asterisk 1.405 #TODO+callback pppd Pppd tab_pppd 1.406 #TODO pptpd PoPToP tab_poptop