Adding IHS server details under ant script - ant

I have an ant script to deploy the EAR file to my Websphere application server. This server is under clustered environment and has a cell with its respective nodes.
I also have an IHS server above this WAS instance which my application uses.
Requesting to kindly guide as to how the ant script can be used to deploy the EAR file on cluster by providing the required IHS server details.
Thanks

You should have a look at the section in $WASHOME/bin/configureWebserverDefinition.jacl that iterates through the existing web modules and maps them to the newly created webserver.
In Jython, from the manual:
AdminApp.edit('myapp', ['-MapModulesToServers',
[['.*', '.*', '-WebSphere:cell=mycell,node=mynode,server=server1']]])
But you'd need to substitue the full name for your webserver.

Related

How to setup WebSphere Liberty as a very simple HTTP Serve to serve files in a directory

I need to setup IBM Maximo attachments feature to work with WebSphere Liberty. IBM confirms that WebSphere Liberty is compatible wit Maximo, but does not provide official support.
Bottom line, all I need is to serve files inside a directory through HTTP using WebSphere Liberty. I was wondering how I can do that.
This is a guide that I need to adapt it from http://www-01.ibm.com/support/docview.wss?uid=swg21312993 with WebSphere Liberty instead.
Can anyone guide me through?
IBM HTTP Server (IHS) already installed with Maximo. IHS is a flavor of Apache, so any Apache related doc will work. I configured Maximo doclinks to fall under htdocs so the attachments are available as a web resource. Bottom line, its not clear to me you need to configure WebSphere Liberty for this purpose.

How to integrate configuration files from a config service in rails?

I am currently running a rails application and a SpringBoot configuration service in the same local network. Is it possible to configure rails to use the config files provided by the service in Springboot?
More specifically I am looking to fetch the database connection and user data via the service and let rails connect to a remote database.
The service provides theses files via http as json or yml.
Thank you.
Edit: Solved it by using a bash script with wget to pull and assemble config files manually via container scripts that are executed before each deploy.

setting Log4j2 Config file path through system variable in IBM Websphere 8.5

I am using IBM Webspehere 8.5, where i need to pass the the log4j2 config file path externally (not hardcoded in deployed jar file as for dev, uat and prod different config file are present)
Log4j2 site tells https://logging.apache.org/log4j/2.0/faq.html
You can also specify the full path of the configuration file with this system property:
-Dlog4j.configurationFile=path/to/log4j2.xml
IBM WS site tells how to set it (But is it system property or environment variable)
http://www-01.ibm.com/support/docview.wss?uid=swg21254153
Also . Can you please let me know the right way to set Log4j2 system property.
See the Java virtual machine custom properties topic in the Knowledge Center for information on setting JVM system properties:
To set custom properties, connect to the administrative console and navigate to the appropriate Java virtual machine custom properties page.
Application Server
Click Servers > Server Types, and either WebSphere application servers > server_name or WebSphere proxy servers > server_name. Then, under Server Infrastructure, click Java and process management > Process definition > Java virtual machine > Custom properties.

Is there a way make a Grails app aware of changes in properties file without server restart?

I've externalized the properties file for my production Grails app running on Tomcat.
I'm wondering if there is a way the Grails app will read the configs from the config file in real time instead of having the changes take affect only after server restart.
For example, I'm using the LDAP plugin which has the following config:
grails.plugin.springsecurity.ldap.context.managerDn = 'somethinghere'
If I change the above setting in the external config file the server needs to be restarted for it to take effect.
I googled "grails external reload" and the first result was http://grails.org/plugin/external-config-reload

Jasper-Struts2 plugin: compiled reports from external directory

I'm using Jasper with the Struts2 plugin to generate PDF reports for my web application, as described in this tutorial.
The application uses Weblogic as app server and Apache as webserver in development environment, IIS in testing and production environments.
Locally I put the .jasper files under WEB-INF of the WAR section, which is then put in a EAR after compilation.
PDF generation works locally, passing a relative path (namely WEB-INF/jasper/template.jasper) to the result parameters of the "jasper" result in struts.xml . This does not work when the application is deployed as an EAR.
How can I get my application to find the .jasper template even when deployed as an EAR? I tried to pass in an absolute path pointing to a directory in the same server the EAR is in, but it doesn't work.
And by the way, is there a comprehensive guide to the Struts2 plugin for Jasper? I couldn't find anything except for that tutorial.
In weblogic domain home's webapplications tab; enable the option called Archived Real Path Enabled
works for me in weblogic 11g or later versions

Resources