New answers tagged

0

There is a space missing between the t and the * in the open tag and you close the tag without the host:port part. <VirtualHost *:80> DocumentRoot /var/www/non.com ServerName non.com ServerAlias www.non.com <Directory "/var/www/non.com"> Options -Indexes +FollowSymLinks AllowOverride </Directory> ...


1

I've been struggling with this for hours, the problem for me was that were multiple apache instances running and "service apache restart" don't stop them, and they were serving the old certificate. The solution was: service apache2 stop pkill apache2 service apache2 start


1

This can be done using the below while also preserving the request URI, in case request URL is different from different users, which is normal when tunneling is needed to reach the web server. error_page 497 301 =307 https://$http_host$request_uri; http_post preserves both the host and the port in the URL.


2

The error: AH00132: file permissions deny server access "/var/www/html/index.html" is quite descriptive. The obvious solution is of course Adjust the file permissions and ensure that the Apache server is allowed to access your content. Find the current permissions. Not only on the index.html file, but also on all directories that make up the ...


0

There are two main methods to install a new PHP version and tell Apache to use it: mod_php and php-fpm. Note: The preffered method is php-fpm, and many new distributions (including Fedora) are using it by default. Install PHP as Apache SAPI module Here is the guide around this for Unix systems, from the official documentation. It has some missing points (at ...


1

I also had this problem, but the problem turned out to be a missing "ServerName" directive in the section. I suggest trying this modification to your configuration file: <VirtualHost ServerIP:443> ServerName host.domain # This parameter already existed as-is SSLEngine on # These are the parameters I changed (already existed w/ ...


0

In my case the solution was edit the /etc/apache2/ports.conf file in this way: # If you just change the port or add more ports here, you will likely also # have to change the VirtualHost statement in # /etc/apache2/sites-enabled/000-default.conf NameVirtualHost *:80 Listen 80 Listen 192.168.1.11:3001 <IfModule ssl_module> NameVirtualHost *:443 ...


0

Alternative to @StickByAtlas's answer you can set the Environment variable through the RewriteRule itself. Here is an example how I use it to load files from an external storage if they do not exist locally (.htaccess is inside the /download folder): RewriteEngine on # rewrite to external source if local file does not exist RequestHeader set Authorization &...


Top 50 recent answers are included