This is a lightweight HTTP server specially used to run Shell commands. It is especially suitable for development debugging, prototype verification or remote control, allowing shell-related functions to be iterated and tested faster. Deployment is also simple, providing only two command-line parameters: the access path (URL path) and the Shell command to execute. After that, as long as you request this path, the service will return the standard output of the script execution directly to you, which is very straightforward. · Map shell commands to HTTP interfaces Supports the definition of the URL path and the corresponding shell command through two command-line parameters, which is executed and returns its standard output when an HTTP request is received. · Flexible server configuration Various command-line options are provided, such as specifying listening host (-host), port (-port, default 8080), and supporting random port (set to 0). · Form and upload support (-form) Query parameters can be parsed and converted into environment variables for use as scripts, and file upload processing is also supported. · Form field verification (-form-check) Use regular expressions to filter form variables, such as allowing only fields of numeric type to be passed into a script. · CGI mode support (-cgi) Allow the script to obtain the complete HTTP request context (such as environment variable injection), support POST/PUT/PATCH data as standard input, and parse the HTTP headers returned by the script (such as Location: Redirection). · Environment variable export configuration You can specify that specific environment variables are exported (-export-vars= VAR1, VAR2...), or all current environment variables are exported (-export-all-vars). · Home Index Control & Exit Command Supports disabling automatically generated directory pages (-no-index) and adding/exit exit interfaces (-add-exit). · Log output configuration Support specifying log output files (-log=filename, output to STDOUT by default), and turn off timestamp (-no-log-timestamp). · Execution method and cache control You can specify the execution shell type (-shell, default "sh"), enable output caching (-cache=N seconds), and force serial execution (-one-thread). · Error and output handling Support displaying command errors (-show-errors) or accompanying standard error output (-include-stderr), and you can also set the exit code to return HTTP 500 (-500) when it is non-0. · HTTP Basic Authentication Supports setting multiple user authentications through-basic-auth="user:pass", and also supports the environment variable SH_BASIC_AUTH. · timeout control Supports setting the command execution timeout (seconds), controlled by the-timeout=N parameter. · HTTPS support If you specify a certificate (-cert) and a private key (-key), you can enable the HTTPS service. · Rich use examples README includes multiple practical examples, including obtaining system status information (such as date, ps aux), displaying environment variables, HTML calendar generation, file upload processing, simple proxy, slow request simulation, caching mechanism, Mac OS media control, JSON interface simulation, Windows examples, etc.

