3 ms·
How hard would it be to make bash be the only dependency (and not require tcpserver)? Iirc bash has some built-in support for networking but perhaps it's only
by ithkuil 3y ago
How hard would it be to make bash be the only dependency (and not require tcpserver)?
Iirc bash has some built-in support for networking but perhaps it's only for clients?
- micheljansen 3y agoBack in the day all you needed was CGI and Bash (though Perl was often the better choice) http://underpop.online.fr/c/cgi/docs/creating-cgi-programs-with-bash/amp.htm http://underpop.online.fr/c/cgi/docs/creating-cgi-programs-w...
- ithkuil 3y agoYes but you needed a web server that then invoked your CGI binary. I meant a truly pure bash server
- forgotpwd16 3y agoA pure bash web server is indeed possible using a loadable builtin. See: https://github.com/dzove855/Bash-web-server https://github.com/dzove855/Bash-web-server (discussed: https://news.ycombinator.com/item?id=29794979 https://news.ycombinator.com/item?id=29794979).
- ithkuil 3y agoBut this isn't pure bash. It requires a shared library you have to compile.
- forgotpwd16 3y ago>It requires a shared library you have to compile. Library is part of bash and patch is for supporting multiple connections. On vers>=5.2 patch is included so no need to compile anything.
- meepmorp 3y agoNot sure about bash, but iirc, zsh’s tcp module has a proxy function to listen on a port and pass input to a shell command.