maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maxime Gréau <greaumax...@gmail.com>
Subject Re: maven 3, deploy:deploy-file and dav:http
Date Sat, 05 Mar 2011 08:29:45 GMT
Hi,

Since Maven 3.0, by default, you can only use HTTP protocol to deploy
artefacts in a remote repository.

1) If you want to use HTTP protocol, you have to ensure that
- your remote repository allow HTTP PUT method
- your credentials are ok

2) If you want to use an other protocol like DAV (or SCP, FTP...), you have
to add an extension in your POM, this is the example for DAV :

<build>
    <extensions>
         <extension>
            <groupId>org.apache.maven.wagon</groupId>
            <artifactId>wagon-webdav-jackrabbit</artifactId>
            <version>1.0-beta-7</version>
         </extension>
     </extensions>
     ....
</build>

Maxime Gréau.
http://mgreau.com



2011/2/4 wujek <wujek.srujek@googlemail.com>

>
> Hi. I am trying to deploy a custom artifact to our internal repo using
> maven
> 3.0.2:
> mvn deploy:deploy-file -Dfile=file.jar -Dversion=1.0.0
> -DgroupId=com.example
>    -DartifactId=artifact -Dpackaging=jar -DrepositoryId=internal
>    -Durl=dav:http://10.1.1.7/maven_repo
>
> where a corresponding <server> element with id internal is in my
> settings.xml, and it has a username and password corresponding to a local
> user on the machine I am trying to deploy to. This doesn't work, I get:
>
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-deploy-plugin:2.5:deploy-file (default-cli)
> on project standalone-pom: Failed to deploy artifacts/metadata: No
> connector
> available to access repository remote-repository (dav:
> http://10.1.1.7/maven)
> of type default using the available factories
> WagonRepositoryConnectorFactory -> [Help 1]
>
> When I remove the dav prefix, I get:
>
> Uploading: http://10.1.1.7/maven/com/test/test/1/test-1.jar
> Uploading: http://10.1.1.7/maven/com/test/test/1/test-1.pom
> [INFO]
> ------------------------------------------------------------------------
> [INFO] BUILD FAILURE
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 1.312s
> [INFO] Finished at: Fri Feb 04 08:15:35 CET 2011
> [INFO] Final Memory: 4M/117M
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-deploy-plugin:2.5:deploy-file (default-cli)
> on project standalone-pom: Failed to deploy artifacts: Could not transfer
> artifact com.test:test:jar:1 from/to remote-repository
> (http://10.1.1.7/maven): Access denied to:
> http://10.1.1.7/maven/com/test/test/1/test-1.jar -> [Help 1]
>
> Which I think it means it tries to upload, but there is something wrong
> with
> the credentials?
>
> How can I configure this correctly?
>
> In maven 2, the first approach used to work, with the dav:http protocol, it
> all changed in maven 3, or at least is seems so.
>
> Thanks.
>
>
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/maven-3-deploy-deploy-file-and-dav-http-tp3370548p3370548.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message