LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-28-2020, 09:59 AM   #1
dr-ing
LQ Newbie
 
Registered: Mar 2020
Posts: 19

Rep: Reputation: Disabled
Reverse proxy (sub)domains to a different local server wihtout interrupting https


Hey,

I will try my best to describe my case:
I have 2 almost similar local servers (e.g. 10.0.0.1 and 10.0.0.2, both behind a pfsense firewall) and currently all web traffic (http and https) is directed to the 10.0.0.1 server running Apache2 with multiple vhosts.

These vhosts can be accessed either through a subdomain (e.g. alpha.myserver.net) or through a domain (e.g. beta.net), depending on the customer.

Now I want to move some vhosts (i.e. a few domains and subdomains) to the second server while the domains are still accessible with the same public IP, so I probably need a reverse proxy.

My question now is, is it possible to set up a reverse proxy that acts like a switch and checks the domain name and then decides if it belongs to the 10.0.0.1 or the 10.0.0.2 server without interrupting https?

Last edited by dr-ing; 05-28-2020 at 10:12 AM.
 
Old 05-28-2020, 10:16 AM   #2
shruggy
Senior Member
 
Registered: Mar 2020
Posts: 3,677

Rep: Reputation: Disabled
I guess a combination of RewriteCond and RewriteRule with a [P] flag can do it. Canonical Hostnames describes redirecting, but reverse proxy should be similar.

Last edited by shruggy; 05-28-2020 at 10:17 AM.
 
  


Reply

Tags
apache, linux, proxy, reverse proxy, webserver



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Nginx Reverse proxy on a internal apache reverse server ITiger Linux - Software 0 04-25-2014 07:44 AM
Shell Script to compare folders,Sub-Folders and Sub-Sub-Folders unix_72427 Programming 8 08-08-2012 02:51 PM
Squid reverse proxy + SSL or hosting multiple domains from one IP friskydrifter Linux - Networking 8 11-19-2009 12:00 AM
Multiple emails accounts(with different from domains) on multiple domains on 1 server locoputo Linux - Server 0 04-12-2009 06:29 PM
Sub Domains & Multiple Domains (Apache) lugos Linux - Server 1 09-01-2006 10:22 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 06:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration