bmlynarczyk
bmlynarczyk

Reputation: 808

Deploy with maven plugin on remote weblogic 12c

I have weblogic 12c on machine 192.168.1.3. I want to deploy ear from machine 192.168.1.2 with maven plugin:

<groupId>com.oracle.weblogic</groupId>
<artifactId>wls-maven-plugin</artifactId>
<version>12.1.1.0</version>

In the first phase I made in the project:

mvn wls:install

Plugin configuration looks like this:

<configuration>
    <adminurl>t3://192.168.1.3:7001</adminurl>
    <user>weblogic</user>
    <password>welcome1</password>
    <debug>true</debug>
    <name>test-ear-dev01</name>                     
    <remote>true</remote>
    <upload>true</upload>
    <advanced>true</advanced>
    <failOnError>true</failOnError>
    <artifactLocation>c:\Users\bartek\Downloads\wls1211_dev.zip</artifactLocation>
</configuration>

next I make

mvn wls:deploy

and I get following error

[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Invalid file. Please provide an existing fully qualified path of the file.
[DEBUG] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Invalid file. Please provide an existing fully qualified path of the file.
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
        ...
        ...
        ...
Caused by: org.apache.maven.plugin.MojoExecutionException: Invalid file. Please provide an existing fully qualified path of the file.
        at weblogic.tools.maven.plugins.deploy.DeployerMojo.handleDeployerException(DeployerMojo.java:459)
        ...
Caused by: org.apache.maven.plugin.MojoExecutionException: Invalid file. Please provide an existing fully qualified path of the file.
        at weblogic.tools.maven.plugins.deploy.DeployerMojo.getSourceParameter(DeployerMojo.java:434)
        ...

Can you tell me what I'm doing wrong, when deploy ear to a remote server

Upvotes: 1

Views: 4715

Answers (1)

user944849
user944849

Reputation: 14961

The configuration you show looks like what you used to install WebLogic with the install goal of the plugin. <artifactLocation> is a configuration element for that goal, not deploy, per the documentation.

For the deploy goal, replace <artifactLocation> with <source>, which contains the name of your ear file.

Upvotes: 2

Related Questions