You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by jeb001 <je...@gmail.com> on 2011/01/13 10:54:47 UTC
Maven release:perform deploy failed access denied
Hi,
I'm trying to build my first release of my multi-modules projects.
In my settings.xml :
<server>
<id>my-releases</id>
<username>deployer</username>
<password>123</password>
</server>
in my main pom.xml :
<distributionManagement>
<repository>
<id>my-releases</id>
<name>Repository Nexus</name>
<url>http://serverIp/nexus/content/groups/MyRepositories/</url>
</repository>
</distributionManagement>
Unfortunately, I've got this error :
INFO] [INFO] [deploy:deploy {execution: default-deploy}]
[INFO] Uploading:
http://serverIp/nexus/content/groups/MyRepositories//com/project/Parent/0.0.5/Parent-0.0.5.pom
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [ERROR] BUILD ERROR
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Error deploying artifact: Authorization failed: Access denied
to:
http://serverIp/nexus/content/groups/MyRepositories/com/project/Parent/0.0.5/Parent-0.0.5.pom
[INFO]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Maven execution
failed, exit code: '1'
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
.... what's wrong ??
Thx !
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3339497.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
Re: Maven release:perform deploy failed access denied
Posted by Baptiste MATHUS <ml...@batmat.net>.
I think this question might be better suited to the Nexus ML, but anyway we
actually use nexus and don't use ssh protocol, simple http (webdav) and it
works fine.
I don't even know if Nexus supports ssh transport.
In your case, if possible, I'd try using http instead of ssh.
If not possible, maybe your config is just missing some port config and
just hitting the host ssh server instead of the nexus one?
Cheers
2013/2/19 Stiffler82 <ha...@gmail.com>
> Hi There,
>
> I am totally desperated! I try to deploy an artifact via maven to my own
> nexus server. But every time when I run "mvn deploy" I got the following
> stacktrace:
>
> [INFO] --- maven-deploy-plugin:2.7:deploy (default-deploy) @ core ---
> Uploading:
> scpexe://nexus.innosquared.com/nexus/content/repositories/central/com
> /innosquared/core/1.1.10/core-1.1.10.jar
> Uploading:
> scpexe://nexus.innosquared.com/nexus/content/repositories/central/com
> /innosquared/core/1.1.10/core-1.1.10.pom
> [INFO]
> ------------------------------------------------------------------------
> [INFO] BUILD FAILURE
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 21.121s
> [INFO] Finished at: Tue Feb 19 20:39:17 CET 2013
> [INFO] Final Memory: 12M/160M
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-deploy-plugin:2.7:
> deploy (default-deploy) on project core: Failed to deploy artifacts: Could
> not t
> ransfer artifact com.innosquared:core:jar:1.1.10 from/to nexus
> (scpexe://nexus.i
> nnosquared.com/nexus/content/repositories/central): Exit code: 1 - Access
> denied
>
> [ERROR] Lost connection
> [ERROR] -> [Help 1]
> [ERROR]
> [ERROR] To see the full stack trace of the errors, re-run Maven with the -e
> swit
> ch.
> [ERROR] Re-run Maven using the -X switch to enable full debug logging.
> [ERROR]
> [ERROR] For more information about the errors and possible solutions,
> please
> rea
> d the following articles:
> [ERROR] [Help 1]
> http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionE
> xception
>
>
>
>
> I added the following snippet to my pom.xml:
>
> <distributionManagement>
> <repository>
> <id>nexus</id>
> <name>Nexus Release Repository</name>
>
> <url>scpexe://nexus.innosquared.com/nexus/content/repositories/central
> </url>
> </repository>
>
> </distributionManagement>
>
>
> My settings.xml have a servers section:
>
> <servers>
> <server>
> <id>nexus</id>
> <username>deployment</username>
> <password>my_password</password>
> <privateKey>my_private_key.pkk</privateKey>
> <passphrase>my_passphrase</passphrase>
> <filePermissions>664</filePermissions>
> <directoryPermissions>775</directoryPermissions>
> <configuration>
> <sshExecutable>plink</sshExecutable>
> <scpExecutable>pscp</scpExecutable>
> </configuration>
> </server>
> </servers>
>
>
> Nexus log just said:
> jvm 1 | 2013-02-19 19:54:14 WARN [tp2109759485-35] -
> org.sonatype.nexus.rest.repositories.RepositoryPlexusResource - Repository
> access denied, id=central
> jvm 1 | 2013-02-19 20:21:12 INFO [Thread-12 ] -
> org.apache.shiro.session.mgt.AbstractValidatingSessionManager - Validating
> all active sessions...
> jvm 1 | 2013-02-19 20:21:12 INFO [Thread-12 ] -
> org.apache.shiro.session.mgt.AbstractValidatingSessionManager - Finished
> session validation. No sessions were stopped.
>
>
> So it seems that ssh file upload works, but nexus denies access. But I'm
> totally sure the password is correct and I also checked the rights for
> deployment user in nexus.
>
> Any suggestions would be great!
>
>
>
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p5747643.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
>
> --
> Baptiste <Batmat> MATHUS - http://batmat.net
> Sauvez un arbre,
> Mangez un castor ! nbsp;! <us...@maven.apache.org>
Re: Maven release:perform deploy failed access denied
Posted by Stiffler82 <ha...@gmail.com>.
Hi There,
I am totally desperated! I try to deploy an artifact via maven to my own
nexus server. But every time when I run "mvn deploy" I got the following
stacktrace:
[INFO] --- maven-deploy-plugin:2.7:deploy (default-deploy) @ core ---
Uploading:
scpexe://nexus.innosquared.com/nexus/content/repositories/central/com
/innosquared/core/1.1.10/core-1.1.10.jar
Uploading:
scpexe://nexus.innosquared.com/nexus/content/repositories/central/com
/innosquared/core/1.1.10/core-1.1.10.pom
[INFO]
------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 21.121s
[INFO] Finished at: Tue Feb 19 20:39:17 CET 2013
[INFO] Final Memory: 12M/160M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-deploy-plugin:2.7:
deploy (default-deploy) on project core: Failed to deploy artifacts: Could
not t
ransfer artifact com.innosquared:core:jar:1.1.10 from/to nexus
(scpexe://nexus.i
nnosquared.com/nexus/content/repositories/central): Exit code: 1 - Access
denied
[ERROR] Lost connection
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e
swit
ch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please
rea
d the following articles:
[ERROR] [Help 1]
http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionE
xception
I added the following snippet to my pom.xml:
<distributionManagement>
<repository>
<id>nexus</id>
<name>Nexus Release Repository</name>
<url>scpexe://nexus.innosquared.com/nexus/content/repositories/central</url>
</repository>
</distributionManagement>
My settings.xml have a servers section:
<servers>
<server>
<id>nexus</id>
<username>deployment</username>
<password>my_password</password>
<privateKey>my_private_key.pkk</privateKey>
<passphrase>my_passphrase</passphrase>
<filePermissions>664</filePermissions>
<directoryPermissions>775</directoryPermissions>
<configuration>
<sshExecutable>plink</sshExecutable>
<scpExecutable>pscp</scpExecutable>
</configuration>
</server>
</servers>
Nexus log just said:
jvm 1 | 2013-02-19 19:54:14 WARN [tp2109759485-35] -
org.sonatype.nexus.rest.repositories.RepositoryPlexusResource - Repository
access denied, id=central
jvm 1 | 2013-02-19 20:21:12 INFO [Thread-12 ] -
org.apache.shiro.session.mgt.AbstractValidatingSessionManager - Validating
all active sessions...
jvm 1 | 2013-02-19 20:21:12 INFO [Thread-12 ] -
org.apache.shiro.session.mgt.AbstractValidatingSessionManager - Finished
session validation. No sessions were stopped.
So it seems that ssh file upload works, but nexus denies access. But I'm
totally sure the password is correct and I also checked the rights for
deployment user in nexus.
Any suggestions would be great!
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p5747643.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
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
YES I found out !!!
I tried to add the distributionManagement Tag in each module of my
multi-module project..
and it worked !!
Still dunno why deploy goal does no need it, and perform goal needs.. but,
it works !!
Thanks everyone for your help, sincerely
Jeremy
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3347495.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
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Hi Mark,
I do you think that it might be a permission problem even if the deploy goal
does work ?
It seems that I'm not the first one encounting that issue.. but I just don't
find any workaround..
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3347450.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
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
..unfortunately, I think I'm right in the pom structure :
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>xxx/groupId>
<artifactId>xxx</artifactId>
<version>0.0.7-SNAPSHOT</version>
<packaging>pom</packaging>
<name>xxx</name>
<url>xxx</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<!-- -->
</dependencies>
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.1</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-release-plugin</artifactId>
<version>2.0-beta-9</version>
<configuration />
</plugin>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.5</version>
<configuration>
<minmemory>128m</minmemory>
<maxmemory>1g</maxmemory>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
<scm>
<developerConnection>scm:cvs:xxx</developerConnection>
</scm>
<distributionManagement>
<!--- ---->
</distributionManagement>
<modules>
<module>xx</module>
<module>xx</module>
<module>xx</module>
</modules>
</project>
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345936.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
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
I tried that, still the same result...
I begin to think that a single module project should be more easy to work
with...
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3346186.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
Re: Maven release:perform deploy failed access denied
Posted by Mark Struberg <st...@yahoo.de>.
hi!
Please look at the file permissions on your server, maybe the file got uploaded by someone else and you have no right to write to this directory.
To prevent such situations, one usually uses the following settings.xml configuration:
<server>
<id>yourServerId</id>
<username>yourusername</username>
<password>yourpassword</password>
<directoryPermissions>0775</directoryPermissions>
<filePermissions>0664</filePermissions>
</server>
Rerun the release with the -X option and use | tee mvn.log to catch the full output of the maven run.
LieGrue,
strub
PS: I assume you substituted your servername in
Uploading: http://serverIp/nexus/content/groups/MyRepositories//com/project/Parent/0.0.5/Parent-0.0.5.pom , right?
--- On Tue, 1/18/11, jeb001 <je...@gmail.com> wrote:
> From: jeb001 <je...@gmail.com>
> Subject: Re: Maven release:perform deploy failed access denied
> To: users@maven.apache.org
> Date: Tuesday, January 18, 2011, 12:48 PM
>
> Hum.. I tried something else, I launched the mvn:deploy
> task, and it works !!
>
> ... I jus't don't understand... any idea ?
> --
> View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3346122.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
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Hum.. I tried something else, I launched the mvn:deploy task, and it works !!
... I jus't don't understand... any idea ?
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3346122.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
Re: Maven release:perform deploy failed access denied
Posted by Wayne Fay <wa...@gmail.com>.
> So please, once you sort this out, post back with the root cause and
> your solution, for the benefit of others on the ml...
Hmmm going back and looking at a few of those emails, I think the
problem is that people are putting the distributionManagement node in
the wrong spot in their pom file. It does not go inside <build/> or
anywhere else, but rather should simply be directly inside <project/>.
What is the xpath to this node in your pom file? It should be simply
/project/distributionManagement. Anything else will cause problems.
Wayne
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by Wayne Fay <wa...@gmail.com>.
> INFO] [DEBUG] Trace
> [INFO] org.apache.maven.lifecycle.LifecycleExecutionException: Error
> configuring: org.apache.maven.plugins:maven-deploy-plugin. Reason: Unable to
> parse the created DOM for plugin configuration
I've seen this a few times related to the deploy plugin in the last ~8
months, but haven't seen any follow up posts saying "oh we solved it,
here's what was wrong." But I assume the other posters must have fixed
their troubles, or they'd still be making noise and complaining about
how they can't deploy things any more.
So please, once you sort this out, post back with the root cause and
your solution, for the benefit of others on the ml...
Wayne
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
with more details from the logs...
INFO] [DEBUG] Trace
[INFO] org.apache.maven.lifecycle.LifecycleExecutionException: Error
configuring: org.apache.maven.plugins:maven-deploy-plugin. Reason: Unable to
parse the created DOM for plugin configuration
[INFO] at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:723)
[INFO] at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345894.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
Re: Maven release:perform deploy failed access denied
Posted by Stephen Connolly <st...@gmail.com>.
On 18 January 2011 09:40, jeb001 <je...@gmail.com> wrote:
>
> Ok, so..
>
> In my settings.xml :
> <mirror>
> <id>repository</id>
> <name>Miror nexus</name>
> <url>http://nexus/content/groups/MyRepositories/</url>
> <mirrorOf>*,!repository-releases,!repository-snapshots</mirrorOf>
not related to your issue, but still
just <mirrorOf>*</mirrorOf>
you should have http://nexus/content/groups/MyRepositories/
aggregating all the repos even repository-releases and
repository-snapshots
> </mirror>
>
> in the pom.xml I removed repositories tag and keep that :
>
> <distributionManagement>
> <!-- use the following if you're not using a snapshot version. -->
> <repository>
> <id>repository-releases</id>
> <name>Repository Name</name>
> <url>http://nexus/content/repositories/Releases/</url>
> </repository>
> <!-- use the following if you ARE using a snapshot version. -->
> <snapshotRepository>
> <id>repository-snapshots</id>
> <name>Snapshots Repository</name>
> <url>http://nexus/content/repositories/Snapshots/</url>
> </snapshotRepository>
> </distributionManagement>
>
> I'm still having that error :-( :
>
>
> [INFO] [INFO] Failed to configure plugin parameters for:
> org.apache.maven.plugins:maven-deploy-plugin:2.4
> [INFO]
> [INFO] check that the following section of the pom.xml is present and
> correct:
> [INFO]
> [INFO] <distributionManagement>
> [INFO] <!-- use the following if you're not using a snapshot version. -->
> [INFO] <repository>
> [INFO] <id>repo</id>
> [INFO] <name>Repository Name</name>
> [INFO] <url>scp://host/path/to/repo</url>
> [INFO] </repository>
> [INFO] <!-- use the following if you ARE using a snapshot version. -->
> [INFO] <snapshotRepository>
> [INFO] <id>repo</id>
> [INFO] <name>Repository Name</name>
> [INFO] <url>scp://host/path/to/repo</url>
> [INFO] </snapshotRepository>
> [INFO] </distributionManagement>
> [INFO]
> [INFO] Cause: Class
> 'org.apache.maven.artifact.repository.ArtifactRepository' cannot be
> instantiated
>
>
> ...
> --
> View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345882.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
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Ok, so..
In my settings.xml :
<mirror>
<id>repository</id>
<name>Miror nexus</name>
<url>http://nexus/content/groups/MyRepositories/</url>
<mirrorOf>*,!repository-releases,!repository-snapshots</mirrorOf>
</mirror>
in the pom.xml I removed repositories tag and keep that :
<distributionManagement>
<!-- use the following if you're not using a snapshot version. -->
<repository>
<id>repository-releases</id>
<name>Repository Name</name>
<url>http://nexus/content/repositories/Releases/</url>
</repository>
<!-- use the following if you ARE using a snapshot version. -->
<snapshotRepository>
<id>repository-snapshots</id>
<name>Snapshots Repository</name>
<url>http://nexus/content/repositories/Snapshots/</url>
</snapshotRepository>
</distributionManagement>
I'm still having that error :-( :
[INFO] [INFO] Failed to configure plugin parameters for:
org.apache.maven.plugins:maven-deploy-plugin:2.4
[INFO]
[INFO] check that the following section of the pom.xml is present and
correct:
[INFO]
[INFO] <distributionManagement>
[INFO] <!-- use the following if you're not using a snapshot version. -->
[INFO] <repository>
[INFO] <id>repo</id>
[INFO] <name>Repository Name</name>
[INFO] <url>scp://host/path/to/repo</url>
[INFO] </repository>
[INFO] <!-- use the following if you ARE using a snapshot version. -->
[INFO] <snapshotRepository>
[INFO] <id>repo</id>
[INFO] <name>Repository Name</name>
[INFO] <url>scp://host/path/to/repo</url>
[INFO] </snapshotRepository>
[INFO] </distributionManagement>
[INFO]
[INFO] Cause: Class
'org.apache.maven.artifact.repository.ArtifactRepository' cannot be
instantiated
...
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345882.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
Re: Maven release:perform deploy failed access denied
Posted by Anders Hammar <an...@hammar.net>.
Normally, the urls for deploying snapshots and release are different.
Surely there must be some kind of help/info where you work on how to
configure this? Most of these configs depend on how the infrastructure is
set up and it's very hard for us to tell you how your environment is.
/Anders
On Tue, Jan 18, 2011 at 10:08, jeb001 <je...@gmail.com> wrote:
>
> ok... If I try to sum up...
>
> First issue was to use a groups URL of nexus.. ok, it's correct now.
> Then, both of the distMgt tag and repository set the same URL.. but
> repositories tag have to
> be moved in the settings.xml.
>
> Am I right now ?
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345851.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
>
>
Re: Maven release:perform deploy failed access denied
Posted by Ron Wheeler <rw...@artifact-software.com>.
Stephen is right about how to set up Nexus.
You probably should have got all this advice from the Nexus installation
docs.
Read them and direct some/most of these questions to the Nexus forum.
Ron
On 18/01/2011 4:25 AM, Stephen Connolly wrote:
> On 18 January 2011 09:08, jeb001<je...@gmail.com> wrote:
>> ok... If I try to sum up...
>>
>> First issue was to use a groups URL of nexus.. ok, it's correct now.
> Correct
>
>> Then, both of the distMgt tag and repository set the same URL..
> Incorrect...
>
> distMgt should point to the repo. repositories should point to the
> group that aggregates the repo and central and whatever other repos
> you want.
>
>> but
>> repositories tag have to
>> be moved in the settings.xml.
> It's optional to move it, but its best practice... in fact better
> practice is just to use a<mirrorOf>*</mirrorOf> and not have any
> repositories in your settings.xml
>
>> Am I right now ?
>> --
>> View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345851.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
>>
>>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by Stephen Connolly <st...@gmail.com>.
On 18 January 2011 09:25, Stephen Connolly
<st...@gmail.com> wrote:
> On 18 January 2011 09:08, jeb001 <je...@gmail.com> wrote:
>>
>> ok... If I try to sum up...
>>
>> First issue was to use a groups URL of nexus.. ok, it's correct now.
>
> Correct
>
>> Then, both of the distMgt tag and repository set the same URL..
>
> Incorrect...
>
> distMgt should point to the repo. repositories should point to the
> group that aggregates the repo and central and whatever other repos
> you want.
>
>> but
>> repositories tag have to
>> be moved in the settings.xml.
>
> It's optional to move it, but its best practice... in fact better
> practice is just to use a <mirrorOf>*</mirrorOf> and not have any
> repositories in your settings.xml
Just to clarify:
If you have repositories in your pom.xml then every build which needs
to check for artifacts will check central and all the repositories
listed in your pom... that is two web requests and the request to
central will be first, slowing down your build and increasing your
bandwidth bills... when you change your infrastructure, any projects
depending on the old deployed pom will gain an extra invalid url to
check against and you will have to wait for that to time-out during a
build... so this gives the slowest build
If you have repositories in your settings.xml you still get multiple
repositories but at least you can update invalid urls and remove
having to wait for the timeout
If you use <mirrorOf>*</mirrorOf> in your settings.xml then you only
ever have one respoitory queried during your build.... so this gives
the fastest builds... also mirrorOf handles both pluginRepositories
and repositories reducing xml verbage
>
>>
>> Am I right now ?
>> --
>> View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345851.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
>>
>>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by Stephen Connolly <st...@gmail.com>.
On 18 January 2011 09:08, jeb001 <je...@gmail.com> wrote:
>
> ok... If I try to sum up...
>
> First issue was to use a groups URL of nexus.. ok, it's correct now.
Correct
> Then, both of the distMgt tag and repository set the same URL..
Incorrect...
distMgt should point to the repo. repositories should point to the
group that aggregates the repo and central and whatever other repos
you want.
> but
> repositories tag have to
> be moved in the settings.xml.
It's optional to move it, but its best practice... in fact better
practice is just to use a <mirrorOf>*</mirrorOf> and not have any
repositories in your settings.xml
>
> Am I right now ?
> --
> View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345851.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
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
ok... If I try to sum up...
First issue was to use a groups URL of nexus.. ok, it's correct now.
Then, both of the distMgt tag and repository set the same URL.. but
repositories tag have to
be moved in the settings.xml.
Am I right now ?
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345851.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
Re: Maven release:perform deploy failed access denied
Posted by Stephen Connolly <st...@gmail.com>.
Nope.
you can (and should) deploy to your nexus/artifactory server.
you can (and should) pull dependencies from your nexus/artifactory server.
However, you might use groups to aggregate several repos in your nexus
server so that you only need the one <repository> definition (and
better yet keep that in your settings.xml as <repository> definitions
in pom.xml files are discouraged... they slow down a build and they
are set in stone.... repository urls are something that is known to
change)
I think the issue you are having originally is that you are trying to
deploy to a group... nexus does not let you do that.
-Stephen
On 18 January 2011 08:49, jeb001 <je...@gmail.com> wrote:
>
> Ok !
>
> So, repository should design my nexus server ? and distMgt should design a
> file server ?
> --
> View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345828.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
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Ok !
So, repository should design my nexus server ? and distMgt should design a
file server ?
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345828.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
Re: Maven release:perform deploy failed access denied
Posted by Anders Hammar <an...@hammar.net>.
Those are two totally different things. distMgmt is where you want to deploy
to. repositories declare what repos you want to pull artifacts you depend
on.
/Anders
On Tue, Jan 18, 2011 at 09:40, jeb001 <je...@gmail.com> wrote:
>
> Ok, I'll try to precise what I'm saying.
> I understand that in the distrMgt, I have to set snapshot, release and
> eventually site url.. I understood in the log that the deploy task needs
> that tag.
>
> I noticed too that I need another tag in the pom file, a repositories tag.
> I wonder why I have to set twice where are my repositories ?
> Here's my file :
>
>
> <repositories>
> <!-- use the following if you're not using a snapshot version. -->
> <repository>
> <id>repository-releases</id>
> <name>Releases Repository</name>
> <url>
> http://nexus/content/repositories/DNSCEReleases/
> </url>
> <snapshots>
> <enabled>false</enabled>
> </snapshots>
> </repository>
> <repository>
> <id>-repository-snapshots</id>
> <name>Snapshots Repository</name>
> <url>http://nexus/content/repositories/DNSCESnapshots/
> </url>
> <releases>
> <enabled>false</enabled>
> </releases>
> <snapshots>
> <enabled>true</enabled>
> </snapshots>
> </repository>
> </repositories>
>
> <distributionManagement>
> <!-- use the following if you're not using a snapshot version. -->
> <repository>
> <id>repository-releases</id>
> <name>Repository Name</name>
> <url>http://nexus/content/repositories/DNSCESnapshots/</url>
> </repository>
> <!-- use the following if you ARE using a snapshot version. -->
> <snapshotRepository>
> <id>repository-snapshots</id>
> <name>Snapshots Repository</name>
> <url>http://nexus/content/repositories/DNSCESnapshots/</url>
> </snapshotRepository>
> </distributionManagement>
>
>
> Maybe, in the distributionMgt tag, I just have to set the id of the repo
> described upon it ?
>
> Thx
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345810.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
>
>
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Ok, I'll try to precise what I'm saying.
I understand that in the distrMgt, I have to set snapshot, release and
eventually site url.. I understood in the log that the deploy task needs
that tag.
I noticed too that I need another tag in the pom file, a repositories tag.
I wonder why I have to set twice where are my repositories ?
Here's my file :
<repositories>
<!-- use the following if you're not using a snapshot version. -->
<repository>
<id>repository-releases</id>
<name>Releases Repository</name>
<url>
http://nexus/content/repositories/DNSCEReleases/</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>-repository-snapshots</id>
<name>Snapshots Repository</name>
<url>http://nexus/content/repositories/DNSCESnapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<distributionManagement>
<!-- use the following if you're not using a snapshot version. -->
<repository>
<id>repository-releases</id>
<name>Repository Name</name>
<url>http://nexus/content/repositories/DNSCESnapshots/</url>
</repository>
<!-- use the following if you ARE using a snapshot version. -->
<snapshotRepository>
<id>repository-snapshots</id>
<name>Snapshots Repository</name>
<url>http://nexus/content/repositories/DNSCESnapshots/</url>
</snapshotRepository>
</distributionManagement>
Maybe, in the distributionMgt tag, I just have to set the id of the repo
described upon it ?
Thx
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345810.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
Re: Maven release:perform deploy failed access denied
Posted by Anders Hammar <an...@hammar.net>.
Regarding special args for release:peform I don't understand the question.
What args to spec depends on what you want to do. Try it, read/google and
come back when you have a specific question.
Regarding distMagmt you need to spec a snapshot repo if you deloy snapshots
and a (release) repo if you deploy a release (like you do with
release:perform). If you deploya maven site you also need to spec a site url
in distMgmt.
It's three different things. If you have the same id for all of them you
only need to define one set of credentials in settings.xml. However, I
normally have three different ids and duplicate the creds in settings.xml.
/Anders
On Tue, Jan 18, 2011 at 08:14, jeb001 <je...@gmail.com> wrote:
>
> Ok, I guess it's getting a little better... but there's something I'm not
> sure to understand.
>
> First, my project is a multi-module project, should I set special arguments
> when I launch release:perform ?
>
> An then, I wonder what's the differences, in my main pom.xml between the
> tag
> distributionManagement, used by the deploy task, and the other tag
> repositories...
> In the tag repositories, I added 2 tags repository to set my nexus snapshot
> and releases URL.
>
> I don't really know what I have to set in the distributionManagement tag...
> it's like I have to indicate my nexus server twice ?
> I tried to remove thoses tags, but there are mandatory...
>
> Thx for your help,
>
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345723.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
>
>
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Ok, I guess it's getting a little better... but there's something I'm not
sure to understand.
First, my project is a multi-module project, should I set special arguments
when I launch release:perform ?
An then, I wonder what's the differences, in my main pom.xml between the tag
distributionManagement, used by the deploy task, and the other tag
repositories...
In the tag repositories, I added 2 tags repository to set my nexus snapshot
and releases URL.
I don't really know what I have to set in the distributionManagement tag...
it's like I have to indicate my nexus server twice ?
I tried to remove thoses tags, but there are mandatory...
Thx for your help,
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3345723.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
Re: Maven release:perform deploy failed access denied
Posted by Anders Hammar <an...@hammar.net>.
Go talk to your Nexus admins?
/Anders
On Fri, Jan 14, 2011 at 08:15, jeb001 <je...@gmail.com> wrote:
>
> Hum... no other suggestions ?
>
>
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3340910.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
>
>
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Hum... no other suggestions ?
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3340910.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
Re: Maven release:perform deploy failed access denied
Posted by Anders Hammar <an...@hammar.net>.
Nope. You need either os access or ui/rest access.
/Anders
On Thu, Jan 13, 2011 at 13:45, jeb001 <je...@gmail.com> wrote:
>
> Hum, ok... but, I'm using a distant nexus server.. I'm not administrator...
> Is there a way for me to see those logs ?
>
> thx
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3339723.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
>
>
Re: Maven release:perform deploy failed access denied
Posted by jeb001 <je...@gmail.com>.
Hum, ok... but, I'm using a distant nexus server.. I'm not administrator...
Is there a way for me to see those logs ?
thx
--
View this message in context: http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3339723.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
Re: Maven release:perform deploy failed access denied
Posted by Anders Hammar <an...@hammar.net>.
You don't have access?
I suggest you have a look in the Nexus logs. It will tell you what it
doesn't like with your credentials.
/Anders
On Thu, Jan 13, 2011 at 10:54, jeb001 <je...@gmail.com> wrote:
>
> Hi,
>
>
> I'm trying to build my first release of my multi-modules projects.
> In my settings.xml :
>
> <server>
> <id>my-releases</id>
> <username>deployer</username>
> <password>123</password>
> </server>
>
> in my main pom.xml :
>
> <distributionManagement>
> <repository>
> <id>my-releases</id>
> <name>Repository Nexus</name>
> <url>
> http://serverIp/nexus/content/groups/MyRepositories/</url>
> </repository>
>
>
> </distributionManagement>
>
> Unfortunately, I've got this error :
>
> INFO] [INFO] [deploy:deploy {execution: default-deploy}]
> [INFO] Uploading:
>
> http://serverIp/nexus/content/groups/MyRepositories//com/project/Parent/0.0.5/Parent-0.0.5.pom
> [INFO] [INFO]
> ------------------------------------------------------------------------
> [INFO] [ERROR] BUILD ERROR
> [INFO] [INFO]
> ------------------------------------------------------------------------
> [INFO] [INFO] Error deploying artifact: Authorization failed: Access denied
> to:
>
> http://serverIp/nexus/content/groups/MyRepositories/com/project/Parent/0.0.5/Parent-0.0.5.pom
> [INFO]
> [INFO] [INFO]
> ------------------------------------------------------------------------
> [INFO] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Maven execution
> failed, exit code: '1'
> at
>
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
> at
>
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
> at
>
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
> at
>
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
> at
>
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
> at
>
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
> at
> org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>
>
>
>
> .... what's wrong ??
>
> Thx !
>
> --
> View this message in context:
> http://maven.40175.n5.nabble.com/Maven-release-perform-deploy-failed-access-denied-tp3339497p3339497.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
>
>