<settings> ... <servers> <server> <id>archiva.internal</id> <username>{archiva-deployment-user}</username> <password>{archiva-deployment-pwd}</password> </server> <server> <id>archiva.snapshots</id> <username>{archiva-deployment-user}</username> <password>{archiva-deployment-pwd}</password> </server> ... </servers> ... </settings>
<project> ... <distributionManagement> <repository> <id>archiva.internal</id> <name>Internal Release Repository</name> <url>dav:http://reposerver.mycompany.com:8080/archiva/repository/internal/</url> </repository> <snapshotRepository> <id>archiva.snapshots</id> <name>Internal Snapshot Repository</name> <url>dav:http://reposerver.mycompany.com:8080/archiva/repository/snapshots/</url> </snapshotRepository> </distributionManagement> ... </project>
<project> ... <build> <extensions> <extension> <groupId>org.apache.maven.wagon</groupId> <artifactId>wagon-webdav</artifactId> <version>1.0-beta-2</version> </extension> </extensions> </build> ... </project>
You can also deploy to the Archiva server using traditional means such as SCP, FTP, etc. For more information on these deployment techniques, refer to the Maven documentation.
Note that once the files are deployed into the location of the Archiva managed repository, they will not be detected by Archiva until the next scan takes place, so the interval should be configured to a reasonably frequent setting.
<project> <modelVersion>4.0.0</modelVersion> <groupId>com.example</groupId> <artifactId>webdav-deploy</artifactId> <packaging>pom</packaging> <version>1</version> <name>Webdav Deployment POM</name> <build> <extensions> <extension> <groupId>org.apache.maven.wagon</groupId> <artifactId>wagon-webdav</artifactId> <version>1.0-beta-2</version> </extension> </extensions> </build> </project>
This pom will not be deployed with the artifact, it simply serves to make the wagon-webdav jar available to the build process.
Alternately, save this file somewhere else, and use "mvn ... -f /path/to/filename" to force the use of an alternate POM file.
mvn deploy:deploy-file -Dfile=filename.jar -DpomFile=filename.pom -DrepositoryId=archiva.internal -Durl=dav:http://repo.mycompany.com:8080/repository/internal/