Add max upload size to nginx (#7358)

This commit is contained in:
Slaviša Arežina 2025-09-02 22:16:48 +02:00 committed by GitHub
parent be5d65f421
commit 8a7eeee727
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 0 deletions

View File

@ -27,6 +27,9 @@ function update_script() {
msg_error "No ${APP} Installation Found!"
exit
fi
if ! grep -q "client_max_body_size[[:space:]]\+100M;" /etc/nginx/conf.d/snipeit.conf; then
sed -i '/index index.php;/i \ client_max_body_size 100M;' /etc/nginx/conf.d/snipeit.conf
fi
if check_for_gh_release "snipe-it" "snipe/snipe-it"; then
msg_info "Stopping Services"

View File

@ -62,6 +62,7 @@ server {
listen 80;
root /opt/snipe-it/public;
server_name $IPADDRESS;
client_max_body_size 100M;
index index.php;
location / {