Created
June 30, 2025 13:40
-
-
Save henriquegogo/1bc49f66e24b7b7a84e8e9baa9803800 to your computer and use it in GitHub Desktop.
Shell Web Server
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 | |
port=8000 | |
echo "Starting server on port $port..." | |
while true; do | |
echo "HTTP/1.1 200 OK | |
Content-Type: text/plain | |
Hello World" | nc -l -p $port -q 0 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment