Errore di 401 durante l'implementazione in Nexus. Non apporto modifiche al nexus installato. Nexus è in esecuzione su localhost:8080/nexus
e sono in grado di accedere con utente/password predefiniti. Quando eseguo mvn deploy
ho ricevuto questo errore.La distribuzione di artefatti in nexus da parte di Maven dà errore "Il codice di ritorno è: 401"?
Ecco il mio POM.
<groupId>testproject</groupId>
<artifactId>testproject</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>testproject</name>
<url>http://maven.apache.org</url>
<distributionManagement>
<repository>
<id>releases</id>
<url>http://localhost:8080/nexus/content/repositories/releases</url>
</repository>
<snapshotRepository>
<id>snapshots</id>
<url>http://localhost:8080/nexus/content/repositories/snapshots</url>
</snapshotRepository>
</distributionManagement>
<dependencies>
.........
</dependencies>
e ~/.m2/settings.xml
<servers>
<server>
<id>snapshots</id>
<username>deployment</username>
<password>deployment123</password>
</server>
<server>
<id>releases</id>
<username>deployment</username>
<password>deployment123</password>
</server>
</servers>
Eccezione:
Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy (default- deploy) on project testproject: Failed to deploy artifacts: Could not transfer artifact testproject:testproject:jar:1.0-20131213.150615-1 from/to snapshots (http://localhost:8080/nexus/content/repositories/snapshots): Failed to transfer file: http://localhost:8080/nexus/content/repositories/snapshots/testproject/testproject/1.0-SNAPSHOT/testproject-1.0-20131213.150615-1.jar.
Return code is: 401 -> [Help 1]
Please help me.
'Impossibile trasferire il file: http: // localhost: 8080/nexus/content/repositories/snapshots/testproject/testproject/1.0-SNAPSHOT/testproject-1.0-20131213.150615-1.jar. 'Il file esiste? – t0mppa
no, non è caricato nel nexus. Ma esiste nella mia directory di destinazione locale. – Gangaraju