Questions tagged [serveralias]

43 questions
54
votes
1 answer

Server Aliases on NGINX

I'm moving a site to a new server running on NGINX. The old site's Apache2 VirtualHost has ServerAlias configured that I want to replicate in the NGINX configuration. From what I've read on the NGINX Docs this seems to be simply achieved with…
Holly
  • 907
  • 5
  • 13
  • 24
12
votes
1 answer

Exclude specific domains from Apache2 serverAlias while using a catch all *(wildcard) alias

I have a web application that needs to support custom domains, in that regard I have set-up the following name based virtual server: ServerName example.com ServerAlias * *.example.com www.example.com example.com …
Victor S
  • 243
  • 2
  • 7
12
votes
2 answers

Apache2 multiple hostnames redirected to one

I'm trying to redirect multiple hostnames to only one, for example, if you enter any of: foo.example.com www.example.com bar.example.com eample.com you must be redirected to www.example.com I have installed a virtual host with www.example.com as…
alcuadrado
  • 223
  • 1
  • 3
  • 6
7
votes
1 answer

Server Alias With wildcard subdomain

I am using WordPress network subdomain setup. I had to put *.mydomain.com as a server alias but now I also have a site subdomain.mydomain.com that leads to another directory. Is there a way of doing this since when I type subdomain.mydomain.com it…
6
votes
1 answer

Apache ServerAlias wildcard for domains (e.g. subdomain.*.com)

I know it's possible to use wildcards for subdomain aliases like: ServerAlias *.domain.com But is it possible to use that for domains having a the same subdomain? # like this ServerAlias subdomain.*.com
Yes Barry
  • 170
  • 1
  • 16
6
votes
3 answers

Apache Virtual Host Config www vs non-www, Rewrite or sServerAlias?

We have a central httpd.conf and we include confs for various virtual hosts. Until today, we didn't really have a need for "www.subdomain.site.com" domains, only "subdomain.site.com." Now we do, so I am trying to figure out which of these two…
KM.
  • 1,746
  • 2
  • 18
  • 31
5
votes
1 answer

apache2 and VirtualHost with foreign characters and more than one Alias

I have a simple apache2 setup with two VirtualHosts. One is a domain name with "normal" characters, and one has foreign characters (with punycode). The problem is that I don't know how to add "www" as an alias with the punycode domain. With the…
Frank H.
  • 221
  • 1
  • 10
5
votes
3 answers

Set Apache Alias for specific ServerAlias

Currently, I have a VirtualHost defined like so: ServerName mydomain.com ServerAlias otherdomain.com DocumentRoot /var/www/project/ How can I make an Alias that only affects the otherdomain.com…
Tatu Ulmanen
  • 161
  • 1
  • 7
3
votes
1 answer

How to make computer alias discoverable?

I am replacing an old server 2008r2 system with a new windows 2016 server but am having problems with computer visibility on the local network. My file server has a DNS alias which doesn't appear as a computer in windows explorer - except on the…
2
votes
4 answers

Managing lots of Apache vhost ServerAliases

So I've got this site that's being served as a virtual host by Apache 2. And it has a metric ton of alternative domain names that are all supposed to resolve to it. Up to now I've handled things like this by adding the extra domains in the…
jalefkowit
  • 123
  • 1
  • 4
2
votes
1 answer

Passenger and ServerAlias not cooperating

I have a ruby application that runs on a server with multiple IP addresses and mutliple vhosts. Here is the configuration of the problematic virtual host: ServerName realname.example.com ServerAlias alias.example.com …
Pyzo
  • 135
  • 1
  • 1
  • 7
2
votes
3 answers

ServerAlias not working

I have a VPS, that I have configured to host multiple websites with name based hosting. It is all good while only using example.com, and www.example.com. It also works with example.net, but when I try example.net, it reverts to my default site…
Janis Peisenieks
  • 239
  • 1
  • 5
  • 11
1
vote
1 answer

Anyway to avoid putting in seperate www for ServerAlias in Apache

I have a server with about 2000 domains on it pointing to same folder. I put an include file with the domain list into a virtual host entry. Do I need to make a second include file for www.sales.com wwww.sales2.com etc.. or is there a better way…
Lid
  • 15
  • 5
1
vote
1 answer

Redirect root & all subdomains to another domain equivalent (DNS only)

First, yeah, I know, this question is probably a duplicate, but I've searched for some hours now and I can't find any relevant answer.... So I try asking. I got, let's say, domain-a.com & domain-b.com. domain-a is just an alias of domain-b.com, and…
1
vote
1 answer

Apache ignoring Server Alias and going to first virtual host

I'm having problems getting my ServerAlias domains to work correctly. apache2ctl -S gives: IP.ADDRESS:80 is a NameVirtualHost default server byteinsight.net (/etc/apache2/sites-enabled/000-default.conf:1) port 80 namevhost byteinsight.net…
Byte Insight
  • 123
  • 7
1
2 3