I am trying to remotely deploy a war file to a websphere application server. I understand this is possible to do using wsadmin, but I am a Websphere newb.
I know I can run wsadmin and connect using SOAP to the remote app server, but that is where I am at.
This seems like it should be a common use case, can anyone help me with?
I suppose the use case follows: 1. Update the application 2. Save all changes 3. Restart the remote application server
I am going to do the deployment using either Hudson WAS Builder or Maven, whichever works.
Thanks for your help
Since the WAS Builder Plugin is relatively new, I haven't tested it (The evaluation is already on the ToDo list). For running deployments from the command line we use jython-scripts and wsadmin. My understanding is that I need to be on the machine where I want to deploy. You can deploy to a different machine id your local wsadmin is on the level than your target machine (same version and same feature packs).
for more information on wsadmin see http://publib.boulder.ibm.com/infocenter/wsdoc400/v6r0/index.jsp?topic=/com.ibm.websphere.iseries.doc/info/ae/ae/rxml_commandline.html
BTW, when you deploy using the web based admin console, there is a link somewhere at the end of the deployment process that shows you the jython command. Don't use jacl, since WAS 7 only uses jython.
This question is pretty old, but id like to show how we do this remotly. In this case with Ant
<target name="postbuild">
<exec executable="C:\MyThinClient\wsadmin.bat" failonerror="true">
<arg line="-conntype SOAP -host ${deployServer} -port ${deployPort} -user ${deployUser} -password ${deployPassword} -c" />
<arg value="$AdminApp update ${projectName}EAR app {-operation update -contents {${artifactsDir}/${projectName}-${buildVersion}.ear}}" />
</exec>
</target>
Given the correct setup of the wsadmin.bat you can run this from any server (without WAS installed) At least on WAS 6.1/7.0 ND this will only restart the application with the new binaries, not the whole server
The link to the scripts didn't show up right in my comment, so here it is: IBM SAMPLE SCRIPTS
来源:https://stackoverflow.com/questions/2118559/remote-deployment-to-websphere-6-1-x-using-wsadmin