Custom Recovery Template Ignored #41513
-
|
Problem Summary: Environment:
Configuration: Verification Steps Performed:
Expected Behavior: Actual Behavior: Workaround (Partial): (GoTrue v2.183.0 / v2.164.0) |
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 3 replies
-
|
This smells less like a filesystem/env issue and more like the recovery flow bypassing the template loader entirely. In GoTrue, recovery emails historically route through a different code path than signup confirmation, and in some versions the recovery handler hard-falls back to site URL rendering if Two things I’d check: Whether Whether the recovery mailer ignores file-backed templates unless The fact that pointing to a known-good confirm template still sends index.html is the key signal here. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks a lot for the detailed suggestion! It sounded very promising. I tried explicitly setting It seems like the template loader is indeed being bypassed or failing silently regardless of the URL path configuration in this version/setup. I've reverted to the default text email for now. Thanks again for the help!" |
Beta Was this translation helpful? Give feedback.
-
|
Thanks for testing and confirming. Given that pointing One quick way to confirm where it’s breaking:
At that point I’d suspect either:
If you do find a version where this works, pinning it may be the safest option for now. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
|
@kopko13 Hi, This isn't a bug. Email template env vars such as in the below example I am using a static file server in the same docker network as auth container. This is the static file server I am using https://github.com/halverneus/static-file-server This can be any file server you want. auth container simply needs a url which it can make a GET request to and this url should return a valid template. |
Beta Was this translation helpful? Give feedback.
-
|
Also, https://supabase.com/docs/guides/self-hosting/custom-email-templates by @singh-inder :) |
Beta Was this translation helpful? Give feedback.
@kopko13 Hi, This isn't a bug. Email template env vars such as
GOTRUE_MAILER_TEMPLATES_RECOVERYhave to be a url and this url should return a template. And it doesn't have to be public. You can simply add a static file-server container in your docker-compose.yml filein the below example I am using a static file server in the same docker network as auth container. This is the static file server I am using https://github.com/halverneus/static-file-server This can be any file server you want. auth container simply needs a url which it can make a GET request to and this url should return a valid template.