-
Notifications
You must be signed in to change notification settings - Fork 23
Simple Linux webserver
Laurens Blanckenborg edited this page Apr 20, 2017
·
3 revisions
This instruction describes how to run a simple Linux webserver to serve well-known files for HTTP01 challenges in only three steps.
-
Create a webserver directory and a well-known directory:
mkdir -p /var/www/.well-known/acme-challenge
-
Navigate to the server directory:
cd /var/www/
-
Run your server on port 80:
$(command -v python2 || command -v python2.7 || command -v python2.6) -c "import BaseHTTPServer, SimpleHTTPServer; s = BaseHTTPServer.HTTPServer(('', 80), SimpleHTTPServer.SimpleHTTPRequestHandler); s.serve_forever()"
Press Ctrl + C to stop the server.