Loading conky.conf 0 → 100644 +98 −0 Original line number Diff line number Diff line -- vim: ts=4 sw=4 noet ai cindent syntax=lua --[[ Conky, a system monitor, based on torsmo Any original torsmo code is licensed under the BSD license All code written since the fork of torsmo is licensed under the GPL Please see COPYING for details Copyright (c) 2004, Hannu Saransaari and Lauri Hakkarainen Copyright (c) 2005-2012 Brenden Matthews, Philip Kovacs, et. al. (see AUTHORS) All rights reserved. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. ]] conky.config = { alignment = 'top_left', background = false, border_width = 1, cpu_avg_samples = 2, default_color = 'white', default_outline_color = 'white', default_shade_color = 'white', draw_borders = false, draw_graph_borders = true, draw_outline = false, draw_shades = false, use_xft = true, font = 'DejaVu Sans Mono:size=14', gap_x = 5, gap_y = 60, minimum_height = 5, minimum_width = 5, net_avg_samples = 2, no_buffers = true, out_to_console = false, out_to_stderr = false, extra_newline = false, own_window = true, own_window_class = 'Conky', own_window_type = 'normal', stippled_borders = 0, update_interval = 1.0, uppercase = false, use_spacer = 'none', show_graph_scale = false, show_graph_range = false, overwrite_file = "/tmp/assistance.txt" } conky.text = [[ Voici les informations nécessaires pour le service d'assistance de la DSI $hr Informations générales : ${color grey}Nom du serveur :$color ${exec dig wpad.ecole.lan | awk '/86400/{print $5}' | head -n 1 | nslookup | grep grenoble | awk '/name/{print $4}' | cut -d . -f 1}.grenoble.ecole.fr ${color grey}Nom du poste :$color $nodename ${color grey}Version :$color ${exec lsb_release -d | awk '{print $2" "$3" "$4}'} ${color grey}Démarré depuis :$color $uptime $hr Utilisation ressources : ${color grey}Processeur :$color ${if_match $cpu >= 80}${color red}${else}${color green}${endif}$cpu% ${color grey}Mémoire :$color ${if_match $memperc >= 80}${color red}${else}${color green}${endif}$memperc% ${color grey}SWAP :$color ${if_match $swapperc >= 30}${color red}${else}${color green}${endif}$swapperc% ${color grey}Disque :$color ${if_match ${exec df / | awk '/^\//{print $5}' | tr -d '%' } >= 80}${color red}${else}${color green}${endif}${exec df / | awk '/^\//{print $5}'} $color $hr Connection réseau : ${color grey}IP:$color ${if_empty ${exec hostname -I}}${color red}HS${else}${color green}${exec hostname -I}${endif} ${color grey}MAC:$color ${if_empty ${exec ip -o link | awk '/state UP/{print $17}'}}${color red}HS${else}${color green}${exec ip -o link | awk '/state UP/{print $17}'}${endif} $color $hr Etat connexion : ${color grey}DHCP : ${if_gw}${color green}OK${else}${color red}HS${endif} ${color grey}Réseau local : ${if_match ${exec ping -c 1 pedago > /dev/null 2>&1; echo $?} == 0}${color green}OK${else}${color red}HS${endif} ${color grey}Partages : ${if_match ${exec grep '^//ecole-dc/' /etc/mtab > /dev/null 2>&1; echo $?} == 0}${color green}OK${else}${color red}HS${endif} ${color grey}DNS : ${if_match ${exec nslookup perdu.com > /dev/null 2>&1; echo $? } == 0}${color green}OK${else}${color red}HS${endif} ${color grey}Internet : ${if_match ${exec ping -c 1 8.8.8.8 > /dev/null 2>&1; echo $? } == 0}${color green}OK${else}${color red}HS${endif} ${color grey}Internet via Proxy : ${if_match ${exec http_proxy="dnsproxy:3128" https_proxy="dnsproxy:3128" wget -O - perdu.com > /dev/null 2>&1; echo $?} == 0}${color green}OK${else}${color red}HS${endif} $color ]] preinstall.sh +3 −2 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ apt-get update apt-get -y install \ appliplanet-primtux \ ardora-primtux \ conky \ cups-browsed \ evince \ flash-primtux \ Loading Loading @@ -103,5 +104,5 @@ done echo "Fixing network issues" $DIR/fix_network.sh echo "Adding cifs mounts" $DIR/create_cifs_mounts.sh echo "Update session" $DIR/upgrade_session.sh Loading
conky.conf 0 → 100644 +98 −0 Original line number Diff line number Diff line -- vim: ts=4 sw=4 noet ai cindent syntax=lua --[[ Conky, a system monitor, based on torsmo Any original torsmo code is licensed under the BSD license All code written since the fork of torsmo is licensed under the GPL Please see COPYING for details Copyright (c) 2004, Hannu Saransaari and Lauri Hakkarainen Copyright (c) 2005-2012 Brenden Matthews, Philip Kovacs, et. al. (see AUTHORS) All rights reserved. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. ]] conky.config = { alignment = 'top_left', background = false, border_width = 1, cpu_avg_samples = 2, default_color = 'white', default_outline_color = 'white', default_shade_color = 'white', draw_borders = false, draw_graph_borders = true, draw_outline = false, draw_shades = false, use_xft = true, font = 'DejaVu Sans Mono:size=14', gap_x = 5, gap_y = 60, minimum_height = 5, minimum_width = 5, net_avg_samples = 2, no_buffers = true, out_to_console = false, out_to_stderr = false, extra_newline = false, own_window = true, own_window_class = 'Conky', own_window_type = 'normal', stippled_borders = 0, update_interval = 1.0, uppercase = false, use_spacer = 'none', show_graph_scale = false, show_graph_range = false, overwrite_file = "/tmp/assistance.txt" } conky.text = [[ Voici les informations nécessaires pour le service d'assistance de la DSI $hr Informations générales : ${color grey}Nom du serveur :$color ${exec dig wpad.ecole.lan | awk '/86400/{print $5}' | head -n 1 | nslookup | grep grenoble | awk '/name/{print $4}' | cut -d . -f 1}.grenoble.ecole.fr ${color grey}Nom du poste :$color $nodename ${color grey}Version :$color ${exec lsb_release -d | awk '{print $2" "$3" "$4}'} ${color grey}Démarré depuis :$color $uptime $hr Utilisation ressources : ${color grey}Processeur :$color ${if_match $cpu >= 80}${color red}${else}${color green}${endif}$cpu% ${color grey}Mémoire :$color ${if_match $memperc >= 80}${color red}${else}${color green}${endif}$memperc% ${color grey}SWAP :$color ${if_match $swapperc >= 30}${color red}${else}${color green}${endif}$swapperc% ${color grey}Disque :$color ${if_match ${exec df / | awk '/^\//{print $5}' | tr -d '%' } >= 80}${color red}${else}${color green}${endif}${exec df / | awk '/^\//{print $5}'} $color $hr Connection réseau : ${color grey}IP:$color ${if_empty ${exec hostname -I}}${color red}HS${else}${color green}${exec hostname -I}${endif} ${color grey}MAC:$color ${if_empty ${exec ip -o link | awk '/state UP/{print $17}'}}${color red}HS${else}${color green}${exec ip -o link | awk '/state UP/{print $17}'}${endif} $color $hr Etat connexion : ${color grey}DHCP : ${if_gw}${color green}OK${else}${color red}HS${endif} ${color grey}Réseau local : ${if_match ${exec ping -c 1 pedago > /dev/null 2>&1; echo $?} == 0}${color green}OK${else}${color red}HS${endif} ${color grey}Partages : ${if_match ${exec grep '^//ecole-dc/' /etc/mtab > /dev/null 2>&1; echo $?} == 0}${color green}OK${else}${color red}HS${endif} ${color grey}DNS : ${if_match ${exec nslookup perdu.com > /dev/null 2>&1; echo $? } == 0}${color green}OK${else}${color red}HS${endif} ${color grey}Internet : ${if_match ${exec ping -c 1 8.8.8.8 > /dev/null 2>&1; echo $? } == 0}${color green}OK${else}${color red}HS${endif} ${color grey}Internet via Proxy : ${if_match ${exec http_proxy="dnsproxy:3128" https_proxy="dnsproxy:3128" wget -O - perdu.com > /dev/null 2>&1; echo $?} == 0}${color green}OK${else}${color red}HS${endif} $color ]]
preinstall.sh +3 −2 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ apt-get update apt-get -y install \ appliplanet-primtux \ ardora-primtux \ conky \ cups-browsed \ evince \ flash-primtux \ Loading Loading @@ -103,5 +104,5 @@ done echo "Fixing network issues" $DIR/fix_network.sh echo "Adding cifs mounts" $DIR/create_cifs_mounts.sh echo "Update session" $DIR/upgrade_session.sh