Questions tagged [vhost]

19 questions
4
votes
1 answer

Multiple Websites - PHP Session Isolation

I have a LAMP stack on a VPS where I set up multiple virtual hosts for different (sub)domains: example.com www.example.com dev.example.com Now, I would like to make sure that PHP session data is isolated, i.e. not shared between these websites.…
Tando
  • 41
  • 4
4
votes
1 answer

Redirect requests on alternate port for Apache virtual host

I have Apache server where I make my LoadBalancer for my application sereres through proxy and balancermember. Some of my clients come from legacy access, they use a port in the URL example.com:2030 as informed by the old team. So vhost is that…
3
votes
1 answer

Vhost sends www.* to another domain

I created a virtual host at my server to host multiple sites, but I got a few unexpected problems. One sites doesn't gets recognized by the server and is redirected to another domain on the server, another one just works without 'www' but the one…
Tim
  • 31
  • 1
3
votes
1 answer

Phantom vhost forwarding from example.com to example.net

I'm running apache2 on Ubuntu 16.04 LTS, and Let's Encrypt Certbot for SSL certificates. I have two domains. Regardless of http or https, www or non-www, I want them to land at https://example.com and https://example.net respectively. I have 4 .conf…
iverSUN
  • 31
  • 3
2
votes
1 answer

Enabling 000-default.conf breaks namebased vhost

I have two sites on a server: dev.example.com and example.com - the latter has a ServerAlias of *.example.com. All domains are SSL-enabled, and all requests to port 80 is redirected to HTTPS. The example.com site is a proxy of an old site, on a…
Vonsild
  • 121
  • 3
2
votes
1 answer

haproxy + Apache + virtual hosts -> wrong host is displayed

On CentOS 7.2.1511 Linux I have installed haproxy-1.5.14-3.el7.x86_64 and httpd-2.4.6-40.el7.centos.1.x86_64 packages. The /etc/haproxy/haproxy.cfg binds HAProxy to ports 80 and 443 and accepts HTTPS to slova.de: defaults mode …
2
votes
1 answer

Subdomain showing incorrect content when going through HTTPS

I have a domain on my server called example.com and I set up a subdomain called links.example.com. Whenever I go to links.example.com, the domain is pointing to the same directory, even though in the cPanel settings, I told it to go to…
Josh Holly
  • 51
  • 3
2
votes
1 answer

Pagespeed Virtual Host Configuration

I installed pagespeed on CentOS 7 with plesk (apache 2.4). I have 2 vhosts with different SSL certificates on the server. Pagespeed is running server-wide. Filters such as collapse_whitespace and remove_comments work fine. But css and javascript…
KenAdamsTR
  • 21
  • 2
2
votes
1 answer

Subdomain folder content returns 404, but root level works

I am setting up a subdomain - subdomain.example.com for my existing example.com to serve application with distinct origin Using DNS manager of my registrar, DNS Manager: type CNAME, name: subdomain, points to @ And in my Apache 2.4 sites-available I…
Yasser
  • 23
  • 3
2
votes
1 answer

301 redirect for "/usage" page while webalizer is installed

I moved my site to another hoster and this hoster is using webalizer. My site has a page called /usage. While testing I found out the page https://example.com/usage/ generates the 403 Forbidden error due to this webalizer.conf: # # This…
Peter VARGA
  • 143
  • 1
  • 1
  • 7
2
votes
2 answers

Apache: sd.example.com and sd.example.com/sd both work - how to disable?

I've got a vhost set up for sd.example.com. DocumentRoot is htdocs/sd. Browsing to sd.example.com works as expected. But if I browse to sd.example.com/sd, I get the same result. Is this expected behavior, and if so, how to disable it? I would have…
kraligor
  • 121
  • 2
2
votes
1 answer

Vhosts on Apache Web Server. All in one or in separate .confs

I am trying to have multiple websites hosted on one server, but do not know for sure if I should create the Virtual Hosts for each website contained in one file or have each of them in their own separate files. All help is appreciated.
Andrew
  • 61
  • 3
1
vote
1 answer

Apache Vhosts - subdomaining

I am a little new to the apache vhosts configuration and for educational purposes I wish to set up a domain and a subdomain. The domain is already set up under the name example.com. Now I want to create a subdomain test.example.com. Consider the…
Limnic
  • 113
  • 4
1
vote
1 answer

Configure files to come from a central location unless that file has been customized for a specific site

I have an user A on a server, this users has a working set of scripts (html+js+css+everything else). I also have users B-[as much as I want]. I want those to use the exact same files, but if they have the file themselves, use that. Like a multi-user…
Martijn
  • 6,806
  • 19
  • 36
1
vote
2 answers

SEO efficient 301 redirects (non-https to https, non-www to www) in 1 hop

Performing an audit of my site revealed multiple 301 redirects to achieve a HTTPS, www. variant, with a trailing slash of all directories. Ideally I'd like to make only one 301 redirect from any url variation, to https://www.example.com/page/ A lot…
1
2