Closed x8BitRain closed 2 years ago
This works for me: { key_file_name: './privkey.pem', cert_file_name: './fullchain.pem' }
the ./
is not required for relative path, I just add it to clarify
Does not work either, I tried Soketi and I get the same issue. Maybe related to this? https://github.com/uNetworking/uSockets/issues/131
Using --trace-uncaught doesn't reveal anything new.
Either you are not linking to the correct pem files which needs private key and full chain, or I just confirmed the pem path you give is relative to where you called Node from and not relative to where the app JS file is, so if you called Node with node dir/to/app.js
the pem path is not relative to app.js, it is relative to node so you would need pem path as dir/to/privkey.pem
Thanks, the above worked!
Trying to create an SSLApp with cert and key but no matter where I put the cert (same level, folder above or below) and the key or how I name them it fails with
Error: App construction failed
.If I remove the
cert_file_name
andkey_file_name
settings it launches just fine.The code in question is basic, readFileSync doesn't work either:
The error:
Doesn't work in docker images like node:16-bullseye, node:16-buster or even on earlier versions of the natively on macos. Downgrading to version v20.7.0 doesn't work either.
EDIT: Soketi doesn't work either, same error.
This seems like a bug to me, any ideas? Thanks.