Discussion:
[Mayan EDMS: 1557] Where do I adjust the size limit on uploads
Mark Phillips
2017-03-23 20:05:02 UTC
Permalink
I tried, as the default admin user, to upload a tiff file as a new
document. I had a document type of Picture defined. I got an error that the
image is too big. Please see the attached screen shot, as the error is a
little weird in its presentation.

Where do I change the size limit on file uploads?

Thanks,

Mark
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Mathias Behrle
2017-03-24 08:35:50 UTC
Permalink
* Mark Phillips: " [Mayan EDMS: 1557] Where do I adjust the size limit on
Post by Mark Phillips
I tried, as the default admin user, to upload a tiff file as a new
document. I had a document type of Picture defined. I got an error that the
image is too big. Please see the attached screen shot, as the error is a
little weird in its presentation.
Where do I change the size limit on file uploads?
Thanks,
Mark
Since you seem to run behind nginx consider increasing

client_max_body_size

in your nginx configuration.

HTH,
Mathias
--
Mathias Behrle
PGP/GnuPG key availabable from any keyserver, ID: 0xD6D09BE48405BBF6
AC29 7E5C 46B9 D0B6 1C71 7681 D6D0 9BE4 8405 BBF6
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Jesaja Everling
2017-03-24 09:25:40 UTC
Permalink
You might also have to adjust the corresponding setting in your wsgi (e.g.
uwsgi) config.
Post by Mathias Behrle
* Mark Phillips: " [Mayan EDMS: 1557] Where do I adjust the size limit on
Post by Mark Phillips
I tried, as the default admin user, to upload a tiff file as a new
document. I had a document type of Picture defined. I got an error that
the
Post by Mark Phillips
image is too big. Please see the attached screen shot, as the error is a
little weird in its presentation.
Where do I change the size limit on file uploads?
Thanks,
Mark
Since you seem to run behind nginx consider increasing
client_max_body_size
in your nginx configuration.
HTH,
Mathias
--
Mathias Behrle
PGP/GnuPG key availabable from any keyserver, ID: 0xD6D09BE48405BBF6
AC29 7E5C 46B9 D0B6 1C71 7681 D6D0 9BE4 8405 BBF6
--
---
You received this message because you are subscribed to the Google Groups
"Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Roberto Rosario
2017-04-19 15:13:50 UTC
Permalink
This is the NGINX configuration file used in the Mayan Docker image. The
max file size is set to 50 megabytes and the max upload wait time is 30
seconds. Both can be increased by any amount.

server {
listen 80;

location / {
include uwsgi_params;
uwsgi_pass unix:/run/mayan.sock;

client_max_body_size 50M; # Increase if your plan to upload bigger
documents
proxy_read_timeout 30s; # Increase if your document uploads take
more than 30 seconds
}

location /static {
alias /usr/local/lib/python2.7/dist-packages/mayan/media/static;
expires 1h;
}

location /favicon.ico {
alias
/usr/local/lib/python2.7/dist-packages/mayan/media/static/appearance/images/favicon.ico;
expires 1h;
}
}
Post by Jesaja Everling
You might also have to adjust the corresponding setting in your wsgi (e.g.
uwsgi) config.
Post by Mathias Behrle
* Mark Phillips: " [Mayan EDMS: 1557] Where do I adjust the size limit on
Post by Mark Phillips
I tried, as the default admin user, to upload a tiff file as a new
document. I had a document type of Picture defined. I got an error that
the
Post by Mark Phillips
image is too big. Please see the attached screen shot, as the error is a
little weird in its presentation.
Where do I change the size limit on file uploads?
Thanks,
Mark
Since you seem to run behind nginx consider increasing
client_max_body_size
in your nginx configuration.
HTH,
Mathias
--
Mathias Behrle
PGP/GnuPG key availabable from any keyserver, ID: 0xD6D09BE48405BBF6
AC29 7E5C 46B9 D0B6 1C71 7681 D6D0 9BE4 8405 BBF6
--
---
You received this message because you are subscribed to the Google Groups
"Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
David Kornahrens
2017-06-27 17:52:44 UTC
Permalink
Robert,
I cannot find where the Docker location is for the php.ini file. We run
NGINX and are hosted on Digital Ocean. Any ideas?

