Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm very new to this but I am wondering if this is possible and if so how.

I have a website http://mysite/ which currently hosts some content. I want to host another website on a separate server but I want the URL to be:

http://mysite/mysecuresubsite

Furthermore, I want to protect the subsite server with SSL.

So, is this possible? What do I need to do to achieve this?

(using IIS, by the way)

share|improve this question
add comment

4 Answers

You can set up the first server to proxy requests through to your second server. So anything to http://mysite/mysecuresubsite will proxy through to http://secondserver/ and anything else gets served locally. You might have some problems with absolute links on the second server, so you might find it easier if both servers served the same path. IE, http://mysite/mysecuresubsite proxies to http://secondserver/mysecuresubsite.

As for the SSL part of your question, once you have the proxying set up, you should be able to redirect anything going to http://mysite/mysecuresubsite to https://mysite/mysecuresubsite. This does mean that the SSL endpoint will be on your first server, rather than on the second server. This is only really a problem if you second server is relying on client certificates for authentication, which is rarely the case.

I don't know if IIS is capable of these features, but I believe that ISA should be capable if IIS can't. If all else fails you could use something like Apache, which can do this, in front of both and proxy appropriately.

share|improve this answer
add comment

you need to use Apache's reversing ability. Through what we call "reverse proxying" Basically, Apache reads the called URI and thanks to the module will redirect a portion of the website to another server. I'll let you write this introduction : http://www.apachetutor.org/admin/reverseproxies then you could ask more informations

share|improve this answer
add comment

I will assume you're using linux. You can achieve this a few ways:

Navigate to your document root (if apache, httpdocs is default)

(It may be /var/www/html/httpdocs/ or /var/www/vhosts/mysite/httpdocs/ or similar)

For a permanent redirect edit your .htaccess file like so:

Redirect 301 /mysecuresubsite http://mysecuresubsite/

If you are not using linux/apache, there are a slew of pages on the subject:

How to Redirect a Web Page

How to Redirect a Web Page Using a 301 Redirect

How to do 301 redirects in Apache .htaccess, IIS, PHP, ASP and ColdFusion

Edit:

If you would like the url to read http://mysite/mysecuresubsite while actually on the foreign secure server, you can mask the url using an iframe. There is a good example here.

share|improve this answer
    
using IIS but good info –  John Nolan Aug 18 '09 at 11:50
add comment

You cannot have one domain pointing to two separate hosts at the same time. So the answer in NO.

share|improve this answer
    
This is more than possible to do using proxying. –  David Pashley Aug 18 '09 at 11:59
    
So you are able to do it with IIS on shared hosting that John Nolan is apparently using? –  Taras Chuhay Aug 19 '09 at 9:07
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.