When I go to my ip address an index file is served.
However when I navigate to my domain name a page isn’t served.
Apache won’t serve content from my (domain name) web directory.
I don’t plan to install PHP or a Database until the virtual hosts implementation is legit.
I’ve reinstalled my image more times than I can count to get my websites migrated to a virtual server. The biggest sticking point is configuring the virtual hosts. My latest attempt was using this blog article:
https://www.tecmint.com/install-apache-with-virtual-hosts-on-debian-10/
Before that it was this article in previous attempts:
https://www.digitalocean.com/community/tutorials/how-to-install-linux-apache-mariadb-php-lamp-stack-on-debian-10
I looked at this article too:
https://linuxize.com/post/how-to-set-up-apache-virtual-hosts-on-debian-10/
I saw mentions of a user called www-data during my internet search but it isn’t mentioned in the three blog posts I cited.
My hosting company keeps telling me to use Plesk but they didn’t configure the shared hosting environment for the migration extension.
So I can’t use Plesk to migrate and they charge me a monthly fee for the Plesk license if it is installed on the image.
<VirtualHost *:80>
ServerName example.com
ServerAlias www.example.com
ServerAdmin [email protected]
DocumentRoot /var/www/html/example.com
<Directory /var/www/html/example.com>
Options -Indexes +FollowSymLinks
AllowOverride All
</Directory>
ErrorLog ${APACHE_LOG_DIR}/example.com-error.log
CustomLog ${APACHE_LOG_DIR}/example.com-access.log combined
/etc/apache2/sites-available/example.com.conf
2
Answers
I looked at the domain name in other browsers and Chrome is forcing HTTPS at my request. I didn't get around to reinstalling the SSL/TLS because of the confusion with the virtual hosts. So basically the page has been live the entire time but Chrome wouldn't connect because a secure connection was unavailable.
This probably is not the correct answer, but I went into my file
/etc/apache2/sites-enabled/000-default.conf
and changed the lines from: