525 error specifically for my API, site is accessible

I have tried every solution I can find but most issues of the 525 error code are for the site itself, I am getting an issue where my api call is returning the error while my site is reachable just fine:

More context: I am using an angular frontend and a nodejs express server hosted on AWS. I was able to post to domain/api/appauth/application before adding the ssl, and the below is my nginx config file:

server {

listen 443 ssl;
listen [::]:443 ssl;

ssl on;
ssl_certificate /etc/ssl/www_rockyhillfiredepartment_com.pem;
ssl_certificate_key /etc/ssl/www_rockyhillfiredepartment_com.key;
ssl_verify_client on;
ssl_client_certificate /etc/ssl/client.pem;

server_name rockyhillfiredepartment.com;

location / {
proxy_pass http://localhost:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection ‘upgrade’;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}

location /api/ {
proxy_pass http://localhost:8080;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection ‘upgrade’;
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}

}

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