Last active
March 21, 2020 13:26
-
-
Save ktor/9cae6dde3ec7ea9793ec343e710fe4bb to your computer and use it in GitHub Desktop.
Lightweight web server oneliner test with 20s delay in response
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| printf 'HTTP/1.1 200 OK\n\n%s' "<html>" | nc -l -i 20 -p 8888 localhost |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
server will wait on port 8888 and respond to a request with
<html>body after 20s from a request and then finish.