Skip to content

Instantly share code, notes, and snippets.

@RicardoRagel
Last active April 20, 2022 17:09
Show Gist options
  • Save RicardoRagel/5e97df9ddd4d96253511dd6373fb86d1 to your computer and use it in GitHub Desktop.
Save RicardoRagel/5e97df9ddd4d96253511dd6373fb86d1 to your computer and use it in GitHub Desktop.
Desktop PC Conky Configuration
conky.config = {
update_interval = 1,
cpu_avg_samples = 2,
net_avg_samples = 2,
out_to_console = false,
override_utf8_locale = true,
double_buffer = true,
no_buffers = true,
text_buffer_size = 32768,
imlib_cache_size = 0,
own_window = true,
own_window_type = 'normal',
own_window_argb_visual = true,
own_window_argb_value = 50,
own_window_hints = 'undecorated,below,sticky,skip_taskbar,skip_pager',
border_inner_margin = 5,
border_outer_margin = 0,
xinerama_head = 1,
draw_shades = false,
draw_outline = false,
draw_borders = false,
draw_graph_borders = false,
use_xft = true,
font = 'Ubuntu Mono:size=12',
xftalpha = 0.8,
uppercase = false,
default_color = 'white',
own_window_colour = '#000000',
alignment = 'bottom_right',
gap_x = 10,
gap_y = 10,
minimum_width = 350, minimum_height = 1035,
};
conky.text = [[
${time %H:%M:%S}${alignr}${time %d-%m-%y}
${voffset -16}${font sans-serif:bold:size=18}${alignc}${time %H:%M}${font}
${voffset 4}${alignc}${time %A %B %d, %Y}
${font}${voffset -4}
${font sans-serif:bold:size=12}SYSTEM ${hr 2}
${goto 30}${font sans-serif:bold:size=10}OS:$alignr ${font sans-serif:normal:size=10}$sysname $kernel $machine
${goto 30}${font sans-serif:bold:size=10}Distro:$alignr ${font sans-serif:normal:size=10}${execi 999999 lsb_release -ds}
${goto 30}${font sans-serif:bold:size=10}Host:$alignr ${font sans-serif:normal:size=10}$nodename
${goto 30}${font sans-serif:bold:size=10}Uptime:$alignr ${font sans-serif:normal:size=10}$uptime
${goto 30}${font sans-serif:bold:size=10}File System: $alignr ${font sans-serif:normal:size=10}${fs_type}
${goto 30}${font sans-serif:bold:size=10}Processes: $alignr ${font sans-serif:normal:size=10} ${execi 1000 ps aux | wc -l}
${font sans-serif:bold:size=12}CPU ${hr 2}
${goto 30}${font sans-serif:normal:size=10}${execi 1000 grep model /proc/cpuinfo | cut -d : -f2 | tail -1 | sed 's/\s//'}
# ${goto 30}${font sans-serif:normal:size=10}${cpugraph cpu1}
${goto 30}${font sans-serif:bold:size=10}1. ${font sans-serif:normal:size=10}${cpu cpu1}% ${goto 100} ${color cyan}${cpubar cpu1}$color
${goto 30}${font sans-serif:bold:size=10}2. ${font sans-serif:normal:size=10}${cpu cpu2}% ${goto 100} ${color cyan}${cpubar cpu2}$color
${goto 30}${font sans-serif:bold:size=10}3. ${font sans-serif:normal:size=10}${cpu cpu3}% ${goto 100} ${color cyan}${cpubar cpu3}$color
${goto 30}${font sans-serif:bold:size=10}4. ${font sans-serif:normal:size=10}${cpu cpu4}% ${goto 100} ${color cyan}${cpubar cpu4}$color
${goto 30}${font sans-serif:bold:size=10}5. ${font sans-serif:normal:size=10}${cpu cpu5}% ${goto 100} ${color cyan}${cpubar cpu5}$color
${goto 30}${font sans-serif:bold:size=10}6. ${font sans-serif:normal:size=10}${cpu cpu6}% ${goto 100} ${color cyan}${cpubar cpu6}$color
${goto 30}${font sans-serif:bold:size=10}7. ${font sans-serif:normal:size=10}${cpu cpu7}% ${goto 100} ${color cyan}${cpubar cpu7}$color
${goto 30}${font sans-serif:bold:size=10}8. ${font sans-serif:normal:size=10}${cpu cpu8}% ${goto 100} ${color cyan}${cpubar cpu8}$color
${font sans-serif:bold:size=12}MEMORY ${hr 2}
${goto 30}${font sans-serif:normal:size=10}RAM $alignc $mem / $memmax $alignr $memperc%
${goto 30}${color cyan}$membar$color
${goto 30}SWAP $alignc ${swap} / ${swapmax} $alignr ${swapperc}%
${goto 30}${color cyan}${swapbar}$color
${font sans-serif:bold:size=12}DISK USAGE ${hr 2}
${goto 30}${font sans-serif:normal:size=10}/ $alignc ${fs_used /} / ${fs_size /} $alignr ${fs_used_perc /}%
${goto 30}${color cyan}${fs_bar /}$color
${font Ubuntu:bold:size=12}NETWORK ${hr 2}
${goto 30}${font sans-serif:bold:size=10}Local IPs: $alignr ${font sans-serif:normal:size=10} ${execi 1000 ip a | grep inet | grep -vw lo | grep -v inet6 | cut -d \/ -f1 | sed 's/[^0-9\.]*//g' | sed -z 's/\n/, /g;s/, $/\n/'}
${goto 30}${font sans-serif:bold:size=10}External IPs: $alignr ${font sans-serif:normal:size=10} ${alignr}${execi 1000 wget -q -O- http://ipecho.net/plain; echo}
${goto 30}${color darkgreen}${downspeedgraph enp0s31f6 80,130 } ${alignr} ${color darkred} ${upspeedgraph enp0s31f6 80,130 }$color
${goto 30}${font sans-serif:normal:size=10}Down: ${downspeed enp0s31f6} ${alignr}Up: ${upspeed enp0s31f6}
${font sans-serif:bold:size=12}TOP PROCESSES ${hr 2}
${goto 30}${font sans-serif:bold:size=10}Name $alignr PID CPU% MEM%${font sans-serif:normal:size=10}
${goto 30}${top name 1} $alignr ${top pid 1} ${top cpu 1}% ${top mem 1}%
${goto 30}${top name 2} $alignr ${top pid 2} ${top cpu 2}% ${top mem 2}%
${goto 30}${top name 3} $alignr ${top pid 3} ${top cpu 3}% ${top mem 3}%
${goto 30}${top name 4} $alignr ${top pid 4} ${top cpu 4}% ${top mem 4}%
${goto 30}${top name 5} $alignr ${top pid 5} ${top cpu 5}% ${top mem 5}%
${goto 30}${top name 6} $alignr ${top pid 6} ${top cpu 6}% ${top mem 6}%
${goto 30}${top name 7} $alignr ${top pid 7} ${top cpu 7}% ${top mem 7}%
${goto 30}${top name 8} $alignr ${top pid 8} ${top cpu 8}% ${top mem 8}%
${goto 30}${top name 9} $alignr ${top pid 9} ${top cpu 9}% ${top mem 9}%
${goto 30}${top name 10} $alignr ${top pid 10} ${top cpu 10}% ${top mem 10}%
]];

Overview

Conky system monitor configuration.

Get it

First, install conky in your system:

sudo apt-get install conky

Download this configuration at your home folder:

cd && wget https://gist.githubusercontent.com/RicardoRagel/5e97df9ddd4d96253511dd6373fb86d1/raw/6917216943f3e0a28de9a508d6f315cefa0f9c03/.conkyrc

And add conky to your system startup. On Ubuntu, you can use a tool by visiting your app menu and typing startup. Select the Startup Applications entry and add the following new command /usr/bin/conky.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment