Threadfin (xteve) behind caddy not working properly

1. The problem I’m having:

trying to access Threadfin (a branch of Xteve) behind caddy.

2. Error messages and/or full log output:

I am properly directed to the login page but upon login, but one I login, the app tries to redirect me to threadfin.serverstuff.pw/web and I get a 404 error.

3. Caddy version:

v2.7.4

4. How I installed and ran Caddy:

sudo apt install via the command line Ubuntu 20, running from a service file. Caddy is working well and properly redirecting a number of other services and websites on the vps.

a. System environment:

Ubuntu 20

b. Command:

threadfin.serverstuff.pw {
        rewrite * /web{uri}
        reverse_proxy 127.0.0.1:11313
}

d. My complete Caddy config:

#threadfin
threadfin.serverstuff.pw {
        rewrite * /web{uri}
        reverse_proxy 127.0.0.1:11313
}

5. Links to relevant resources:

Why are you doing this?

The upstream will need to be aware that all requests are being rewritten to include /web. If the upstream doesn’t know this, then it makes sense that 404s will happen.