Pergunta

From an ant script, I'm able to use the app-deployer, adapter-deployer with the worklightServerhost property to publish apps

<!-- Deploys adapter file to configured host & project -->
<target name="adapterDeployer" depends="init">
    <echo.timestamp message="Deploying adapter ${adapterFile}" />
    <adapter-deployer worklightServerHost="${WLSERVERHOST}/${project.name}"
        deployable="${adapterFile}" />
</target>

Why, when I want to publish the project WAR file do I need to reference installdir ? My CI environment isn't running Liberty profile.

<target name="deployWar" depends="init">
    <updateapplicationserver>
        <project warfile="${build.dir}/${project.name}.war" />
        <applicationserver>
            <websphereApplicationserver installdir="WTH this is a CI server" />
        </applicationserver>
    </updateapplicationserver>
</target>

Are there any shortcuts or do i need to scp my war to a different box & run a different ant script?

Foi útil?

Solução

We have a similar scenario, where we are deploying in an automated way from Jenkins, and the answer is basically 'yes'; you need to SCP your WAR to the target box, along with a small ANT script to deploy it with, and then run that 'locally' (we use a remote SSH command to do that). When you are using <adapter-deployer> (or <app-deployer>) you are basically connecting to an existing deployed Worklight server (which essentially is the .war file). However, getting the WAR file on there in the first place involves using the <updateapplicationserver> ANT task (in fact, in our scenario, we use <unconfigureapplicationserver>, followed by <configureapplicationserver>, as this gives the chance to update the JNDI properties also).

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top