Reputation: 13
I'm developing an enterprise application and deployed it on a Websphere Application Server 8. I can use the web application if I put the port of the web container in the url, but it doesn't work without the port number. I.e.
http://<server_url>:<port>/<contextroot>/<entry/point/path>
works, while
http://<server_url>/<contextroot>/<entry/point/path>
does not. I quess the sysadmin needs to configure something on the server in order to redirect the second url to the correct port, but we don't know how to do that. There is an alias already configured for the default virtual host
host name: *
port: <port>
We also have simple web applications (single wars in ears) installed on the server, and those work withouth specifying the port in the url
Thanks
EDIT: more info (adapted from a comment), since I had time to look after this issue again : We have a WAS installed on our production server, but I also have one installed locally that I use for development, with the same configuration. I'd like to make this work on my local machine first. I have two virtual hosts defined: one admin host and a default host. The default host has aliases on ports 9080, 80, 9443, 5060, 5061 and 443. I access my application as localhost:9080/. All I want is to avoid stating the :9080 in the URL?
EDIT2: If i change WC_defaulthost to port 80 i can access the application without stating the port in the address, but AFAICT it's a bad practice. Can I somehow transparentrly forward/redirect requests to the right port?
EDIT3: I created a transport chain WCInboundAdditional listening on port 80 (along WCInboundDefault listening on port 9080), and it seems to work on my locally installed server (i.e. I can access my application through http://localhost/). Is this a good practice?
Upvotes: 0
Views: 1209
Reputation: 17896
In order of likelyhood:
1) You're running a HTTP server or Proxy server on the canonical ports (80,443) but either your application is not mapped to that frontend server (this happens at the web module level) or in the case of a webserver w/ the WAS Plugin, the plugin-cfg.xml has not been regenerated since this module was added (or since it was mapped to the webserver).
For the WAS Plugin inside a webserver (such as IHS, IIS, etc) the plugin-cfg.xml is referenced in the webserver configuration. If you view it, you will see your URL patterns being forwarded to WAS.
2) You may have multiple virtual hosts defined at the WAS layer, only one of which that uses the canonical ports, and the applications that don't work aren't mapped to that virtual host.
This also happens at he web module config level.
Upvotes: 1