Im running a nodejs server on my pc with nodemon, yesterday after getting my cert it worked fine. Now, after closing my pc, im trying to run my server.js file again, and the following code:
const https = require('https');
const fs = require('fs');
const options = {
key: fs.readFileSync('C:/Certbot/live/learntocode.ddns.net/privkey.pem'),
cert: fs.readFileSync('C:/Certbot/live/learntocode.ddns.net/fullchain.pem'),
};
Error: EPERM: operation not permitted, open 'C:/Certbot/live/learntocode.ddns.net/fullchain.pem'
This is the error i get. I tried changing file access permissions on file explorer but i get: Failed to enumerate objects in the container. Weirdly enough, when i rerun certbot certonly and replaced by certs, Nodejs ran my .js file without error
My domain is: learntocode.ddns.net
My web server is (include version):
Nodejs v18.14.2
The operating system my web server runs on is (include version):
Windows 11 v22h2
My hosting provider, if applicable, is:
no-ip
I can login to a root shell on my machine (yes or no, or I don't know):
I dont know
I'm using a control panel to manage my site (no, or provide the name and version of the control panel):
no
The version of my client is (e.g. output of certbot --version
or certbot-auto --version
if you're using Certbot):
2.7.4