有相当多的一行HTTP服务器可用。
Python
python -m SimpleHTTPServer 8000
红宝石
ruby -run -ehttpd . -p8000
等。
有1行HTTPS服务器吗?如果他们自己生成自己签名的证书,那就更好了。一小部分线路也能工作。
发布于 2016-06-23 00:38:57
发布于 2020-04-14 19:38:03
发布于 2014-11-06 15:03:17
亨琴托特可用于此目的。这一行相当长,但并不是不可能的。不过,您需要从文件中提供证书和密钥。
sbcl --eval '(progn
(and nil #.(require "hunchentoot"))
(setq hunchentoot:*dispatch-table*
(list (hunchentoot:create-folder-dispatcher-and-handler "/" "'`pwd`/'")))
(hunchentoot:start (make-instance (quote hunchentoot:easy-ssl-acceptor)
:port 8443
:ssl-privatekey-file "../cert.key"
:ssl-certificate-file "../cert.crt")))'
为了提高可读性,上面的命令被拆分成多行;它也可以作为一行输入。
https://stackoverflow.com/questions/26790727
复制