I have managed to deploy my MERN app on a VPS successfully and serve it with greenlock-express.
But, all of the sudden it stopped working and this is what gets logged when I serve the app:
node server.js
Listening on 0.0.0.0:80 for ACME challenges, and redirecting to HTTPS
Listening on 0.0.0.0:443 for secure traffic
Ready to Serve:
domain_name.com
(node:13453) DeprecationWarning: collection.ensureIndex is deprecated.
Use createIndexes instead.
MongoDB connected!
debug: ignoring servername "www.domain_name.com"
(it's probably either missing from your config, or a bot)
set greenlockOptions.notify to override the default logger
servername_unknown (more info available: servername)
ACME Directory URL: https://acme-v02.api.letsencrypt.org/directory
By using this software you ([email protected]) are agreeing
to the following:
ACME Subscriber Agreement:
https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf
Greenlock/ACME.js Terms of Use: https://rootprojects.org/legal/#terms
certificate_order (more info available: account subject altnames
challengeTypes)
challenge_select (more info available: altname type dnsHost
keyAuthorization)
challenge_status domain_name.com pending
challenge_status domain_name.com valid
certificate_status domain_name.com valid
cert_issue (more info available: renewAt subject altnames)
When I try to connect to my website on the browser, this is what I see:
This site canβt be reached
www.domain_name.com unexpectedly closed the connection.
Try:
Checking the connection
Checking the proxy and the firewall
ERR_CONNECTION_CLOSED
I also noticed that when I enter the greenlock.d folder generated when I run the config command:
npx greenlock add --subject domain_name.com --altnames domain_name.com
I only find these two files:
![enter image description here](https://camo.githubusercontent.com/f980568c0d26f7b3bc07649cc8c1f06d34bb3bce9ed7b6de98c14e0c9bbd1de8/68747470733a2f2f692e737461636b2e696d6775722e636f6d2f73757068782e706e67)
Whereas usually after I load the website the first time after the config, I find all these files:
![enter image description here](https://camo.githubusercontent.com/7705aa9d652f6614938962768f4a5c5e0b7e862598f7dc6478ed302358bdb75d/68747470733a2f2f692e737461636b2e696d6775722e636f6d2f45626a734f2e706e67)