Using htop to generate a live website background
drunken-security.at
Using htop to generate a live website background
1–10 of 63 posts
Re: Using htop to generate a live website background
#2Direct link to the generated background image: http://104.233.86.94/background/background.png
Re: Using htop to generate a live website background
#3I would be worried about one of the processes having a database password or something like that as a parameter...
Re: Using htop to generate a live website background
#4I would be worried about one of the processes having a database password or something like that as a parameter...
mysql at least replaces -ppassword for -px
Re: Using htop to generate a live website background
#5Neat thanks!
You can generate HTML (and from that png or whatever) with http://www.pixelbeat.org/scripts/ansi2html.sh like
$ COLUMNS=80 timeout 1 htop > t.ansi
$ ansi2html.sh --bg=dark t.html
I've requested a -b, --batch option for htop, to simplify this mode of operation. https://github.com/hishamhm/htop/issues/282 Then you could just: $ COLUMNS=80 htop -b | ansi2html.sh ...Re: Using htop to generate a live website background
#6I would be worried about one of the processes having a database password or something like that as a parameter...
mysql at least replaces -ppassword for -px
Even though some software does replace the password, it would be better not to use passwords like that at all anyway. Just to be sure.
Re: Using htop to generate a live website background
#7Earlier quoted context omitted.
mysql at least replaces -ppassword for -px
Even though some software does replace the password, it would be better not to use passwords like that at all anyway. Just to be sure.
Good point.
I think we should be caeful what we do, while administrating the server.
Maybe we could build some automatism which stops the screenshot service while an ssh session is established.
Re: Using htop to generate a live website background
#8Would be more interesting if the background is live, like updating itself every second or half a second.
Re: Using htop to generate a live website background
#9I wonder how https://github.com/ansilove/AnsiLove-C would fare for generating the PNG compared to the current solution.
Re: Using htop to generate a live website background
#10Nice idea although a bit dangerous! I wonder if it would be better to use as background the output of a program like gotty, which streams a terminal's output as a web page.