ChaosOptimized
ChaosOptimized
WWasp-lang
Created by ChaosOptimized on 7/8/2024 in #đŸ™‹questions
Cannot Access dB once Deployed...
Hi, all! I'm running into an error with any Wasp apps that use a dB after deploy. During development on localhost, the wasp client and server work just fine and the server connects to the dB (running on Supabase) just fine. The app works just fine. BUT THEN: I deploy the app and run into errors with the dB. The wasp server and client work with any page / function that does not call out to the dB. But when accessing the dB while deployed, I just get errors. I have my own servers I rent from Hetzner and am using Coolify to deploy. Once again, the server and client work fine and any page that does not use the dB loads up just as one would expect. Trying to log in gives me a "405" error when accessing the dB. Thinking the problem might be Coolify, I decided to deploy on Fly.io. This time, I get a "network error" when accessing the dB instead of a "405" error. THEN, I tried using the Postgre dB that Fly.io offers -- STILL get a "network error" when the app accesses the dB. My DATABASE_URL is properly set both on my Coolify instance and when I tried it on Fly.io. I have no idea what is going on. When running locally the app calls out to the Supabase db just fine, with no errors. I have spent several hours trying to debug this problem and all I have done is waste time and energy. Currently, I am only replicating the "Todo" app from the Tutorial -- so this is not some big and complicated App. I really want to use Wasp instead of having to learn Next.js. What am I doing wrong? Please, help!
16 replies