Fix Appwrite Function API requests behind HTTPS redirects - #1087
Conversation
built with Refined Cloudflare Pages Action⚡ Cloudflare Pages Deployment
|
There was a problem hiding this comment.
Pull request overview
This PR updates the Appwrite Dokploy template configuration so Appwrite is instructed to force HTTPS, preventing HTTP→HTTPS redirect behavior that can cause Node-based Function requests to change from POST to GET when following a 301.
Changes:
- Enable Appwrite’s
_APP_OPTIONS_FORCE_HTTPSoption in the Appwritetemplate.tomlenv configuration.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…HTTPS domain Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Tested this on a Dokploy instance (hostinger.dokploy.com) by importing Why the change is correct
Deploy results (all 29 containers running, deploy 83 s)
So the trade-off is: correct HTTPS behaviour (Functions endpoint, generated URLs) vs. plain-HTTP deployments no longer working out of the box. Given Appwrite's guidance and that HTTPS is the expected setup, I think the change is right; I pushed 92e06a7 to this branch adding a comment next to Not verified end-to-end: actually deploying a Function and inspecting |
What is this PR about?
Fix the Appwrite template so Functions receive an HTTPS
APPWRITE_FUNCTION_API_ENDPOINT.Dokploy redirects HTTP to HTTPS permanently. Node follows that redirect by changing POST to GET, which can turn a TablesDB
createRowrequest intolistRowsbecause both operations use the same path.Checklist
Before submitting this PR, please make sure that:
Validation performed:
A Dokploy instance was not available locally. This is a one-line configuration correction; the existing template's HTTPS domain and redirect configuration were verified statically.
Issues related (if applicable)
Reported in https://appwrite.io/threads/1538184240431370403
Screenshots or Videos
Not applicable.