Thanks,
David
Post by Roberto Rosario
This is the NGINX configuration file used in the Mayan Docker image. The
max file size is set to 50 megabytes and the max upload wait time is 30
seconds. Both can be increased by any amount.
server {
listen 80;
location / {
include uwsgi_params;
uwsgi_pass unix:/run/mayan.sock;
client_max_body_size 50M; # Increase if your plan to upload
bigger documents
proxy_read_timeout 30s; # Increase if your document uploads take
more than 30 seconds
}
location /static {
alias /usr/local/lib/python2.7/dist-packages/mayan/media/static;
expires 1h;
}
location /favicon.ico {
alias
/usr/local/lib/python2.7/dist-packages/mayan/media/static/appearance/images/favicon.ico;
expires 1h;
}
}
Post by Jesaja Everling
You might also have to adjust the corresponding setting in your wsgi
(e.g. uwsgi) config.
Post by Mathias Behrle
* Mark Phillips: " [Mayan EDMS: 1557] Where do I adjust the size limit on
Post by Mark Phillips
I tried, as the default admin user, to upload a tiff file as a new
document. I had a document type of Picture defined. I got an error
that the
Post by Mark Phillips
image is too big. Please see the attached screen shot, as the error is
a
Post by Mark Phillips
little weird in its presentation.
Where do I change the size limit on file uploads?
Thanks,
Mark
Since you seem to run behind nginx consider increasing
client_max_body_size
in your nginx configuration.
HTH,
Mathias
--
Mathias Behrle
PGP/GnuPG key availabable from any keyserver, ID: 0xD6D09BE48405BBF6
AC29 7E5C 46B9 D0B6 1C71 7681 D6D0 9BE4 8405 BBF6
--
---
You received this message because you are subscribed to the Google
Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send
For more options, visit https://groups.google.com/d/optout.
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Roberto Rosario
2017-06-27 19:00:44 UTC
Permalink
There is no php.ini in Mayan, as it is a Python project all files end in
.py.

To increase the file upload limits change the NGINX file as mentioned
above. Inside a container this file is located in
/etc/nginx/sites-enabled/mayan-edms
If you wish to build a customized image, the NGINX file path is
/etc/nginx/mayan-edms in the Docker image source files
(https://gitlab.com/mayan-edms/mayan-edms-docker).
Post by David Kornahrens
Robert,
I cannot find where the Docker location is for the php.ini file. We run
NGINX and are hosted on Digital Ocean. Any ideas?
Thanks,
David
Post by Roberto Rosario
This is the NGINX configuration file used in the Mayan Docker image. The
max file size is set to 50 megabytes and the max upload wait time is 30
seconds. Both can be increased by any amount.
server {
listen 80;
location / {
include uwsgi_params;
uwsgi_pass unix:/run/mayan.sock;
client_max_body_size 50M; # Increase if your plan to upload
bigger documents
proxy_read_timeout 30s; # Increase if your document uploads take
more than 30 seconds
}
location /static {
alias /usr/local/lib/python2.7/dist-packages/mayan/media/static;
expires 1h;
}
location /favicon.ico {
alias
/usr/local/lib/python2.7/dist-packages/mayan/media/static/appearance/images/favicon.ico;
expires 1h;
}
}
Post by Jesaja Everling
You might also have to adjust the corresponding setting in your wsgi
(e.g. uwsgi) config.
Post by Mathias Behrle
* Mark Phillips: " [Mayan EDMS: 1557] Where do I adjust the size limit on
Post by Mark Phillips
I tried, as the default admin user, to upload a tiff file as a new
document. I had a document type of Picture defined. I got an error
that the
Post by Mark Phillips
image is too big. Please see the attached screen shot, as the error
is a
Post by Mark Phillips
little weird in its presentation.
Where do I change the size limit on file uploads?
Thanks,
Mark
Since you seem to run behind nginx consider increasing
client_max_body_size
in your nginx configuration.
HTH,
Mathias
--
Mathias Behrle
PGP/GnuPG key availabable from any keyserver, ID: 0xD6D09BE48405BBF6
AC29 7E5C 46B9 D0B6 1C71 7681 D6D0 9BE4 8405 BBF6
--
---
You received this message because you are subscribed to the Google
Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send
For more options, visit https://groups.google.com/d/optout.
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
David Kornahrens
2017-06-28 18:16:35 UTC
Permalink
Roberto,
Apologize for asking this. Feels like I'm beating a dead horse, but I used
the docker install method and I cannot even find the NGINX folder at all.

I have navigated to /etc with no NGINX folder available.
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Roberto Rosario
2017-06-28 21:26:45 UTC
Permalink
Go inside the running container with:

docker exec -ti mayan-edms /bin/bash

This executes a bash shell inside the container. The command prompt should
display something like this:

***@9210b0c7f945:/#

Now do a:

cat /etc/nginx/sites-enabled/mayan-edms

You should see the file contents.

There are no editors included in the container to cut size. To edit the
file you need to install one using:

apt-get update && apt-get install vim -y

Afterwards use vi /etc/nginx/site-enabled/mayan-edms

Enter insert mode pressing the key <a>.
Make the changes.
Increase client_max_body_size (It's set at 500M = 500 megabytes).
Increase proxy_read_timeout (maximum time an upload can take before it
timesout. It's set at 600s = 600 seconds = 10 minutes).
Leave insert mode pressing <ESC>
Save pressing <:> and then <w>
Exit the editor using <:> and then <q>

Restart the NGINX server using:

supervisorctl restart nginx

I'll check if NGINX supports environment variables, and make these settings
configurable at runtime without having to edit this file.
This is not directly related to Mayan and therefore lower in the priority
schedule, so it can take a while.
Post by David Kornahrens
Roberto,
Apologize for asking this. Feels like I'm beating a dead horse, but I
used the docker install method and I cannot even find the NGINX folder at
all.
I have navigated to /etc with no NGINX folder available.
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
David Kornahrens
2017-06-29 00:37:25 UTC
Permalink
Thank you sir for the response. I'll test in then morning. I'm sure it
will function as expected!
--
---
You received this message because you are subscribed to the Google Groups "Mayan EDMS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mayan-edms+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...