summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr/local/etc/apache24/Includes/nextcloud.53hor.net.conf38
-rw-r--r--usr/local/etc/apache24/httpd.conf132
-rw-r--r--usr/local/etc/apache24/modules.d/001_mod_php.conf6
3 files changed, 158 insertions, 18 deletions
diff --git a/usr/local/etc/apache24/Includes/nextcloud.53hor.net.conf b/usr/local/etc/apache24/Includes/nextcloud.53hor.net.conf
index 2bf47a9..9fd015f 100644
--- a/usr/local/etc/apache24/Includes/nextcloud.53hor.net.conf
+++ b/usr/local/etc/apache24/Includes/nextcloud.53hor.net.conf
@@ -1,20 +1,22 @@
<VirtualHost *:80>
- DocumentRoot "/usr/local/www/apache24/data/nextcloud"
- ServerName <domain name>
- RewriteEngine on
- RewriteCond %{SERVER_NAME} =<domain name>
- RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,QSA,R=permanent]
- #ErrorLog ${APACHE_LOG_DIR}/error.log
- #CustomLog ${APACHE_LOG_DIR}/access.log combined
+ DocumentRoot "/usr/local/www/nextcloud"
+ ServerName nextcloud.53hor.net
+ RewriteEngine on
+ RewriteCond %{SERVER_NAME} =nextcloud.53hor.net
+ RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,QSA,R=permanent]
+ #ErrorLog ${APACHE_LOG_DIR}/error.log
+ #CustomLog ${APACHE_LOG_DIR}/access.log combined
- <Directory /usr/local/www/apache24/data/nextcloud/>
- Options +FollowSymlinks
- AllowOverride All
- <IfModule mod_dav.c>
- Dav off
- </IfModule>
- SetEnv HOME /usr/local/www/apache24/data/nextcloud
- SetEnv HTTP_HOME /usr/local/www/apache24/data/nextcloud
- Satisfy Any
- </Directory>
- </VirtualHost>
+ <Directory /usr/local/www/nextcloud/>
+ Options +FollowSymlinks
+ AllowOverride All
+
+ <IfModule mod_dav.c>
+ Dav off
+ </IfModule>
+
+ SetEnv HOME /usr/local/www/nextcloud
+ SetEnv HTTP_HOME /usr/local/www/nextcloud
+ Satisfy Any
+ </Directory>
+</VirtualHost>
diff --git a/usr/local/etc/apache24/httpd.conf b/usr/local/etc/apache24/httpd.conf
index e69de29..89e144e 100644
--- a/usr/local/etc/apache24/httpd.conf
+++ b/usr/local/etc/apache24/httpd.conf
@@ -0,0 +1,132 @@
+
+ServerRoot "/usr/local"
+
+
+Listen 80
+
+LoadModule mpm_prefork_module libexec/apache24/mod_mpm_prefork.so
+LoadModule authn_file_module libexec/apache24/mod_authn_file.so
+LoadModule authn_core_module libexec/apache24/mod_authn_core.so
+LoadModule authz_host_module libexec/apache24/mod_authz_host.so
+LoadModule authz_groupfile_module libexec/apache24/mod_authz_groupfile.so
+LoadModule authz_user_module libexec/apache24/mod_authz_user.so
+LoadModule authz_core_module libexec/apache24/mod_authz_core.so
+LoadModule access_compat_module libexec/apache24/mod_access_compat.so
+LoadModule auth_basic_module libexec/apache24/mod_auth_basic.so
+LoadModule reqtimeout_module libexec/apache24/mod_reqtimeout.so
+LoadModule filter_module libexec/apache24/mod_filter.so
+LoadModule mime_module libexec/apache24/mod_mime.so
+LoadModule log_config_module libexec/apache24/mod_log_config.so
+LoadModule env_module libexec/apache24/mod_env.so
+LoadModule headers_module libexec/apache24/mod_headers.so
+LoadModule setenvif_module libexec/apache24/mod_setenvif.so
+LoadModule version_module libexec/apache24/mod_version.so
+LoadModule unixd_module libexec/apache24/mod_unixd.so
+LoadModule status_module libexec/apache24/mod_status.so
+LoadModule autoindex_module libexec/apache24/mod_autoindex.so
+LoadModule rewrite_module libexec/apache24/mod_rewrite.so
+LoadModule php7_module libexec/apache24/libphp7.so
+<IfModule php7_module>
+ <FilesMatch "\.(php|phps|php7|phtml)$">
+ SetHandler php7-script
+ </FilesMatch>
+ DirectoryIndex index.php
+</IfModule>
+<IfModule !mpm_prefork_module>
+</IfModule>
+<IfModule mpm_prefork_module>
+</IfModule>
+LoadModule dir_module libexec/apache24/mod_dir.so
+LoadModule alias_module libexec/apache24/mod_alias.so
+
+IncludeOptional etc/apache24/modules.d/[0-9][0-9][0-9]_*.conf
+
+<IfModule unixd_module>
+User www
+Group www
+
+</IfModule>
+
+
+ServerAdmin you@example.com
+
+
+<Directory />
+ AllowOverride none
+ Require all denied
+</Directory>
+
+
+DocumentRoot "/usr/local/www/apache24/data"
+<Directory "/usr/local/www/apache24/data">
+ Options Indexes FollowSymLinks
+
+ AllowOverride None
+
+ Require all granted
+</Directory>
+
+<IfModule dir_module>
+ DirectoryIndex index.html
+ </IfModule>
+
+<Files ".ht*">
+ Require all denied
+</Files>
+
+ErrorLog "/var/log/httpd-error.log"
+
+LogLevel warn
+
+<IfModule log_config_module>
+ LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
+ LogFormat "%h %l %u %t \"%r\" %>s %b" common
+
+ <IfModule logio_module>
+ LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
+ </IfModule>
+
+ CustomLog "/var/log/httpd-access.log" common
+
+</IfModule>
+
+<IfModule alias_module>
+
+
+ ScriptAlias /cgi-bin/ "/usr/local/www/apache24/cgi-bin/"
+
+</IfModule>
+
+<IfModule cgid_module>
+</IfModule>
+
+<Directory "/usr/local/www/apache24/cgi-bin">
+ AllowOverride None
+ Options None
+ Require all granted
+</Directory>
+
+<IfModule headers_module>
+ RequestHeader unset Proxy early
+</IfModule>
+
+<IfModule mime_module>
+ TypesConfig etc/apache24/mime.types
+
+ AddType application/x-compress .Z
+ AddType application/x-gzip .gz .tgz
+
+ AddType application/x-httpd-php-source .phps
+ AddType application/x-httpd-php .php
+
+</IfModule>
+<IfModule proxy_html_module>
+Include etc/apache24/extra/proxy-html.conf
+</IfModule>
+
+<IfModule ssl_module>
+SSLRandomSeed startup builtin
+SSLRandomSeed connect builtin
+</IfModule>
+
+Include etc/apache24/Includes/*.conf
diff --git a/usr/local/etc/apache24/modules.d/001_mod_php.conf b/usr/local/etc/apache24/modules.d/001_mod_php.conf
index e69de29..f756a81 100644
--- a/usr/local/etc/apache24/modules.d/001_mod_php.conf
+++ b/usr/local/etc/apache24/modules.d/001_mod_php.conf
@@ -0,0 +1,6 @@
+<FilesMatch "\.php$">
+ SetHandler application/x-httpd-php
+</FilesMatch>
+<FilesMatch "\.phps$">
+ SetHandler application/x-httpd-php-source
+</FilesMatch>