-
Hi Cockpit developers, I'm building a server with Cockpit and two virtual machines. In both virtual machines I want to install a web server. How can I set up a reverse proxy (with Apache) on the host in such a way that when you visit domain A you are redirected to virtual machine A, and when you visit domain B you are redirected to virtual machine B?
I think this is a common scenario so there must be some good documentation about this somewhere? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
For everybody who has the same problem, this is how I did it.
This setup only forwards HTTP request. |
Beta Was this translation helpful? Give feedback.
For everybody who has the same problem, this is how I did it.
Install the Apache web server.
sudo dnf install httpd
Enable the Apache web server in systemd.
sudo systemctl enable httpd
Start the Apache web server.
sudo systemctl start httpd
Open port 80 and 443 in the firewall.
Create a new virtual hosts file.
sudo vim /etc/httpd/conf.d/virtualhosts.conf
Add the following code.