IIS site setup with a different port - iis

We are having a situation where we have to create use the site with different ports
1) 80 goes to site -xyz
2) 1443 goes to some other site - abc.zyx which uses same root folder.
SO we have added 1443 to iis server bindings along with a new private ip. This site as of now uses same root folder as the root site with port as 80.
Now the privateip:port is not coming up. Need to view the same site with port 1443.
Kindly help
Thanks
Vivek

Im not exactly sure what you are asking but you can create two separate sites in IIS to look at the same root folder as long as they have different host names.
The same can be said about ports. You can add multiple ports in the sites bindings as long as they are actually different ports.
Just make sure all ports are open on the firewalls. You should be OK.

Related

New IIS 10 site on different port can only be accessible on VM directly via http://localhost:portnumber

I am managing a Windows Server 2016 Azure VM in the cloud that has IIS version 10 installed.
It currently has 2 sites that is live
Namely
http://www.clientdomain.com
http://portal.clientdomain.com
Both these sites work.
I need to setup a test site just for testing purposes.
I create 2 test sites in IIS and setup the bindings with hostname portal.clientdomain.com on port 88 and port 89 respectively in the IIS bindings.
I use a different port than 80,443 so it doesn't interfere with the live site
This works if I type in my browser
http://localhost:88 or https://localhost:89 on the VM directly
However, it needs to be accessible outside the VM on the internet.
For one or other reason I can't get the site url to open up in the browser.
Some of the URLs I have tried:
http://portal.clientdomain.com
http://sitename.westus.cloudapp.azure.com:88
http://TheIPAdress:88
http://clientdomain.com:88
which all the following cause the browser to gives the error This site cannot be reached with details The server took too long to respond
I tried various bindings too but nothing works.
My question:
Why does http://localhost:88,https://localhost:89,http://portal.clientdomain.com work directly on the server, however http://portal.clientdomain.com:88 or http://portal.clientdomain.com:89 do not if I made the bindings match. I also tried it with no bindings. Nothing works.
I have tried adding the ports to the Firewall as Inbound TCP rules but result is the same.

Mapping Domain Name to Tomcat application

I am having stand alone Linux Centos server with Static IP. I am running two tomcat application http://IP:8080/sampleapp, http://IP:8090/myapp. i can access that both application from internet.
i bought domain from ipage.com. now i wanted to map http://sampleapp.com to http://IP:8080/sampleapp and http://myapp.com to http://IP:8090/myapp.
I don't want to add another apache layer to forward port.
How can i map..? please help me
You can give a redirection in your ipage.com DNS setting which redirects your domain to your static IP.
But I would like to suggest you can run on port 80 to just make your link prettier.
Your requirement is not very clear. However you can deploy both apps to the same port, like 80, and then use Tomcat virtual host to achieve what you need: https://tomcat.apache.org/tomcat-7.0-doc/virtual-hosting-howto.html

Binding Port Number 80 for Subdomain in IIS7.5

We have Windows 2008R2 dedicated server which is pointing a domain. Let us say domain name "TestDomain" under that as given in Image "Default Web Sites" having many application those can be acessed by www.TestDomain.com/appA,www.TestDomain.com/appB,etc. Now I need to create submain something like "www.franchise.TestDomain.com". I could configure the same as given in image but I have configured subdomain with Port Number 80. Will it be a problem if we have "Default Web Site" and "Franchise" running on same port number?
You can run all the sites you want under the same port, as long as the hostname (in your case testdomain.com and franchise.testdomain.com) varies.
So the answer is yes, you can do that without any problems.

MVC4 Website/Web Application Recommended IIS Directory Structure

I have an MVC4 web application
In setting it up on IIS7.5 I added the application to the "Default Website" and set up a virtual directory under http://localhost/myApplication
However, this forced me to change many of my controller calls (specifically js ajax calls) which I previously called in Cassini like "/Home/Index", I now had to change them to "/myApplication/Home/Index" for them to work on my local IIS.
NOW, when I publish it to a remote hosting server I have to change it BACK to "/Home/Index" for it to work.
This cannot be the most productive way to traverse the development -> testing -> production cycle.. What step am I missing?
I tried to create the applications virtual directory on on just http://localhost/ without appending the application name so that I can call "/Home/Index" at all three stages but it complains that http://localhost/ is already mapped to inetpub/wwwroot.
Thanks for your time.
The steps are like this:
Publish your website to a new folder in inetpub/wwwroot (or the place where your applications are kept) like "inetpub/wwwroot/myapp"
Go to IIS management, create a new web-site, assign it any free port (like 11001 or something, > 1024 at least) and point it to a folder from the step 1. Bind it to all IP addresses available or to 127.0.0.1
Start the web-site.
Access it using http://localhost:11001/ (or any other port you've set)
Problem is that by default any browser uses port 80 to request a web page, and that port is taken by the default web-site. You have to manually override it or create a site on another port. IIS usually warns you about port collisions.
If you don't want to have port number in the address, alternatively you can work with host header on port 80. You may have to make local host entry for the host header given to the site.

How to configure Application Request Routing in IIS 7.0 for 2 applications running locally on different ports?

I've got 2 applications running on my local machine. One sharepoint and another IIS application:
localhost:43442
localhost:5080
I've installed ARR and need to configure it to run these 2 apps on a host and port but when adding a new server, it only accepts a server name rather than its port as well.
Any help?
For me, I needed to add a server to my server farm, called localhost. Clicking Advanced Settings... lets you specify the http and https ports. Set those to the ports that you would like your domain proxied to.
After that, create an inbound rule for URL Rewrite that matches the HTTP_HOST condition with a pattern of your website domain that the server is acting as a proxy for. Select Route to Server Farm for the action and select the specified server farm.
I added a new Inbound Rule and it worked :)

Resources