0

I have setup the oracle maven command to deploy to a remote server (myservername.com).

    <plugin>
        <!-- This is the configuration for the weblogic-maven-plugin -->
        <groupId>com.oracle.weblogic</groupId>
        <artifactId>weblogic-maven-plugin</artifactId>
        <version>12.1.2-0-0</version>
        <configuration>
             <adminurl>t3://myservername.com:7001</adminurl>
             <user>test</user>
             <password>test1</password>
             <upload>true</upload>
             <remote>true</remote>
             <targets>AdminServer</targets>
             <verbose>true</verbose>
             <source>${project.build.directory}/${project.build.finalName}</source>
             <name>${project.build.finalName}</name>
        </configuration>
        <executions>
            <execution>
            <!-- Deploy the application -->
                <id>wls-deploy</id>
                <phase>pre-integration-test</phase>
                <goals> 
                    <goal>deploy</goal>
                </goals>
            </execution>
            <!-- Stop the application in the pre-integration-test phase -->
            <execution>
                <id>wls-stop-app</id>
                <phase>pre-integration-test</phase>
                <goals>
                    <goal>stop-app</goal>
                </goals>
            </execution>
            <!-- start servicing all requests -->
            <execution>
                <id>wls-start-app</id>
                <phase>pre-integration-test</phase>
                <goals>
                    <goal>start-app</goal>
                </goals>
            </execution>    
        </executions>
    </plugin>

I am getting the following error, it is trying to connect to loacalhost but I don't have a server running on localhost, I have already set the admin url as above.

[ERROR] Failed to execute goal com.oracle.weblogic:weblogic-maven-plugin:12.1.2-0-0:deploy (wls-deploy) on project myproject-web: weblogic.Deployer$DeployerException: weblogic.dep loy.api.tools.deployer.DeployerException: Unable to connect to 't3://localhost:7001': Destination 127.0.0.1, 7001 unreachable; nested exception is:

How can I get the plugin to deploy to a remote server?

jax
  • 37,735
  • 57
  • 182
  • 278
  • Is the WLS admin server listening on 7001 port? The error message says something different. – khmarbaise Aug 26 '13 at 07:28
  • @khmarbaise, yes it is listening on port 7001 (on the remote server), there is no server running locally on my pc. – jax Aug 26 '13 at 09:59
  • But your configurate says it should connect to localhost or 127.0.0.1 – khmarbaise Aug 26 '13 at 10:13
  • @khmarbaise, `127.0.0.1` means `localhost`, I don't think I know what your getting at. The problem I am having is that the connection is trying to connect to localhost (127.0.0.1) on port 7001, It should be authentication via `myservername.com:7001` (see the `adminurl` section) – jax Aug 26 '13 at 10:14
  • But the error message states something different `Unable to connect to 't3://localhost:7001': Destination 127.0.0.1, 7001 unreachable; nested exception is:`... So either your configuration of your WLS is wrong..I'm not sure if the weblogic-maven-plugin is able to handle remote deployment ? (What does the docs say?) – khmarbaise Aug 26 '13 at 10:43
  • @khmarbaise, from the docs - When true, `` specifies that the plug-in is not running on the same machine as the Administration Server. In this case, the source parameter specifies a path on the server, unless the upload parameter is also used. Default value is: false – jax Aug 26 '13 at 11:36
  • can you try setting the adminurl via jvm option: "mvn com.oracle.weblogic:weblogic-maven-plugin:deploy -Dadminurl=t3://myhost:7001" ... – Markus Eisele Aug 27 '13 at 09:38
  • @Markus I got the same error. `mvn pre-integration-test -Dadminurl=t3://mysite.com:7001 -P integration-weblogic` ... `Unable to connect to 't3://localhost:7001': Destination 127.0.0.1, 7001 unreachable;` – jax Aug 28 '13 at 00:15
  • Maybe you can use `weblogic.deployer` instead as a work-around? http://docs.oracle.com/cd/E11035_01/wls100/deployment/deploy.html – Display Name is missing Aug 28 '13 at 15:17

0 Answers0