Created
November 9, 2022 15:52
-
-
Save paulgreg/304bd061311c0c503849bee4cb1dd16e to your computer and use it in GitHub Desktop.
Quickly serve a local directory with TLS using http-server (node) & with self signed certificates
This file contains 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/bash -v | |
openssl req -x509 -newkey rsa:4096 -keyout key.pem -out cert.pem -sha256 -days 365 -subj '/CN=localhost' -nodes | |
npx http-server -S . |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment