Accessing an image within a railway. app PGS database

Hi all, Absolutely love Railway.app but just wondering if anyone can assist with accessing an image which is saved in the DB via a FormBricks submission. In summary I want to access those images in an N8N workflow also hosted on Railway. App Much thanks
Solution:
okay so i spent a good while on a formbricks template with minio and got 99% of the way finished, until i tested uploading and found out the backend returns the wrong url for the signed s3 file uploads, i then spent another good while trying to debug that and combing through formbrick's code to no avail. The solution im now proposing is, use the REST api formbricks provides - https://documenter.getpostman.com/view/11026000/2sA3Bq5XEh#f7e77579-edfd-4416-b266-6af2ce04dfdf that simple request gives you a json response for all form responses and in that it contains direct links to the uploads that are served from the volume via formbricks....
Jump to solution
18 Replies
Percy
Percy5mo ago
Project ID: N/A
juanmackie🇦🇺
N/aa
Brody
Brody5mo ago
you can't access the disk storage of one service from another service, formbricks would need to provide an n8n integration or API for this, or you would need to have formbricks store the images in a place thats accessable by multiple services like MinIO s3
juanmackie🇦🇺
Noted with thanks...... I was hopefully just going to use the URL that points to the blob within postgress, but I will look to implement your advice.
Brody
Brody5mo ago
i dont think formbricks stores images in postgres
juanmackie🇦🇺
I might be misunderstanding, as I have NIL experience with postgress it is most likely the case. Appreciate the prompt response and help/nudge in the right direction
Brody
Brody5mo ago
happy to help where i can
juanmackie🇦🇺
Hey @Brody , Thanks again the leads this morning. Are you able to briefly point me in the write direction on how to go about using minio . I have set up minio in the same project space on railway I have added the variables to the formbricks variables tab in railway.app As an alternative solution,I have tried using N8N and the S3 node to save the file but I get an error stating "hostname/ip does not match certificate's altnames" I have googled and quizzed the hell out of it but just can't make either of the approaches work. Oh I also tried maybe using a webhook from FormBricks to minIO Thanks in advance
Brody
Brody5mo ago
so basically you just want to be able to access any media uploaded to formbricks from multiple services?
juanmackie🇦🇺
Pretty much yes. Using minIO, as you mentioned the uploaded media would be accessable via the minIO URL for said media item . Based on that I can use the minIO item URL in my workflow and just set a variable to access each item via my N8N workflow.
Brody
Brody5mo ago
switching to minio would likely mean loosing access to any images previously saved to the volume, are you aware and okay with that?
juanmackie🇦🇺
Totally fine 👍
Brody
Brody5mo ago
alright, then I will try my hand at a formbricks with minio
juanmackie🇦🇺
🙏🙏 big thanks
Solution
Brody
Brody5mo ago
okay so i spent a good while on a formbricks template with minio and got 99% of the way finished, until i tested uploading and found out the backend returns the wrong url for the signed s3 file uploads, i then spent another good while trying to debug that and combing through formbrick's code to no avail. The solution im now proposing is, use the REST api formbricks provides - https://documenter.getpostman.com/view/11026000/2sA3Bq5XEh#f7e77579-edfd-4416-b266-6af2ce04dfdf that simple request gives you a json response for all form responses and in that it contains direct links to the uploads that are served from the volume via formbricks.
Want results from more Discord servers?
Add your server