Questions tagged [virtual-host]

30 questions
5
votes
1 answer

Apache redirect to https if the request is not from localhost

I have a Centos 6.7 with apache 2.2.15. I want to redirect all traffic from port 80 to 443 with one exception. The traffic who come from localhost I want to remain on port 80. Now I use this config but I don't know how to change it RewriteEngine…
antiks
  • 409
  • 2
  • 7
  • 12
3
votes
1 answer

Port 81 for http is redirecting to 80

I have created port 80 and 81 for my Apache. Below is the configuration. Listen 80 Listen 81 DocumentRoot "/var/www/html/wp" ServerName www.test.tk DocumentRoot "/var/www/html/pw" …
superman
  • 79
  • 2
  • 6
3
votes
0 answers

Use apache virtual host to redirect a subdomain to internal ip preserving passed port

I've been looking for a while to the answer to this question and I seem to find slightly different needs from people asking questions and they get wildly different answers... but none of them seem to fit my problem. I have a server that uses…
TonyMorello
  • 351
  • 1
  • 7
3
votes
1 answer

How to setup virtual hosts to point to two diffrent directories

I have one domain and a sub domain which are supposed to point to two different folder, i have tried this help but still i have issues.…
3
votes
2 answers

configuring httpd for multiple domains on same server

A CentOS 7 web server is hosting one public domain, called mydomain.com. The same server also has a separate vpn that hosts two apps for private authorized/authenticated users only. Httpd is set up in a reverse proxy relationship in front of…
CodeMed
  • 5,079
  • 45
  • 100
  • 147
3
votes
1 answer

postfix virtual domain on specific IP address

We are running postfix with single domain (example.com) currently and we have appropriate PTR record for that. Now we want to add one more domain but i want to isolate that domain totally, Even i want to isolate PTR record too. so we added new…
Satish
  • 1,632
  • 3
  • 34
  • 60
2
votes
1 answer

Can I install a Let'sEncrypt ssl certificate before I configure a virtual host?

Assuming I am not close on which web server to use, Apache or Nginx but I still want to be over with the SSL certification procedure, can I install a Let'sEncrypt ssl certificate before I configure a virtual host?
automation
  • 57
  • 4
2
votes
1 answer

How to Stop a specific virtualhost in apache2

let's say I want to stop only the example2 VirtualHost. How do I do it? sudo service apache2 stop will stop all the VirtualHosts. I want example1 to keep running ServerName www.example1.com ServerAdmin…
2
votes
0 answers

H2O Webserver - Multiple domains - Is possible ? Or current version is only for one domain?

I'm testing h2o server : (some urls ) https://github.com/h2o/h2o/wiki https://calomel.org/h2o.html All works fine with only one domain but when I try to load multiple domains I can't load different paths for these domains: This is a simple…
2
votes
1 answer

Nginx virtual hosts for multiple LXC containers

I am having the following configuration: I have 5 LXC containers that are running nginx. On each container there are a couple of virtual hosts set up in nginx. That means for a container I have multiple virtual hosts that are available through port…
roshkattu
  • 23
  • 1
  • 3
2
votes
4 answers

Apache2 not reading sites-enabled/*.conf

So I'm trying to set up my site with Apache on Ubuntu 14.04. I have created a mydomain.com.conf file in sites-available/. It looks like this; mydomain.com.conf ServerName mydomain.com ServerAlias www.mydomain.com …
William Boman
  • 131
  • 1
  • 2
  • 5
1
vote
2 answers

Could not reliably determine the server's fully qualified domain name

I was following this tutorial to setup two virtual hosts in Centos 7. The issue is i am getting the following error while restarting the httpd. [userme@server ~]$ sudo systemctl restart httpd.service [sudo] password for userme: Job for…
ran
  • 121
  • 1
  • 1
  • 7
1
vote
2 answers

Is there some security restriction preventing apache2 from listening on a high port?

I have configured an Apache2 virtual host to listen on a port above port 80, 8011 in this case. apachectl configtest returns no error in regards on the usage of the high port, yet netstat indicates the port is not in use and telneting to the IP…
vfclists
  • 7,215
  • 14
  • 51
  • 79
1
vote
3 answers

Multiple virtual host in Centos 7 is not working together

My server information is Server version: Apache/2.4.6 (CentOS) Server built: Nov 19 2015 21:43:13 I am trying to configure virtual host for 2 different sites: biz.example.com and pin.example.com which are hosted on the same server. There are 2…
1
vote
1 answer

Nginx redirects all domains to one website

I'm trying to setup a server with Nginx and PHP FPM and I ran into some trouble. I've set up an Nginx virtual host and a fpm pool for each website. The problem is that all domains are showing the same website, even though it's not the default…
Alex
  • 101
  • 7
1
2