Tuesday, April 21, 2015

Bashttpd - Self contained bash webserver in one single short script! =)

I was thinking about coding something like this before I found something that was pretty much working already here: Original project

All I did was modify it a bit, changed the default settings for remote browsing, fixed binary file transfers and added a start option.

To use it first install tree, socat: 
 sudo apt-get install tree
 sudo apt-get install socat

Then download the latest copy of bashttpd from here:

https://github.com/AdamDanischewski/bashttpd

Just drop it on a host machine (that has bash) and start it up like this:

$192.168.1.101> bashttpd -s

On the remote machine you should be able to browse and download files from the host server via any web browser by visiting:

http://192.168.1.101:8080 

Fun!! =)