This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Pages: [1]
1
Apache / Site redirecting to usr/local/apache/htdocs
« on: April 15, 2018, 03:07:15 AM »
Hello,
When I'm accessing my website (lets call it example.com for the sake of this post) via https://www.example.com it goes to the usr/local/apache/htdocs folder but on all other combination (http://www/ex... , http://ex... and https://ex...) it works fine.
I'm somewhat new to server-side stuff, but an hours Googling has informed me that it is most likely my vhosts.
The vhosts.conf is currently this (IP and website name changed obviously)
And the vhosts-ssl-letsencrypt.conf is currently this (IP and website name changed obviously)
Any ideas of what may be causing it?
When I'm accessing my website (lets call it example.com for the sake of this post) via https://www.example.com it goes to the usr/local/apache/htdocs folder but on all other combination (http://www/ex... , http://ex... and https://ex...) it works fine.
I'm somewhat new to server-side stuff, but an hours Googling has informed me that it is most likely my vhosts.
The vhosts.conf is currently this (IP and website name changed obviously)
Code: [Select]
# vhost_start example.com
<VirtualHost MYIP:80>
ServerName example.com
ServerAlias www.example.com
ServerAdmin webmaster@example.com
DocumentRoot /home/example/public_html
UseCanonicalName Off
ScriptAlias /cgi-bin/ /home/example/public_html/cgi-bin/
# Custom settings are loaded below this line (if any exist)
# Include "/usr/local/apache/conf/userdata/example/example.com/*.conf
<IfModule mod_userdir.c>
UserDir disabled
UserDir enabled example
</IfModule>
<IfModule mod_suexec.c>
SuexecUserGroup example example
</IfModule>
<IfModule mod_suphp.c>
suPHP_UserGroup example example
suPHP_ConfigPath /home/example
</IfModule>
<Directory "/home/example/public_html">
AllowOverride All
</Directory>
</VirtualHost>
# vhost_end example.com
And the vhosts-ssl-letsencrypt.conf is currently this (IP and website name changed obviously)
Code: [Select]
# vhost_start example.com
<VirtualHost MYIP:80>
ServerName example.com
ServerAlias www.example.com
ServerAdmin webmaster@example.com
DocumentRoot /home/example/public_html
SSLEngine on
SSLCertificateFile /etc/letsencrypt/live/example.com/cert.pem
SSLCertificateKeyFile /etc/letsencrypt/live/example.com/privkey.pem
SSLCertificateChainFile /etc/letsencrypt/live/example.com/fullchain.pem
SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown
<IfModule mod_suexec.c>
SuexecUserGroup example example
</IfModule>
<IfModule mod_suphp.c>
suPHP_UserGroup example example
suPHP_ConfigPath /home/example
</IfModule>
<Directory "/home/example/public_html">
AllowOverride All
</Directory>
</VirtualHost>
# vhost_end example.com
Any ideas of what may be causing it?
Pages: [1]