-
Notifications
You must be signed in to change notification settings - Fork 23
Simple Linux webserver
Oleksandr Porunov edited this page Apr 19, 2017
·
3 revisions
This instraction describes how to run a simple Linux webserver to serve well-known files (HTTP01 challenges) in several steps.
-
Create a webserver directory and a well-known directory
mkdir -p /var/www/.well-known/acme-challenge
-
Copy your well-known files into the
/var/www/.well-known/acme-challenge
directory. -
Enter your 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.