R
Railway15mo ago
Aviz

Upload Files

Good morning, I have 4 gigabytes of image files, my application is connected to Git, and I can't upload the files there. How do I upload them directly to my application's upload folder without going through Git? I also tried through the CLI, but when I run an Indexed Compressed [====================] 100% Failed Failed to upload code with status code 413 Payload Too Large My application is working fine; I just can't get the files into my upload folder.
23 Replies
Percy
Percy15mo ago
Project ID: N/A
Aviz
AvizOP15mo ago
N/A
Brody
Brody15mo ago
for media storage you would be much better off using bucket storage like cloudflare r2, or even a purpose built online media storage service like cloudinary
Aviz
AvizOP15mo ago
Very grateful for the feedback! The application has already been developed, so I have the 4 gigabytes of files. I've already created the volume, and the code pointing to the volume is working perfectly. Now, I just need to put the 4 gigabytes into the volume. How do I do that? Please help me!
Brody
Brody15mo ago
all file access to the volume has to be done by the service it's attached to, so you can deploy this, upload your files to the volume then mount it's volume to your service, note
By default, the storage location is set to the storage subdirectory in the root of the volume, but by setting a service variable USE_VOLUME_ROOT to 1 you can opt to use the root of the volume as the storage location instead
By default, the storage location is set to the storage subdirectory in the root of the volume, but by setting a service variable USE_VOLUME_ROOT to 1 you can opt to use the root of the volume as the storage location instead
https://railway.app/template/Nan7Bs
Aviz
AvizOP15mo ago
"Que maneira elegante de resolver esse problema, vocês são incríveis 🤩🤩🤩🤩🤩🤩🤩, parabéns de verdade! Estarei implementando!" "What an elegant way to solve this problem, you guys are amazing 🤩🤩🤩🤩🤩🤩🤩, congratulations for real! I'll be implementing it!" Do I have to manually include these variables in my application, or does it automatically communicate with my database?
Aviz
AvizOP15mo ago
No description
Brody
Brody15mo ago
file browser does not use a postgres database, I'm not sure why you have those variables in that service
Aviz
AvizOP15mo ago
appeared automatically "Is it because I created it within my project?" "I thought I should create it inside, not outside of a project."
Brody
Brody15mo ago
correct, either way pay no attention to the uneeded postgres database variables
Aviz
AvizOP15mo ago
Should I create it outside?
Brody
Brody15mo ago
no inside is good
Aviz
AvizOP15mo ago
https://filebrowser-production-f8d0.up.railway.app/ It doesn't work, am I doing something wrong?
Brody
Brody15mo ago
check the deployment logs
Aviz
AvizOP15mo ago
yes, no volume attached, please attach a volume. upon attaching a volume let this service rebuild
No description
Brody
Brody15mo ago
so attach a volume
Aviz
AvizOP15mo ago
No description
Brody
Brody15mo ago
attach a volume
Aviz
AvizOP15mo ago
I didn't understand why it made an error, investigating
Brody
Brody15mo ago
^
Aviz
AvizOP15mo ago
Yes, but since it's inside the project, I would attach it to the volume created within the project. So, I'll need to recreate the volume and my code.
Aviz
AvizOP15mo ago
No description
Brody
Brody15mo ago
you can unmount the volume from your gestor service and attach it to the file browser service
Want results from more Discord servers?
Add your server