Problem
I’ve deployed Chatwoot using CapRover.
However, when a new agent clicks the reset password link in the email, they are redirected to a “Nothing here yet :/” (i.e 404 error) page.
My Nginx Config
<%
if (s.forceSsl) {
%>
server {
listen 80;
server_name <%-s.publicDomain%>;
# Used by Lets Encrypt
location /.well-known/acme-challenge/ {
root <%-s.staticWebRoot%>;
}
# Used by CapRover for health check
location /.well-known/captain-identifier {
root <%-s.staticWebRoot%>;
}
location / {
return 302 https://$http_host$request_uri;
}
}
<%
}
%>
server {
<%
if (!s.forceSsl) {
%>
listen 80;
<%
}
if (s.hasSsl) {
%>
listen 443 ssl http2;
ssl_certificate <%-s.crtPath%>;
ssl_certificate_key <%-s.keyPath%>;
<%
}
%>
client_max_body_size 500m;
underscores_in_headers on;
server_name <%-s.publicDomain%>;
resolver 127.0.0.11 valid=10s;
set $upstream http://<%-s.localDomain%>:<%-s.containerHttpPort%>;
location / {
<%
if (s.redirectToPath) {
%>
return 302 <%-s.redirectToPath%>;
<%
} else {
%>
<%
if (s.httpBasicAuthPath) {
%>
auth_basic "Restricted Access";
auth_basic_user_file <%-s.httpBasicAuthPath%>;
<%
}
%>
proxy_pass $upstream;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
<%
if (s.websocketSupport) {
%>
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_http_version 1.1;
<%
}
%>
<%
}
%>
}
# Used by Lets Encrypt
location /.well-known/acme-challenge/ {
root <%-s.staticWebRoot%>;
}
# Used by CapRover for health check
location /.well-known/captain-identifier {
root <%-s.staticWebRoot%>;
}
error_page 502 /captain_502_custom_error_page.html;
location = /captain_502_custom_error_page.html {
root <%-s.customErrorPagesDirectory%>;
internal;
}
}
To Reproduce
- Deploy Chatwoot on CapRover.
- Ensure that HTTPS is set up and functioning properly (also tested without https – same thing).
- Invite a new agent to create an account, which sends an email.
- Click on the password reset link in the email, e.g., https://example.com/app/auth/password/edit?reset_password_token=userToken
What i’ve tried so far:
Deploying Chatwoot both with and without HTTPS, but neither worked on my server.
However, when deployed on localhost, the email password reset link worked as expected.
Environment details
- CapRover version: 1.11.1
- Chatwoot version: 3.11.0
- Server OS: Ubuntu 22.04