![]() |
VOOZH | about |
Thanks for learning with the DigitalOcean Community. Check out our offerings for compute, storage, networking, and managed databases.
Open source advocate and lover of education, culture, and community.
With over 6 years of experience in tech publishing, Mani has edited and published more than 75 books covering a wide range of data science topics. Known for his strong attention to detail and technical knowledge, Mani specializes in creating clear, concise, and easy-to-understand content tailored for developers.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Thank you very much for your easy instructions on installing Apache2 server. it still proves that it takes a woman to get things right. I just switched over from centos 7 to the ubuntu 20.04 server due to vestacp problems and no kind of support for why my add on domains would not work but yet the main admin one would. still baffels me, but iβm a glutten for punishment so thought i would try it out on ubuntu 20.04. any way thanks for the excellent info and help the enternet needs more like you.
Hello!
Thanks for sharing this information. Here is a question
I have a website(example.com) already running in /var/www/html can i add another website (newdomain.com) by creating directory /var/www/newdomain.com and use it. Without changing the location of example.com as you know it will take time to transfer from /var/www/html to /var/www/example.com
Yes, iβm using Apache Web Server on Ubuntu 20.04 (LTS) x64
Please reply me ASAP
Now itβs easy, you can use easy-apache to set up everything for you, all you have to do is copy-paste below lines into your terminal, and enter your domain name when asked, it will also install SSL if you want
sudo add-apt-repository ppa:realpvn/easy-apache
sudo apt-get update
sudo apt-get install easy-apache
#to install Apache server
easy-apache -a
#to install SSL
easy-apache -s
#full setup, Apache and SSL
easy-apache -f
A very nice piece of Information. Nicely written. Thanks a lot. I was wondering for basic apache server setup. I will remember your name as my teacher. GBY.
how do I make my site visible to any other computer?
Issue: Error AH00558: Could not reliably determine the serverβs fully qualified domain name
Solution: Add a line containing ServerName 127.0.0.1 to the end of the file:
sudo nano /etc/apache2/apache2.conf
Restart apache2
sudo systemctl restart apache2
=========================================================
Issue: can access the website via IP but not Domain Solution:
sudo nano /etc/hosts
add this code:
127.0.0.1 www.YOURDOMAIN.com
Restart apache2
sudo systemctl restart apache2
Worked great Thank you for the walkthrough!!!
Do we need to add /public_html to the directory if we want to add more than one virtual host site? If I add one using the above method it works fine but if I add a second one the second one wonβt show up.
Thanks Erin!
Just a comment, that could help people. When following your tutorial after doing the configtest of apache I found ERROR AH00558. Since I was starting from scratch from a Desktop 20.04 Ubuntu distribution, I assume that it will happen to anybody doing the same thing.
The fix is easy, just add to your tutorial that if they find this error all they need to do is to add this line to their /etc/apache2/apache2.conf file using sudo nano /etc/apache2/apache2.conf, going to the end of the file and adding it, then <Ctrl>S, followed by <Ctrl>X
ServerName 127.0.0.1
This is one of the best-written tutorials Iβve ever followed. Thanks, Erin!
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.