Skip to content

Instantly share code, notes, and snippets.

@linonetwo
Created January 8, 2020 07:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save linonetwo/a8a8c79185f5b74065cddf4569b3fa90 to your computer and use it in GitHub Desktop.
Save linonetwo/a8a8c79185f5b74065cddf4569b3fa90 to your computer and use it in GitHub Desktop.
[trust local CA added by mkcert] #javascript #server #tls
// Get full chain CA and local CA added by mkcert, so secure TLS can be established
const rootCAs = require('ssl-root-cas/latest').create();
rootCAs.addFile(process.env.MKCERT_PATH);
require('https').globalAgent.options.ca = rootCAs;
DEBUG=solid:* MKCERT_PATH=\"$(mkcert -CAROOT)/rootCA.pem\" solid start # --root $(pwd)/data --data-browser-path $(pwd)/../node_modules/mashlib/dist/databrowser.html --config-file $(pwd)/../config.solid.example.json
# MKCERT_PATH=\"$(mkcert -CAROOT)/rootCA.pem\"
# ↑
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment