libretime/installer/apache/libretime.conf
Jonas L 95a7411c0c
feat: improve apache configuration (#1784)
- merge php config in apache config
- remove deprecated php config
- remove old apache config
- use dedicated log files for libretime vhost
- change template variables format

BREAKING: The apache configuration file has been updated and renamed. You must remove the old configuration files `/etc/apache2/sites-available/airtime*` file from the system.

BREAKING: The php configuration file has been merged in the apache configuration. You need to remove the `/etc/php/*/apache2/conf.d/airtime.ini` file from the system.
2022-04-25 12:46:30 +02:00

46 lines
1.4 KiB
ApacheConf

@@LISTEN_PORT_STRING@@
<VirtualHost *:@@LISTEN_PORT@@>
ServerAdmin webmaster@localhost
DocumentRoot @@LEGACY_WEB_ROOT@@/public
ErrorLog ${APACHE_LOG_DIR}/libretime.error.log
CustomLog ${APACHE_LOG_DIR}/libretime.access.log combined
AddOutputFilterByType DEFLATE text/plain text/html text/css application/javascript application/json
php_admin_value memory_limit 512M
php_admin_value post_max_size 512M
php_admin_value upload_max_filesize 512M
php_admin_value upload_tmp_dir /tmp
php_admin_value request_order GPC
php_admin_value session.gc_probability 0
php_admin_value session.auto_start 0
<Directory @@LEGACY_WEB_ROOT@@/public>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]
DirectoryIndex index.php
AllowOverride all
Order allow,deny
Allow from all
Require all granted
</Directory>
ProxyPreserveHost On
ProxyPass /api/v2/ http://localhost:8081/api/v2/
ProxyPassReverse /api/v2/ http://localhost:8081/api/v2/
ProxyPass /api-auth/ http://localhost:8081/api-auth/
ProxyPassReverse /api-auth/ http://localhost:8081/api-auth/
</VirtualHost>
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet