Hello Dave,

you should pass the projectName as an argument, so if you put it after the other arguments, I guess inside your script you would have sys.argv[4] instead of ${projectName}

Regards,

Antoine


dave.alvar...@remanresource.com wrote:
Hi,

I have the below target ...

        <target name="deploy" depends="copy-war">
                <taskdef name="wlst" 
classname="weblogic.ant.taskdefs.management.WLSTTask" />
<wlst debug="true" failOnError="true" executeScriptBeforeFile="false" fileName="./wls_scripts/wls922_definitions.py"
                arguments="${wlsuser} ${wlspwd} ${wlshosturl} "
> <script>
print 'Calling the script ...'
connect(sys.argv[1],sys.argv[2],sys.argv[3])
shutdownCluster("my_cluster_1")
undeploy("RoutingEngine#v1.0")
removeApplication("RoutingEngine#v1.0")
deploy('RoutingEngine#v1.0', '/opt/wars/routing_engine_wars/RoutingEngine.war', 
targets='my_cluster_1' )
startCluster("my_cluster_1")
disconnect()
        </script>
</wlst> </target>

Problem is, if I try and put in variables within the "<script>" segment, for 
example

removeApplication("${projectName}#v1.0")

They are literally interpreted.  So the above tries to remove the application, 
"${projectName}#v1.0".  How can I get my variables passed to this?  I hate 
having to hard code things.

Thanks, - Dave

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@ant.apache.org
For additional commands, e-mail: user-h...@ant.apache.org

Reply via email to