DEV Community

JohnOdhiambo
JohnOdhiambo

Posted on

SET UP VIRTUAL ENVIRONMENT IN UBUNTU

cd /etc/apache2/sites-available/

sudo cp 000-default.conf salespro.conf

sudo vim salespro.conf

ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/Salespro
ServerName servername_example

AllowOverride All

--Add the new servername_example to list of hosts
sudo vim /etc/hosts
For example, 127.0.0.1 servername_example

--Enable a new virtual host file
sudo a2ensite salespro.conf

--Restart the server
sudo systemctl restart apache2

Top comments (0)

Billboard image

Create up to 10 Postgres Databases on Neon's free plan.

If you're starting a new project, Neon has got your databases covered. No credit cards. No trials. No getting in your way.

Try Neon for Free →

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay