kyler
(Kyler Boudreau)
August 6, 2015, 6:29pm
1
Hey, I’m trying to increase the max file upload size on my site. I edited my config file per the instructions here:
https://meta.discourse.org/t/changing-max-attachment-size/26435
I rebuilt the app and then my discourse went down. So I removed the lines and rebooted the server. Back up now, but still now sure on how to do this.
Can someone tell me exactly what file to edit? I had Discourse.org install my forum on a Digital Ocean droplet, so everything is standard. Thanks!
You can SSH into discourse while you’re SSH’ed into your Droplet. From there, you could nano /etc/nginx/conf.d/discourse.conf
and edit the file directly.
Or I guess you could also copy the file from inside discourse to your host server,
$ scp discourseIP:/etc/nginx/conf.d/discourse.conf ~/discourse.conf
edit the file, and then scp
it back into the discourse container.
$ scp ~/discourse.conf discourseIP:/etc/nginx/conf.d/discourse.conf
Either way, once you’ve edited the file, you would have to tell the contained instance of nginx
to reload its configuration, like so:
$ docker exec discourse nginx -s reload
#Update
It turns out that there’s a parameter for it in the *.yml configuration. Just add upload_size: 5000M
.
Source: Changing Max Attachment Size
4 Likes
diogocsc
(Diogocsc)
July 20, 2018, 10:07pm
3
how do we know the ip of the discourse ?
sam
(Sam Saffron)
July 23, 2018, 12:39am
5
This is all documented in this howto:
If you are on managed hosting, you should contact your hosting provider to change this setting. The below instructions only apply if you self host your own instance of Discourse.
Here is what you need to do to allow more than 10mb for attachments upload.
Connect to your server via SSH
Navigate to and edit the .yml config file
cd /var/discourse/
nano containers/app.yml
Scroll down where it says this:
params:
## Which Git revision should this container use? (default: tests-…
3 Likes