I'm running a JBoss EAP 6 instance that has 5 applications running inside. Each one needs it's own socket bindings, web connector and thread pool.
I've defined 5 web connectors that bind to each socket binding group (one for each app) as well as their corresponding thread pools. But I'm not sure how to get a distinct url / address for each app.
Here's what I'd like:
http://myapp1.servername -> app1
http://myapp2.servername -> app2
And so on..
I've scraped the web and found bits and pieces of how to do this, including virtual hosts. But I can't find anything coherent that helps me tie and app to it's corresponding connector and expose it via a separate url.
Can anyone help?
To configure virtual host add below tag in 'web' subsystem:
<virtual-server name="virtualserver1" enable-welcome-root="false" default-web-module="app1">
<alias name="app1.com"/>
</virtual-server>
Add below tag in war/WEB-INF/jboss-web.xml file:
<jboss-web>
<context-root>/application</context-root>
<virtual-host>virtualserver1</virtual-host>
</jboss-web>
Related
I need to have an ability make several applications listen on different ports, but in the certain situation some of these applications must listen on the same port. I can change all configs, but I can't reassemble WAR files.
I've read this article "Application deployment" but still perplexed. Can it be done on standalone server? If it is possible, what configs should I make?
UPD
May be I sould change the question. Is there any way to set up a specific virtual server for an application by a deployment descriptor?
To create create a different http listeners on the same wildfy instance, you will need to adjust your configuration file by adding the new http-listener.
Add, just below <http-listener name="default" socket-binding="http" redirect-socket="https" enable-http2="true"/>, in the undertow subsystem your new listener <http-listener name="customerPort" socket-binding="customerPort"/>
Then in your socket-binding-group (usually at the end of the configuration file), add the socket binding referencing customerPort above <socket-binding name="customerPort" port="2323"/>
Hope this help solve your problem.
By default, applications in wildfly are deployed to localhost:8080/app. How to deploy application on dedicated port, i.e. open it on localhost:8282 without application name ending?
I need to change the port for certain application, not the default port.
I have not tried this, but AFAICT it should be possible to:
run a single Wildfly instance listening on multiple HTTP ports. This is, in theory at least, possible (ref: https://developer.jboss.org/thread/233414?start=0&tstart=0)
Configure undertow subsystem as a reverse proxy, and proxy your app to the other port/location (ref: http://www.mastertheboss.com/jboss-server/wildfly-8/configuring-a-reverse-proxy-with-undertow). That said, I have never used undertow for a reverse proxy and as such cannot speak for whether this really works.
Once you have done this, you have effectively just turned your Wildfly instance into an overly complex application server and reverse proxy in one. Ultimately however, the app in question would still be running on both ports, but you redirect the traffic using the proxy the way you would like.
The same proxy configuration in an Apache (ref: https://httpd.apache.org/docs/current/mod/mod_proxy.html#forwardreverse or https://www.leaseweb.com/labs/2014/12/tutorial-apache-2-4-transparent-reverse-proxy/) or NGINX (ref: https://www.nginx.com/resources/admin-guide/reverse-proxy/) would be IMHO less complex and better tested in countless production scenarios.
With Angel.SR3, assigning server.port: 0 would assign a random port to embedded Tomcat instance and use that port when registering with Eureka (using random instance ID as well in order to run more than one instance of a service on my dev machine).
I want to use the new Spring Cloud Sleuth for automatic tracing so first I just tried using spring-cloud-starter-sleuth at 1.0.0.M1 but trace and span didn't show up in log files when using the logging pattern in the example app. I thought it might be related to the versions of the other libraries that I was picking up with Angel.SR3 so I tried experimenting with Brixton.M1. With Brixton.M1, trace and span are now being set correctly but my service no longer registers its random port with Eureka - port 0 is registered instead. Tomcat DOES come up on a random port, however.
I added a breakpoint in EurekaDiscoveryClientConfiguration.containerPortInitializer() and it is not hit until AFTER the service has registered with Eureka Server in Brixton.M1 and is hit BEFORE service registration in Angel.SR3.
Am I missing something or is this currently broken in Brixton.M1?
This is a known issue that has been fixed in snapshots. Another milestone will come in the next week or so.
i want to install multiple instance of jboss fuse and then integrate each jboss instance with different environment .
eg suppose we have 6 SIT env then we need 6 different jboss fuse to be connected.
and suppose we have 10 different unix user on one server and jboss fuse is install on this server now how we can install fuse on each unix user.
can we create jboss domain same as web-logic domain?
Currently we have downloaded zip file of jboss fuse from red-hat site and unzip this file and do configuration changes per environment that is we unzip file in 6 different users and integrated to SIT env.
what is standard way of doing this?
The solution for this is
Fabric
with the help Fabric we can support multiple environment without any issue.
.
You can run multiple instances
for that you would require to change in etc\system.properties
Change port for below attribute
org.osgi.service.http.port=<Port> #Every Instance should have different port
If you accessing it via putty. It is better to change sshPort as well to prevent the conflict. in etc\org.apache.karaf.shell.cfg
sshPort=8107
Last thing you would require to change is RMI Server Port in etc\org.apache.karaf.management.cfg for each instance.
rmiServerPort = 44444
We have several enterprise application to deploy on Weblogic server. As you know for each domain we could define specific port, deploy an application on that and clients could access to server application by that port. My question is about the port number standard.
Is there any standard to assign server ports number to different application, if No what is your suggestion ? Is counting method (for example) god ?!! or ...
Thanks for your replies
You can deploy your applications in different managed servers. What you have to do is create a managed server per application under your weblogic domain. During the configuration of the managed server you will be asked to give a port number. After setting the managed server your applications can be deployed on them, using the ports you have specified earlier. More information about the weblogic managed servers can be found in weblogic administration guide.