POST route not working with Passenger/Dreamhost server

I am programming a contact form on my Dreamhost site ( that emails me their message. I am using Nodejs, Express, and have enabled Passenger. I have also went through all the Dreamhost Nodejs/passenger guides. My post route for the contact form works on my localhost, but when I upload it to Dreamhost (and set the app to listen to port 80) I get a 500 error. I have been trying to fix this to no avail.
My fetch code looks like this
fetch("/send", {
method: “post”,
body: mail,

My app.js code looks like this"/send", (req, res) => {
//… code to send mail
// express server listening
app.listen(80, () => {
console.log(Listening on port 80...);
It works on localhost when I test on port 8080, but on dreamhost I get a 500 error.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.