File humhub-apache.conf of Package humhub

Alias /humhub "__humhub_web__"
Header append Vary User-Agent env=!dont-vary

<IfModule mod_php8.c>
    php_admin_value open_basedir "__humhub_web__:__humhub_conf__:__humhub_log__:/tmp:/usr/bin:/var/cache/apache2:/run/humhub_sessions"
    php_admin_flag display_startup_errors Off
    php_admin_flag display_errors Off
    php_admin_flag file_uploads Off
    php_admin_flag allow_url_fopen Off
    php_admin_value upload_tmp_dir "/var/cache/apache2"
    php_admin_value session.save_path "/run/humhub_sessions/"
    php_admin_value disable_functions "posix_setpgid,exec,ftp_login,mysql_pconnect,apache_setenv,popen,posix_getpwuid,posix_setsid,passthru,escapeshellcmd,ini_alter,ftp_raw,ftp_nb_fput,ini_restore,shell_exec,ftp_get,proc_get_status,highlight_file,proc_close,proc_terminate,syslog,ftp_connect,posix_uname,ini_get_all,proc_open,posix_kill,escapeshellarg,ftp_rawlist,posix_setuid,openlog,php_uname,system,ftp_exec,posix_mkfifo,proc_nice,ftp_put"
    php_admin_value memory_limit "1024M"
    php_admin_value max_execution_time 120
</IfModule>

<IfModule mod_deflate.c>
     AddOutputFilterByType DEFLATE text/css application/x-javascript text/x-component text/html text/plain text/xml application/javascript
     <IfModule mod_setenvif.c>
         BrowserMatch ^Mozilla/4 gzip-only-text/html
         BrowserMatch ^Mozilla/4.0[678] no-gzip
         BrowserMatch bMSIE !no-gzip !gzip-only-text/html
     </IfModule>
</IfModule>

<Directory "__humhub_web__">
    Options -Indexes +FollowSymLinks
    AllowOverride All
    Require all granted
</Directory>

<DirectoryMatch "__humhub_web__/(\.|protected|themes/\w+/views|uploads/file)">
    Require all denied
</DirectoryMatch>

<FilesMatch "^\.">
    Require all denied
</FilesMatch>

<DirectoryMatch "__humhub_web__/(static|uploads|themes|assets)">
    Header set Cache-Control "max-age=172800, public"
</DirectoryMatch>

<IfModule mod_mime.c>
    AddType application/x-javascript .js
    AddType text/css .css
</IfModule>
openSUSE Build Service is sponsored by