Error: certificate expired in Node

My production node application on Heroku accidentally started throwing the following error:

Error: certificate has expired
     at Error (native)
     at TLSSocket.<anonymous> (_tls_wrap.js:1060:38)
     at emitNone (events.js:86:13)
     at TLSSocket.emit (events.js:185:7)
     at TLSSocket._finishInit (_tls_wrap.js:584:8)
     at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:416:38)
 error: Forever detected script exited with code: 1
 error: Script restart attempt #1
 Creating a pool connected to blah.thing.com:port
 Running migrations for database 'app_name'...
 events.js:160
       throw er; // Unhandled 'error' event
       ^

Two things confuse me. My certificate is updated, so I don’t know why it says that it expired, and secondly, only two files with the name "events.js" in my application directory are in two seemingly irrelevant node modules (request and twilio ) and doesn’t even have line 160. What could be the reason for this and how should I debug it?

edit: In addition, it is just a production application (of course), and not intermediate or local, which is odd, because production and production point to the same certificate.

+4
1

, " " . (, node -)

+1

Source: https://habr.com/ru/post/1659771/


All Articles