Questions tagged [virtualhost]

Questions relating to virtual hosting; that is, serving content for multiple logically-separate entities from the same machine. Usually relates to name-based virtual hosting in the web server, but can also cover other protocols such as SMTP or IMAP.

Filter by
Sorted by
Tagged with
0 votes
0 answers
7 views

Block all IP's except HOME IP in Nginx Netdata virtual host file on Ubuntu Server 20.04

I'm running Ubuntu Server 20.04, and have successfully set up netdata. My netdata's Nginx virtual host file looks like this: upstream backend { server 127.0.0.1:19999; keepalive 64; } server { ...
  • 83
0 votes
1 answer
23 views

Apache httpd on a backup machine where hostname is not matching

I have to run an Apache httpd server on a backup machine, which is a CentOS. In this case, it is a WordPress multisite installation. Since it is a backup machine, the DNS server does not point to the ...
0 votes
1 answer
20 views

Drop all connections from other domain except from original domain on Apache 2.4

I have ubuntu server with apache 2.4 web server and original domain is running with ssl. Someone pointed their domain to my server and in my virtual host, it specify there the servername and ...
0 votes
0 answers
17 views

Redirection of only home page to 404 not working

What is needed is that https://cpc.dev.company.eu should redirected to 404 page, and all other like https://cpc.dev.company.eu/* and app1.dev.company.eu & app1.dev.company.eu/* should work as it ...
0 votes
1 answer
85 views

Apache virtualhost port 443 serves content from port 80 configuration

I'm running Apache 2.4.52 on Ubuntu Server 22.04. I'm trying to run https through port 443, eventually aiming to have a redirect from port 80 to force content on https. However, Apache seems to be ...
  • 21
0 votes
0 answers
29 views

Cannot get HomeBrew Apache/2.4.54 Virtual Hosts to listen on all Network Interfaces

I have tried to configure Apache virtual hosts to respond to connections on all of my network interfaces (external, private, loopback) on port 8080, but to no luck. Here's what I have done so far on ...
0 votes
0 answers
110 views

Magento 2 running on Ubuntu 20.04 with Nginx returns Bad Gateway Error code 502

I have a fresh install of Magento 2.4.4-p2 on Ubuntu 20.04. The PHP version is 8.1.13 and the nginx version is 1.18.0 (Ubuntu). I can see and access the home page and the following pages without 502 ...
  • 123
1 vote
0 answers
93 views

Apache 2.4 "Require ip" not working for /server-status, /phpMyAdmin etc with VirtualHost directives added in httpd.conf

I recently changed using the Event MPM in my Apache 2.4 installation, alongside PHP-FPM and FastCGI proxy, I hope that wasn't the reason for my problem. I also started working with name-based ...
  • 77
0 votes
0 answers
28 views

OHS ProxyPass returning a 403

I've setup an OHS server (managed by me) to be used to proxy requests to another server (not managed by me). As of right now, the relevant part of the OHS server's virtual_hosts.conf looks like this: &...
  • 35
0 votes
1 answer
42 views

Apache2 how to generate random string for subdomain

I want to issue a redirect to a new randomly generated subdomain name for every request I get. Below you can find my vhost configuration. I want to do a redirect towards a subdomain containing some ...
  • 131
0 votes
0 answers
12 views

Apache ReverseProxy keeps redirecting to another virtual hosts

I have apache as a reverse proxy for Webmin (port 10000) backend. Both are on the same server. Here's my config file: <VirtualHost *:*> ProxyPreserveHost On ServerName srvadm.****.com ...
  • 103
0 votes
2 answers
41 views

Apache VirtualHost - per user ProxyPass

I'm trying to configure Apache to redirect users to different paths based on their authentication credentials (using htpasswd). I've managed to set up ProxyPass, which enables the redirection of the ...
  • 1
0 votes
1 answer
19 views

How to make site map file public on site secured by shibboleth

We use shibboleth to secure an apache virtualhost. We would like to make single file (a site map) available publicly for this site. Is there way to code this in the virtualhost? The current virtual ...
0 votes
0 answers
51 views

How to redirect subdomain in apache virtualhost (CentOS8)?

I have an apache virtual host for the main domain and subdomain as below. <VirtualHost *:80> ServerName example.com DocumentRoot /var/www/html/example/public <Directory /var/www/html/...
0 votes
0 answers
23 views

How to make redirect rewrite rule for https subdomain on apache (CentOS8)?

I have own domain for example. https://example.com Below is my apache virtual host with 301 redirect rewrite rule. <VirtualHost *:80> ServerName example.com DocumentRoot /var/www/html/...
0 votes
1 answer
35 views

Configuring Virtual Hosting Httpd - Fedora Server - 'sites-available and sites-enabled' vs 'conf.d/vhost.conf'

The current set-up for my web server is a 1GB nanode using Fedora37 as the distribution for the compute instance. For the web server I am using Httpd (Apache 2.4.54), and am now in the process of ...
0 votes
2 answers
51 views

ProxyPass not working alongside ProxyPassMatch

So at the moment I have a virtual host configured on my Oracle HTTP Server instance with a ProxyPass as such: ProxyPass ^/test/home/ https://example.com/ ProxyPassMatch ^/test/home/(.*)$ https://...
  • 35
0 votes
1 answer
54 views

How do I add a second virtual host to an Apache server config?

I have an Apache server running on an AWS EC2 instance. Currently, one virtual host is running successfully on the server, and I want to add a second virtual host / domain, but I can't figure out how ...
0 votes
0 answers
14 views

HTTPS Redirect Not Allowing Access On Port 443 (Apache2, letsencrypt)

ERR_CONNECTION_TIMED_OUT ...is what I'm getting trying to access my domain wget (website), VH config, netstat, ufw status The issue lies somewhere between sending the request to apache through 443 and ...
  • 1
0 votes
1 answer
72 views

How to install memcashed on a LAMP stack with PHP FPM?

I have a LAMP stack with PHP FPM and multiple virtual hosts with Wordpress sites on. I have tried to install memcashed using this tutorial. In Wordpress sitehealth I get: "You should use a ...
0 votes
0 answers
332 views

Cloudflare Tunnel without having to also use noTLSVerify?

I’ve got a simple domain setup on an Ubuntu server running Apache (literally just displays a static HTML file); I set it up with LetsEncrypt and it was working without issue. I wanted a bit more ...
0 votes
0 answers
20 views

How do you set up multiple virtualhosts on apache2 using only the server ip and server alias?

I'm trying to set up apache with multiple virtual hosts "filebrowser.com" and "videos.com" however, I'm only able to access filebrowser.com and not videos.com. I also have to enter ...
0 votes
1 answer
24 views

Having Trouble setting up 2 Virtual Hosts with SSL

Im trying to setup a second webserver on my machine however im running into problems with the virtual hosts and im not sure which file and what i should be changing. I have 1 server running with SSL ...
0 votes
0 answers
29 views

(Solved) Apache 2.4 multiple subdomain with fallback folder

I want to have a default folder when the folder does not exist in the VirtualDocumentRoot, I have this code: <VirtualHost *:80> ServerAlias *.development UseCanonicalName Off ...
1 vote
1 answer
28 views

How to create alias to url in Apache 2

I have main url like http://apps1.example.com and i want create alias like http://apps1.example.com/svc-base in my vhost config <VirtualHost *:80> ServerName apps1.example.com ...
  • 11
0 votes
1 answer
38 views

apache virtualhost not taked into account

I have multiple domains and i have imagined that one VirtualHost for each would be the way to go. glpi.localnet.lan is never loaded, whereas web.localnet.lan is always display instead, even if i tip &...
  • 2,211
0 votes
0 answers
28 views

How do I properly remove a staging subdomain that's no longer needed?

I have a WordPress Multisite configuration on an Apache/2.4.46 (Ubuntu) server. I make staging sites using a subdomain of the main domain, then when that staging site is ready to be 'live' and uses ...
  • 101
0 votes
0 answers
56 views

404 errors with Virtual Host in VPS Server

I'm trying to create a virtual host in my vps server but I'm receiving "HTTP Status 404 - Not found". My Virtual Host: vi /etc/httpd/conf.d/demonstracao.itcmedbr.com.conf <VirtualHost *:...
0 votes
0 answers
20 views

Apache vhost doesn't work

What is wrong with this? The .conf file is added via puppet in /etc/apcahe2/sites-enabled but it doesn't get enabled and i cannot open the link abc.xyz-software.com/apis/1 ....it throws 404 error. <...
  • 21
0 votes
0 answers
24 views

Apache HTTP/2 Issues on Virtual Hosts

I have third-party domains pointed to my IP address using A records, and these are configured on the server using a Virtual Host configuration. Here's an example: Protocols h2 h2c http/1.1 <...
  • 101
0 votes
0 answers
25 views

create a virtual host with name

I have to create api.conf in /etc/apache2/sites-available dir in a server(xyz02.software.com). The apache config is managed via apache module(apache::vhost) in role::script..so basically it is ///...
  • 21
0 votes
1 answer
108 views

Apache virtual host not catching all requests

I have 80 port requests redirected to 443 like this <VirtualHost *:80> ServerName example.com ServerAlias www.example.com mail.example.com Redirect permanent / https://example.com/ &...
  • 115
-1 votes
1 answer
410 views

Match VirtualHost by X-Forwarded-Host header

I am using apache 2.4 and would like to create multiple vhosts. The vhosts should be matched based on the X-Forwarded-Host header, instead of the Host header. Unfortunatly I could not find anything in ...
  • 101
0 votes
0 answers
119 views

Apache2 Virtual Host. http to https. Too many redirects

I've created a new virtual host in Apache 2.4.29. I want to redirect http traffic to https. Accessing the url gives an error www.example.com redirected you too many times. If I comment out the ...
  • 11
1 vote
1 answer
63 views

Nmap - Print names from virtual hosts

I'm trying to identify virtual hosts with Nmap, command: nmap --script http-vhosts -p80 {ip} Nmap identifies a number of hosts. But how do I get the actual host names that are found? Now nmap only ...
  • 11
0 votes
0 answers
146 views

Deploy VueJS and CodeIgniter applications under same virtualhost/hostname

I've a Windows Server VM in LAN named "testingserver" I've installed Xampp (Apache, PHP) to serve both, a VueJS 2 and CodeIgniter 4 apps Folder structure d - ciapp (CodeIgniter) d - dist d - ...
0 votes
1 answer
22 views

How to create a local host that can be accessed through everyone on the same internet?

I've had an Apache Virtual Host working for a couple of month where workers on the office wifi could type in something like www.XYZ123.com and was able to access the website through their browser. Now,...
0 votes
1 answer
178 views

Can't load Web API with SSL (ERR_SSL_PROTOCOL_ERROR)

So I can't get my head around this problem, and looked everywhere on the internet but did not found any working solution. 1.1. I have an apache server running as virtual host. In the initial situation,...
  • 1
1 vote
1 answer
101 views

Postfix wildcard, virtual_alias, and recipient_delimiter forwarding glitch

Using Postfix with an MySQL backend, have a group of aliases set up, including domain aliases. Using '.' as recipient_delimiter, and have propagate_unmatched_extensions = canonical, virtual, alias. ...
-1 votes
0 answers
381 views

Setting up a virtual host in a different directory in XAMPP

I’m trying to do something which I had got working in the past, so I wonder whether things have changed. I am running XAMPP (not the VM) on my Mac. I want to set up a virtual host, using a directory ...
  • 113
0 votes
1 answer
246 views

Apache virtual host serving incorrect index.html file for one of two domains connected to server

I have two domains setup on a single server using Apache Virtual Hosts. The first domain (domainA.com) is loading the index.html file of the second domain (domainB.com), even though the first domain (...
0 votes
0 answers
46 views

Allowing file types in specific folder apache2 vhost file

I've an apache2 virtual host file, which has several sites in it (yes I know.. a single file, work with me here). Before any of the VirtualHost stuff I've specified some directory and file rules like ...
0 votes
0 answers
20 views

Apache2 htaccess issues when using vhost_alias

I have the vhost_alias module set up and loaded, and have the following in a host file inside sites-enabled UseCanonicalName Off <VirtualHost *:80> ServerName vhosts.local ...
1 vote
1 answer
29 views

Advice on a catch all for https incoming but no cert installed

I am trying to think of an elegant way to handle an SSL / HTTPS issue we are having. I have read THIS QUESTION but it raises a slightly larger question in my case. Say I have these domains installed ...
  • 345
0 votes
0 answers
710 views

nginx - server doesn't show requested site

So I installed nginx on a local Linux Virtual Machine (Ubuntu Server, if it matters) though apt, and created a slightly modified config file for my website following the default site's template: ...
0 votes
0 answers
43 views

TOMCAT - direct TomCat requests to ISS

is there any way to redirect a required url from TomCat to IIS? I have the following scenario: there is a service running on TomCat, which in turn is configured on port 80 and 443 and another service ...
0 votes
1 answer
234 views

Blocking Port 8080 from direct IP access but allow access via domain (Virtualhost Config)

I want to access web server from http://subdomain2.domain.com from URL but not from direct IP (http://1.1.1.1:8080). For instance, below is my virtualhost config file (site2.conf) in /etc/apache2/...
0 votes
0 answers
25 views

Apache 2.4 : Redirect a subdomain to a new domain except one url the / (index.html)

I just changed the domain name, and i would redirect the following links : All old urls from subdomain.example.com/url.html --> subdomain.newdomain.com/url.html Except one url (the /) (implies ...
0 votes
2 answers
94 views

If i find port X open on an ip address, is it safe for me to assume that i will find a web server at domian:X where domain resolves to the ip

Lets say www.example.com resolved to 36.45.6.x, and i port scanned that ip and ports 80,443,8080 came up and nmap tells me they all have http web servers running on them, is it safe for me to assume ...
0 votes
1 answer
334 views

Request exceeded the limit of 10internal redirects on cPanel Server

I just created a subdomain called virtual from cPanel and its return 500 error. When I check the error_log I see below error: AH00124: Request exceeded the limit of 10internal redirects due to ...

1
2 3 4 5
55