Some of our projects still use Maven 1. Is it possible to deploy artifacts to a Nexus Maven 1 Repository using "maven:deploy" goal? I could not find the properties to set username and password.
We found a work around by sharing the storage folder of the Nexus server and deploying directly into that folder using file protocol, but this is not really a preferred solution.
Nexus supports hosted repositories using the Maven 1 format so you can use the usual deployment setup. Unfortunately I do NOT remember how to do the deployment with credentials in Maven 1, but I assume the archived documentation would detail that.
If you can not get this to work easily and the project is not VERY complex I would actually suggest to drop Maven 1 and upgrade to Maven 3. This would solve your problem and bring numerous improvements to your development team. Maven 1 has been unsupported and deprecated for years and which puts you into this troublesome situation.
If you're using Maven 2 (not Maven 3) you can also deploy artifacts in Maven 1 format by adding "legacy to your distributionManagment
<distributionManagement>
<repository>
<id>nexus</id>
<name>Release Repository</name>
<url>http://localhost:8081/nexus/content/repositories/maven1</url>
<layout>legacy</layout>
</repository>
...
</distributionManagement>
This won't work with Maven 3, the legacy layout support was removed in that version of Maven.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.