I tried asking this before but although I took all of the advised steps, nothing happened. Basically, I want to create a website like www.example.com. I can open HTML files in my browser using the LocalHost server, but I want this webpage to be visible to other users on other devices in other locations using the internet.
Here is a link to the question I asked previously
I was able to take all of the suggested steps. First, I created the file /var/www/html/index.html. Then, I created the file /etc/apache2/sites-available/index.conf with this information:
<VirtualHost *:80>
ServerName test.com
ServerAdmin info@test.com
ServerAlias www.test.com
DocumentRoot /var/www/html
<Directory /var/www/html>
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Then I ran this command: sudo a2ensite index.conf
And then I ran this command: sudo systemctl restart apache2
However, nothing happened after that. I have tried this many times. Does anyone have any ideas on what to do?
And as you can see, the information from the config isn't pasting correctly. I'll take a screenshot of it instead.
– Ruairí Másún Jan 27 '19 at 18:36