Файл конфигурации moodle для nginx

baltun

Администратор
Сообщения
13.267
Реакции
3.363
Баллы
1.833
Часть файла конфигурации для работы moodle в nginx и панели ISPmanager:
Код:
    location / {
        rewrite ^/(.*.php)(/)(.*)$ /$1?file=/$3 last;
        location ~ [^/]\.ph(p\d*|tml)$ {
            try_files /does_not_exists @php;
        }
    }
    location /dataroot/ {
        internal; 
        alias /var/www/print/data/www/xxx.ru/data/moodledata/;
        expires 1y;
        add_header Cache-Control "public, immutable";
    }
    location @php {
        fastcgi_index index.php;
        fastcgi_param PHP_VALUE "
        max_input_vars = 30000
        upload_max_filesize = 999M";
        fastcgi_split_path_info  ^(.+\.php)(/.+)$;
        fastcgi_param PATH_INFO $fastcgi_path_info;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PHP_ADMIN_VALUE "sendmail_path = /usr/sbin/sendmail -t -i -f webmaster@xxx.ru";
        fastcgi_pass unix:/var/www/php-fpm/8.sock;
        try_files $uri =404;
        include fastcgi_params;
        include /etc/nginx/vhosts-resources/xxx.ru/dynamic/*.conf;
    }
 
Назад
Верх Низ