Compare commits
4 Commits
Author | SHA1 | Date |
---|---|---|
Daniel Berteaud | 468792e48e | 8 years ago |
Daniel Berteaud | b8c748a281 | 8 years ago |
Daniel Berteaud | d86b691fe1 | 8 years ago |
Daniel Berteaud | 2b37f09ca2 | 8 years ago |
7 changed files with 121 additions and 19 deletions
@ -0,0 +1,9 @@ |
|||||||
|
{ |
||||||
|
if ($fastcgi_mod eq 'mod_fastcgi'){ |
||||||
|
$OUT .=<<_EOF; |
||||||
|
Action phppydio-fastcgi /php-cgi-bin/phppydio-wrapper |
||||||
|
Alias /php-cgi-bin/phppydio-wrapper /var/www/php-cgi-bin/phppydio-wrapper |
||||||
|
FastCgiExternalServer /var/www/php-cgi-bin/phppydio-wrapper -socket /var/run/php-fpm/php__PHP_VERSION__-pydio.sock -pass-header Authorization -idle-timeout 120 |
||||||
|
_EOF |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,55 @@ |
|||||||
|
{ |
||||||
|
|
||||||
|
if ($PHP_VERSION eq '__PHP_VERSION__'){ |
||||||
|
if (($dl{'status'} || 'disabled') eq 'enabled'){ |
||||||
|
my $max_upload_size = $pydio{MaxUploadSize} || '4096'; |
||||||
|
$max_upload_size .= 'M' unless ($max_upload_size =~ m/[MG]$/); |
||||||
|
my $id = 'pydio'; |
||||||
|
my $homedir = $pydio{'HomeDir'} || 'none'; |
||||||
|
$homedir = (($homedir eq 'enabled') || ($homedir eq 'users')) ? ':/home/e-smith/files/users':''; |
||||||
|
|
||||||
|
$OUT .=<<_EOF; |
||||||
|
|
||||||
|
[php$PHP_VERSION-$id] |
||||||
|
user = www |
||||||
|
group = www |
||||||
|
listen.owner = root |
||||||
|
listen.group = www |
||||||
|
listen.mode = 0660 |
||||||
|
listen = /var/run/php-fpm/php$PHP_VERSION-$id.sock |
||||||
|
pm = dynamic |
||||||
|
pm.max_children = 15 |
||||||
|
pm.start_servers = 3 |
||||||
|
pm.min_spare_servers = 3 |
||||||
|
pm.max_spare_servers = 4 |
||||||
|
pm.max_requests = 1000 |
||||||
|
php_admin_value[session.save_path] = /var/lib/php/$id/session |
||||||
|
php_admin_value[opcache.file_cache] = /var/lib/php/$id/opcache |
||||||
|
php_admin_value[upload_tmp_dir] = /var/lib/php/$id/tmp |
||||||
|
php_admin_value[error_log] = /var/log/php/$id/error.log |
||||||
|
slowlog = /var/log/php/dl/slow.log |
||||||
|
php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f php@{ $DomainName } |
||||||
|
php_admin_flag[display_errors] = off |
||||||
|
php_admin_flag[log_errors] = on |
||||||
|
php_admin_value[error_log] = syslog |
||||||
|
php_admin_value[memory_limit] = 128M |
||||||
|
php_admin_value[max_execution_time] = 0 |
||||||
|
php_admin_value[post_max_size] = $max_upload_size |
||||||
|
php_admin_value[upload_max_filesize] = $max_upload_size |
||||||
|
php_admin_value[disable_functions] = system, show_source, symlink, dl, passthru, phpinfo, escapeshellcmd |
||||||
|
php_admin_value[open_basedir] = /usr/share/pydio:/var/lib/pydio:/var/log/pydio:/etc/pydio:/var/cache/pydio:/usr/share/pear/:/usr/share/php/:/home/e-smith/files/shares$homedir |
||||||
|
php_admin_flag[allow_url_fopen] = off |
||||||
|
php_admin_flag[file_upload] = on |
||||||
|
php_admin_flag[session.cookie_httponly] = on |
||||||
|
php_admin_flag[allow_url_include] = off |
||||||
|
php_admin_value[session.save_handler] = files |
||||||
|
php_admin_value[output_buffering] = off |
||||||
|
|
||||||
|
_EOF |
||||||
|
|
||||||
|
} |
||||||
|
else{ |
||||||
|
$OUT .= '; Pydio is disabled'; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
Loading…
Reference in new issue