Not able to release new version of plugin

795 views
Skip to first unread message

Irfan Sayed

unread,
Jan 5, 2017, 8:49:48 AM1/5/17
to jenkin...@googlegroups.com
Hi,
I need to release new version of plugin.
when i am executing command : mvn release:perform 
getting following error:


[INFO]
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] BUILD FAILURE
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] Total time: 01:07 min
[INFO] [INFO] Finished at: 2017-01-05T05:43:23-08:00
[INFO] [INFO] Final Memory: 62M/585M
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy (default-deploy) on project sinatra-chef-builder: Failed to deploy artifacts: Could not transfer a
rtifact org.jenkins-ci.plugins:sinatra-chef-builder:hpi:1.4 from/to maven.jenkins-ci.org (http://maven.jenkins-ci.org:8081/content/repositories/releases): Connect to maven.jenkins-ci.org:8081 
[maven.jenkins-ci.org/199.193.196.24] failed: Connection timed out: connect -> [Help 1]
[INFO] [ERROR]
[INFO] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[INFO] [ERROR] Re-run Maven using the -X switch to enable full debug logging.
[INFO] [ERROR]
[INFO] [ERROR] For more information about the errors and possible solutions, please read the following articles:
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:22 min
[INFO] Finished at: 2017-01-05T05:43:23-08:00
[INFO] Final Memory: 17M/222M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.5:perform (default-cli) on project sinatra-chef-builder: Maven execution failed, exit code: '1' -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[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 read the following articles:


Can someone please suggest ? 

Regards,


Daniel Beck

unread,
Jan 5, 2017, 8:57:39 AM1/5/17
to jenkin...@googlegroups.com

> On 05.01.2017, at 14:49, Irfan Sayed <irfu....@gmail.com> wrote:
>
> it seems that URL : http://maven.jenkins-ci.org:8081/content/repositories/releases is not working.
> Can someone please suggest ?

Second item at https://wiki.jenkins-ci.org/display/JENKINS/Hosting+Plugins#HostingPlugins-Workingaroundcommonissues

Irfan Sayed

unread,
Jan 5, 2017, 9:02:05 AM1/5/17
to jenkin...@googlegroups.com
Thanks Daniel.
In my plugins POM, i have already this:

 <repositories>
    <repository>
      <id>repo.jenkins-ci.org</id>
    </repository>
  </repositories>
  <pluginRepositories>
    <pluginRepository>
      <id>repo.jenkins-ci.org</id>
    </pluginRepository>
  </pluginRepositories>

is this not correct ?
Regards,



--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/BAD647E8-726F-43FA-BCE0-2153E08E0E82%40beckweb.net.
For more options, visit https://groups.google.com/d/optout.

Daniel Beck

unread,
Jan 5, 2017, 9:03:24 AM1/5/17
to jenkin...@googlegroups.com

> On 05.01.2017, at 15:02, Irfan Sayed <irfu....@gmail.com> wrote:
>
> In my plugins POM, i have already this:

What about distributionManagement?

Irfan Sayed

unread,
Jan 5, 2017, 9:15:44 AM1/5/17
to jenkin...@googlegroups.com
Thanks Daniel.
i added following in plugin POM:

<distributionManagement>
    <repository>
      <id>java.net-m2-repository</id>
    </repository>
  </distributionManagement>

still the same error. i am not getting from where it is picking up that url and port number.
in my settings.xml as well this URL is not there

Regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Oliver Gondža

unread,
Jan 5, 2017, 9:17:48 AM1/5/17
to jenkin...@googlegroups.com
On 2017-01-05 15:15, Irfan Sayed wrote:
> Thanks Daniel.
> i added following in plugin POM:
>
> <distributionManagement>
> <repository>
> <id>java.net-m2-repository</id>
> <url>http://maven.jenkins-ci.org/content/repositories/releases/</url>
> </repository>
> </distributionManagement>
>
> still the same error. i am not getting from where it is picking up that
> url and port number.
> in my settings.xml as well this URL is not there

Have a look at effective pom to see where the url is coming from.

--
oliver

Daniel Beck

unread,
Jan 5, 2017, 9:47:05 AM1/5/17
to jenkin...@googlegroups.com

> On 05.01.2017, at 15:15, Irfan Sayed <irfu....@gmail.com> wrote:
>
> still the same error

Unsurprising given that this still referenced the host name that has been shut down.

Irfan Sayed

unread,
Jan 6, 2017, 2:37:18 AM1/6/17
to jenkin...@googlegroups.com
Thanks.
In the effective POM, i have following:

 <distributionManagement>
    <repository>
      <id>java.net-m2-repository</id>
    </repository>
    <snapshotRepository>
      <id>maven.jenkins-ci.org</id>
    </snapshotRepository>
    <site>
      <id>github-pages</id>
    </site>
  </distributionManagement>

in snapshot repository, there is a port 8081 
but in release repo it is not.
please let me know

regards,



--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Baptiste Mathus

unread,
Jan 6, 2017, 3:06:53 AM1/6/17
to Jenkins Developers
Upgrade to the 2.x version of the parent pom + remove the distributionManagement tag from your pom.


(Note : unrelated to upgrading to 2.x core baseline) 

Cheers

Oliver Gondža

unread,
Jan 6, 2017, 3:38:44 AM1/6/17
to jenkin...@googlegroups.com
On 2017-01-06 08:37, Irfan Sayed wrote:
> Thanks.
> In the effective POM, i have following:
>
> <distributionManagement>
> <repository>
> <id>java.net-m2-repository</id>
> <url>http://maven.jenkins-ci.org/content/repositories/releases/</url>
> </repository>
> <snapshotRepository>
> <id>maven.jenkins-ci.org <http://maven.jenkins-ci.org></id>
> <http://gitsite:g...@github.com/jenkinsci/maven-site.git:plugin-parent/sinatra-chef-builder></url>
> </site>
> </distributionManagement>
>
> in snapshot repository, there is a port 8081
> but in release repo it is not.
> please let me know

maven.jenkins-ci.org was discontinued, repo.jenkins-ci.org is the
replacement. As long as the old hostname is coming up in effective pom,
your pom is not configured correctly.

This is annoying as hell, no question about that, but the easiest way to
go here is to update the plugin-pom.

--
oliver

Irfan Sayed

unread,
Jan 6, 2017, 5:56:06 AM1/6/17
to jenkin...@googlegroups.com
Thanks.

any specific wiki to refer how to upgrade the version of Parent POM to 2.x ?
I have removed the DistributionManagement entry from my plugin POM.

Regards,










--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Baptiste Mathus

unread,
Jan 6, 2017, 6:31:27 AM1/6/17
to Jenkins Developers
Irfan, seems like my mail went through looking at the archive. So please read it, and click on the link...

We are spending time trying to help, so please at least read the link we provide.

Thank you

Irfan Sayed

unread,
Jan 6, 2017, 8:26:25 AM1/6/17
to jenkin...@googlegroups.com
Sorry. actually i was confused. i red again and i guess i have to make following changes and did that.
I made these changes in my plugin POM

<parent>
    <groupId>org.jenkins-ci.plugins</groupId>
    <artifactId>plugin</artifactId>
    <version>2.3</version> <!-- or later -->
  </parent>

  <properties>
    <jenkins.version>1.609.1</jenkins.version>
    <hpi-plugin.version>1.106</hpi-plugin.version>
  </properties>

is this seems correct now?
but in the Plugin.POM file , i got following entries :

 <distributionManagement>
    <repository>
      <uniqueVersion>false</uniqueVersion>
      <id>maven.jenkins-ci.org</id>
    </repository>
    <snapshotRepository>
      <id>maven.jenkins-ci.org</id>
    </snapshotRepository>
  </distributionManagement>

i am not getting what is wrong. please help
Regards,





Daniel Beck

unread,
Jan 6, 2017, 8:30:23 AM1/6/17
to jenkin...@googlegroups.com

> On 06.01.2017, at 14:26, Irfan Sayed <irfu....@gmail.com> wrote:
>
> <version>2.3</version> <!-- or later -->
>

The first response you got linked to:
https://wiki.jenkins-ci.org/display/JENKINS/Hosting+Plugins#HostingPlugins-Workingaroundcommonissues

And it says:

> … or update to the parent plugins POM 2.5 or newer

2.3 is not newer than 2.5.

Irfan Sayed

unread,
Jan 6, 2017, 9:08:11 AM1/6/17
to jenkin...@googlegroups.com
I changed the version from 2.3 to 2.5 , but still it refers to old repo.
then i again changed to more updated version of plugin POM : 2.11 , still the same issue...
in the effective POM, there is no entry with 8081 port 

i have checked the .m2/settings.xml file as well, there is also not any old repo.

i have deleted all the contents of local maven repo (just in case) and tried again.

I am still not getting what is wrong ?

regards,




--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Baptiste Mathus

unread,
Jan 6, 2017, 10:57:47 AM1/6/17
to Jenkins Developers
Can you create a branch or a PR against your repo so that we check actual code/thing?

Also, did you *remove* the distributionManagement part from your pom as I said?

Irfan Sayed

unread,
Jan 7, 2017, 11:43:14 AM1/7/17
to jenkin...@googlegroups.com
Thanks.
Yes. I did remove the DistributionManagement from my POM.
Please refer here actual code. This is the latest code which i would like to release 

Regards,


Baptiste Mathus

unread,
Jan 7, 2017, 4:15:24 PM1/7/17
to Jenkins Developers
Your current pom.xml is not even valid from a Maven PoV. You commented out the artifactId for one.
So I don't know what you're testing right now, but no, this is not what is on your repo because that immediately fails with Maven. 

Please file a PR with what you really have. For me, once this is removed this seems fine. Or maybe you have crap left somehow in your settings.xml.

Irfan Sayed

unread,
Jan 8, 2017, 3:57:10 AM1/8/17
to jenkin...@googlegroups.com
Sorry. while experimenting, that modification left as it is. i fixed that and uploaded new version. please have a look
further , please find the attached settings.xml as well

Regards,


settings.xml

Irfan Sayed

unread,
Jan 9, 2017, 1:39:01 AM1/9/17
to jenkin...@googlegroups.com
Hi Baptiste,
I tried creating settings.xml and try to perform the release. still the issue persist.
Effective POM also looks OK.

 <distributionManagement>
    <repository>
      <id>maven.jenkins-ci.org</id>
    </repository>
    <snapshotRepository>
      <id>maven.jenkins-ci.org</id>
    </snapshotRepository>
  </distributionManagement>

Regards,
Irfan


Irfan Sayed

unread,
Jan 9, 2017, 11:44:05 AM1/9/17
to jenkin...@googlegroups.com
Hi Baptiste,
Can you please help

Regards,
Irfan

Baptiste Mathus

unread,
Jan 9, 2017, 2:28:45 PM1/9/17
to Jenkins Developers
You're not helpable this way. Please describe what you did, and put the necessary data in gist.github.com or something. Like the error you're having. Is this really still the same error? 
You probably have something wrong locally or so you didn't push, because right now your pom.xml seems correct. At least can't see any ref to the old maven repo;

Irfan Sayed

unread,
Jan 10, 2017, 1:27:31 AM1/10/17
to jenkin...@googlegroups.com
Thanks Baptiste.
I have created public gist and uploaded all data there.


please have a look.

Regards,
irfan


Irfan Sayed

unread,
Jan 11, 2017, 6:44:47 AM1/11/17
to jenkin...@googlegroups.com
Hi,
The issue of having wrong URL in the maven release preparation is now resolved. i am getting correct URL.
however, now "401 unauthorized" error is coming 
i have uploaded correct public key in the github and able to push the code properly.

do i need to do any another setting to get rid of "unauthorized" error ?
Please suggest 

regards,

Irfan Sayed

unread,
Jan 11, 2017, 11:34:15 AM1/11/17
to jenkin...@googlegroups.com
Hi Baptiste,
Can you please suggest ?
i am able to push the changes using my username and using pass-wordless authentication 
not getting why "unauthorized" error is coming. i verified settings.xml as well 

regards,

Daniel Beck

unread,
Jan 11, 2017, 11:37:08 AM1/11/17
to jenkin...@googlegroups.com

> On 11.01.2017, at 17:34, Irfan Sayed <irfu....@gmail.com> wrote:
>
> not getting why "unauthorized" error is coming

Have you looked into all of the suggestions in the 12th note at https://wiki.jenkins-ci.org/display/JENKINS/Hosting+Plugins#HostingPlugins-Workingaroundcommonissues ?

Irfan Sayed

unread,
Jan 11, 2017, 11:56:54 AM1/11/17
to jenkin...@googlegroups.com
Thanks.
Let me thoroughly have a look and update

Regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Irfan Sayed

unread,
Jan 12, 2017, 2:17:41 AM1/12/17
to jenkin...@googlegroups.com
Hi,
I have created the PR request : 

Can you please review the same ?
i made changes directly into master branch. so i guess no need to merge anything.

I understand that i dont have plugin release upload permission.

i followed the below link:

and verified that YAML file exist for my plugin with correct content.
please let me know if i need to request anything more so that i can upload new release

Regards,

Irfan Sayed

unread,
Jan 12, 2017, 9:47:46 PM1/12/17
to jenkin...@googlegroups.com
Hi,
Please suggest...
i tried passing username and password as well in the maven release command but no luck

Regards,

Irfan Sayed

unread,
Jan 13, 2017, 2:15:04 AM1/13/17
to jenkin...@googlegroups.com
further update:
i started ssh-agent and imported the private key of the github account. my github account and jenkins-ci account is same.
aftrer that, added username and password in the ~/.m2/settings.xml file and run the command:
"mvn release:prepare release:perform"

still the same issue : "401 unauthorized"

Regards,

Irfan Sayed

unread,
Jan 13, 2017, 2:25:10 AM1/13/17
to jenkin...@googlegroups.com
As i am troubleshooting further, just wanted to confirm, if my ID : "irfanjs" has valid deploy artifact/release plugin permission to jenkins-ci org?
Hi Baptiste/Daniel, 
Can i Request you to please have a look on the same. 

Regards,

Irfan Sayed

unread,
Jan 13, 2017, 4:45:42 AM1/13/17
to jenkin...@googlegroups.com
Further update:
I got the Encrypted password of my account and put it in the settings.xml as well.

here is the snippet from settings.xml:

<servers>
    <server>
      <id>java.net-m2-repository</id> <!-- For parent 1.397 or newer; before this use id java.net-m2-repository -->
      <username>irfanjs</username>
      <password>$encryptedpassword</password>
    </server>
  </servers>

still it throws the unauthorized error.
can someone please provide me the access to release plugin ?
regards,



Irfan Sayed

unread,
Jan 13, 2017, 10:19:56 AM1/13/17
to jenkin...@googlegroups.com
hi,
can someone please help.
I am stuck totally.

regards,

Slide

unread,
Jan 13, 2017, 10:47:01 AM1/13/17
to jenkin...@googlegroups.com
This is a pretty long thread, would it be possible for you to sum up where you are currently stuck, what you have tried and so forth?

To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CACGLCJb-iR9LRoDpCGcwACSakU-MMkOrX5QpQGpe-9uUkAQBpQ%40mail.gmail.com.

Irfan Sayed

unread,
Jan 13, 2017, 11:30:00 AM1/13/17
to jenkin...@googlegroups.com
Sure Thanks 
Let me explain:

My current development environment:
1: windows box 
2: eclipse MARs release
3: java 1.8
4: maven version: 3.3.9
5: fixed all the findbugs issues

plugin details:
Chef sinatra jenkins plugin:
current version: 1.3

Release process:
this is the first time i am uploading the new version of my plugin
Installed git bash 
my github account and jenkins account is same
created the public/private key pair 
uploaded the public key to the github.

troubleshooting steps i did:
i followed most instruction in the URL: https://wiki.jenkins-ci.org/display/JENKINS/Hosting+Plugins

1: hard-coded username and password in the settings section in settings.xml 
2: pass the username/password in the mvn release command
3: able to push the latest changes in the github without asking for password
4: run the command mvn help:effective-settings to get the effective settings to check the distributionManagement tag. it seems OK
5: my plugin POM is updated with Jenkins parent plugin POM : https://github.com/jenkinsci/plugin-pom
6: effective POM is also seems OK 
7:get the encrypted password from the repo.jenkins-ci.org and paste in the settings.xml instead of plain text password.
8: created the PR request for the review

actual commands :
git add pom.xml src
git commit -m "new version" 
git push origin master

final release command: 
mvn release:prepare release:perform

i am getting "401 unauthorized error"
please suggest

Regards,
 





To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CAPiUgVf5NzjAnMDxVgwFRSxrqn8oTtcxTiLMhcr5rXfEzLtnNQ%40mail.gmail.com.

Slide

unread,
Jan 13, 2017, 12:46:50 PM1/13/17
to jenkin...@googlegroups.com
One question, why are you overriding the hpi plugin version? https://github.com/jenkinsci/sinatra-chef-builder-plugin/blob/master/pom.xml#L15

Also, it looks like the git scm info in the pom.xml is for an old repo link? 

To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CACGLCJbbu1TS5%2B-ZGMWFJTu5N_TzOx1S%3DwMa46%2B%2B9USFMYAXfg%40mail.gmail.com.

Irfan Sayed

unread,
Jan 13, 2017, 12:52:25 PM1/13/17
to jenkin...@googlegroups.com
Thanks Slide.
Can you please tell me what should be the hpi plugin version in POM.xml? i will make necessary change and commit.
further, git scm info is the same which i kept when i released the initial version. can you please tell me then what should be the correct link?

please let me know
Regards,


To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CAPiUgVfMDLYiswKyP%3D9yHuQLHts9Cn%2B5AbgFJwuiOJUxq0YvBg%40mail.gmail.com.

Slide

unread,
Jan 13, 2017, 1:27:50 PM1/13/17
to jenkin...@googlegroups.com

You shouldn't need to specify an hpi plugin version at all, it will be handled in the parent pom. When I click on the repo you have in your previous email it takes me to a different name.


To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CACGLCJYr4kxHR%3De5Z%2B36UMZ1BDf3%2Bw%3DPgZWhocg5VfWH%3DgGk1w%40mail.gmail.com.

Irfan Sayed

unread,
Jan 13, 2017, 1:38:44 PM1/13/17
to jenkin...@googlegroups.com
Ok. thanks.
Let me remove below line and commit.
<hpi-plugin.version>1.106</hpi-plugin.version>

so you mean, the curent scm section look OK?
should i mention any username and password in the settings.xml?
is mvn release:prepare release:perform command is enough?

regards,




To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CAPiUgVfyKti_dOOdyDsAAH%3D6ZbAJV1PN_WpSoEsn4DtKLLiawA%40mail.gmail.com.

Irfan Sayed

unread,
Jan 13, 2017, 2:07:26 PM1/13/17
to jenkin...@googlegroups.com
Made the changes and committed.
command used: mvn release:prepare release:perform
still the same issue: "401 unauthorized"

regards,
 

Slide

unread,
Jan 13, 2017, 2:11:03 PM1/13/17
to jenkin...@googlegroups.com
Well, the SCM section doesn't match with the repo url:

https://github.com/jenkinsci/sinatra-chef-builder-plugin is the repo URL, but the scm section has


<connection>scm:git:git://github.com/jenkinsci/chefbuilder-plugin.git</connection>

<developerConnection>scm:git:ssh://g...@github.com/jenkinsci/chefbuilder-plugin.git</developerConnection>
<url>http://github.com/jenkinsci/chefbuilder-plugin</url>
<tag>HEAD</tag>

The URL's clearly don't match.


The SCM section for the token-macro-plugin that I maintain is like this:


<connection>scm:git:git://github.com/jenkinsci/token-macro-plugin.git</connection>
<developerConnection>scm:git:g...@github.com:jenkinsci/token-macro-plugin.git</developerConnection>
<tag>HEAD</tag>

Can you post a build log of the current runs after the changes?

To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CACGLCJY1ikyPqcKtSW0c-ig%2BrOrpN1MF8j6aLCdemQWDhhbS6A%40mail.gmail.com.

Irfan Sayed

unread,
Jan 13, 2017, 2:55:37 PM1/13/17
to jenkin...@googlegroups.com
made the scm section changes and committed.
here is the build output log:

ef-builder ---
    [INFO] Installing C:\sinatra-chef-builder-plugin\target\sinatra-chef-builder                                                               .hpi to C:\Users\irfanjs\.m2\repository\org\jenkins-ci\plugins\sinatra-chef-buil                                                               der\1.10\sinatra-chef-builder-1.10.hpi
    [INFO] Installing C:\sinatra-chef-builder-plugin\pom.xml to C:\Users\irfanjs                                                               \.m2\repository\org\jenkins-ci\plugins\sinatra-chef-builder\1.10\sinatra-chef-bu                                                               ilder-1.10.pom
    [INFO] Installing C:\sinatra-chef-builder-plugin\target\sinatra-chef-builder                                                               .jar to C:\Users\irfanjs\.m2\repository\org\jenkins-ci\plugins\sinatra-chef-buil                                                               der\1.10\sinatra-chef-builder-1.10.jar
    [INFO] ---------------------------------------------------------------------                                                               ---
    [INFO] BUILD SUCCESS
    [INFO] ---------------------------------------------------------------------                                                               ---
    [INFO] Total time: 02:35 min
    [INFO] Finished at: 2017-01-13T11:36:47-08:00
    [INFO] Final Memory: 62M/167M
    [INFO] ---------------------------------------------------------------------                                                               ---
[INFO] Checking in modified POMs...
[INFO] Executing: cmd.exe /X /C "git add -- pom.xml"
[INFO] Working directory: C:\sinatra-chef-builder-plugin
[INFO] Executing: cmd.exe /X /C "git rev-parse --show-toplevel"
[INFO] Working directory: C:\sinatra-chef-builder-plugin
[INFO] Executing: cmd.exe /X /C "git status --porcelain ."
[INFO] Working directory: C:\sinatra-chef-builder-plugin
[WARNING] Ignoring unrecognized line: ?? pom.xml.releaseBackup
[WARNING] Ignoring unrecognized line: ?? release.properties
[WARNING] Ignoring unrecognized line: ?? target/
[INFO] Executing: cmd.exe /X /C "git commit --verbose -F C:\Users\irfanjs\AppDat                                                               a\Local\Temp\maven-scm-1195565814.commit pom.xml"
[INFO] Working directory: C:\sinatra-chef-builder-plugin
[INFO] Executing: cmd.exe /X /C "git symbolic-ref HEAD"
[INFO] Working directory: C:\sinatra-chef-builder-plugin
[INFO] Executing: cmd.exe /X /C "git push g...@github.com/jenkinsci/sinatra-chef-                                                               builder-plugin.git refs/heads/master:refs/heads/master"
[INFO] Working directory: C:\sinatra-chef-builder-plugin
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 03:37 min
[INFO] Finished at: 2017-01-13T11:36:48-08:00
[INFO] Final Memory: 16M/39M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.5                                                               .3:prepare (default-cli) on project sinatra-chef-builder: Unable to commit files
[ERROR] Provider message:
[ERROR] The git-push command failed.
[ERROR] Command output:
[ERROR] fatal: 'g...@github.com/jenkinsci/sinatra-chef-builder-plugin.git' does n                                                               ot appear to be a git repository
[ERROR] fatal: Could not read from remote repository.
[ERROR]
[ERROR] Please make sure you have the correct access rights
[ERROR] and the repository exists.
[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/MojoFailureExc                                                               eption

irfanjs@host-10 MINGW64 /c/sinatra-chef-builder-plugin (master)
$

regards,


To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CAPiUgVfSQEYwp%2Brp4_8hU022zwkth9iOuoVcrHj3YqHaxr4vBQ%40mail.gmail.com.

Irfan Sayed

unread,
Jan 13, 2017, 3:30:49 PM1/13/17
to jenkin...@googlegroups.com
fixed the small typo in the scm section and commited

fired the release command again:
here is the output:
   [INFO] --- maven-deploy-plugin:2.8.2:deploy (default-deploy) @ sinatra-chef-                                                               builder ---
    Uploading: https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/sinat                                                               ra-chef-builder/1.10/sinatra-chef-builder-1.10.hpi
    Uploading: https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/sinat                                                               ra-chef-builder/1.10/sinatra-chef-builder-1.10.pom
    [INFO] ---------------------------------------------------------------------                                                               ---
    [INFO] BUILD FAILURE
    [INFO] ---------------------------------------------------------------------                                                               ---
    [INFO] Total time: 01:47 min
    [INFO] Finished at: 2017-01-13T12:21:50-08:00
    [INFO] Final Memory: 59M/207M
    [INFO] ---------------------------------------------------------------------                                                               ---
    [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:                                                               2.8.2:deploy (default-deploy) on project sinatra-chef-builder: Failed to deploy                                                                artifacts: Could not transfer artifact org.jenkins-ci.plugins:sinatra-chef-build                                                               er:hpi:1.10 from/to maven.jenkins-ci.org (https://repo.jenkins-ci.org/releases/)                                                               : Failed to transfer file: https://repo.jenkins-ci.org/releases/org/jenkins-ci/p                                                               lugins/sinatra-chef-builder/1.10/sinatra-chef-builder-1.10.hpi. Return code is:                                                                401, ReasonPhrase: Unauthorized. -> [Help 1]
    [ERROR]
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e                                                                switch.
    [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                                                                read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecut                                                               ionException
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 06:44 min
[INFO] Finished at: 2017-01-13T12:21:51-08:00
[INFO] Final Memory: 16M/39M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.5                                                               .3:perform (default-cli) on project sinatra-chef-builder: Maven execution failed                                                               , exit code: '1' -> [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:

<developerConnection>scm:git:gi...@github.com:jenkinsci/token-macro-plugin.git</developerConnection>
<tag>HEAD</tag>

...

[Message clipped]  

Irfan Sayed

unread,
Jan 13, 2017, 4:20:23 PM1/13/17
to jenkin...@googlegroups.com
hi,
can you please suggest.

regards

Slide

unread,
Jan 13, 2017, 5:18:50 PM1/13/17
to jenkin...@googlegroups.com
From the same console, can you do something like this:

Slide

unread,
Jan 13, 2017, 5:29:42 PM1/13/17
to jenkin...@googlegroups.com

Oh, I missed your message about the typo before I hit send. Are you able to login to https://accounts.jenkins.io/login?from=%2Fmyself%2F with the username/password combo that you have in your settings.xml?

Irfan Sayed

unread,
Jan 14, 2017, 3:59:57 AM1/14/17
to jenkin...@googlegroups.com
Yes . i am able to login to : https://accounts.jenkins.io/login?from=%2Fmyself%2F
i uploaded public key as well on above link and tried again releasing.
but still the same error

Regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Baptiste Mathus

unread,
Jan 14, 2017, 4:46:38 AM1/14/17
to Jenkins Developers
Also, quick tip: you can stop trying to release, but only do "mvn deploy" to see if you can deploy snapshots, because this is the thing that is failing for you. Github pushes seem to work, only artifacts have an in issue IIUC.

<developerConnection>scm:git:gi...@github.com:jenkinsci/token-macro-plugin.git</developerConnection>
<tag>HEAD</tag>

...

Irfan Sayed

unread,
Jan 14, 2017, 7:52:58 AM1/14/17
to jenkin...@googlegroups.com
OK. i made the POM changes in my plugin and added following:
<distributionManagement>
   <snapshotRepository>
       <id>propSnap</id>
    
    </snapshotRepository>
    <repository>
         <id>propRel</id>
         <url>https://repo.jenkins-ci.org/releases</url>
        </repository>
  </distributionManagement>

run the same command: mvn clean package deploy
same error : "401 unauthorized"

regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Slide

unread,
Jan 14, 2017, 8:45:06 AM1/14/17
to jenkin...@googlegroups.com

If your version has SNAPSHOT in it, you don't need to add anything. Snapshots are automatically deployed to the correct place I believe.


<developerConnection>scm:git:g...@github.com:jenkinsci/token-macro-plugin.git</developerConnection>
<tag>HEAD</tag>

Irfan Sayed

unread,
Jan 14, 2017, 8:55:47 AM1/14/17
to jenkin...@googlegroups.com
Yes i do have SNAPSHOT version in the POM. 
mvn deploy command also failing with the same error ..
i am still not getting what is the issue 

regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Irfan Sayed

unread,
Jan 14, 2017, 9:09:13 AM1/14/17
to jenkin...@googlegroups.com
When i requested initially for hosting plugin in jenkins-ci org, following was the original discussion:

we had changed the JIRA component and plugin name to align the proper artifactID and all.
is this issue due to this ?

Regards,


<developerConnection>scm:git:gi...@github.com:jenkinsci/token-macro-plugin.git</developerConnection>
<tag>HEAD</tag>

Slide

unread,
Jan 14, 2017, 11:34:34 AM1/14/17
to jenkin...@googlegroups.com

I've been wondering the same thing but I am not sure. I wonder if there is any sort of log on the server that someone with those privileges could look at. I'm out of ideas sadly.


<developerConnection>scm:git:g...@github.com:jenkinsci/token-macro-plugin.git</developerConnection>
<tag>HEAD</tag>

Can you post a build log of the current runs after the changes?

Irfan Sayed

unread,
Jan 14, 2017, 11:37:29 AM1/14/17
to jenkin...@googlegroups.com
Thanks Slide.
anyone has any other suggestions/workaround  ? 
if this is not resolved, how will i be able to release my plugin ?

regards,




--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Slide

unread,
Jan 14, 2017, 11:42:55 AM1/14/17
to jenkin...@googlegroups.com

One thing to try would be to add another user to the upload permissions app and see if they can do a snapshot release.

Irfan Sayed

unread,
Jan 14, 2017, 11:56:16 AM1/14/17
to jenkin...@googlegroups.com
OK. Thanks
can you please give me those steps ?
May i request to take that please?

regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Christopher Orr

unread,
Jan 14, 2017, 12:39:29 PM1/14/17
to jenkin...@googlegroups.com
Since last month, no special permissions are needed to upload SNAPSHOTs:
https://groups.google.com/d/msgid/jenkinsci-dev/53CC6ED4-3BBC-4FAD-A197-10AD7F922A34%40beckweb.net

The permissions look correct here, and match the groupId and artifactId
from your logs, plus you said that you've logged into Artifactory, so
that should be fine:
https://github.com/jenkins-infra/repository-permissions-updater/blob/176a269/permissions/plugin-sinatra-chef-builder.yml

So since the permissions look ok (and aren't needed for SNAPSHOTs
anyway), and you've managed to log in to the Jenkins account app and
Artifactory, I would guess that's something is wrong with your Maven
security config.
But I don't know much about this stuff — maybe you've defined your
id/password in multiple places, or perhaps Maven shows where it's
reading the credentials from if you use --debug?

Regards,
Chris
> <mailto:slide...@gmail.com>> wrote:
>
> If your version has SNAPSHOT in it, you don't
> need to add anything. Snapshots are
> automatically deployed to the correct place I
> believe.
>
>
> On Sat, Jan 14, 2017, 05:52 Irfan Sayed
> <irfu....@gmail.com
> <mailto:irfu....@gmail.com>> wrote:
>
> OK. i made the POM changes in my plugin and
> added following:
> <distributionManagement>
> <snapshotRepository>
> <id>propSnap</id>
>
> <url>https://repo.jenkins-ci.org/snapshots
> <https://repo.jenkins-ci.org/snapshots></url>
>
> </snapshotRepository>
> <repository>
> <id>propRel</id>
>
> <url>https://repo.jenkins-ci.org/releases
> <https://repo.jenkins-ci.org/releases></url>
> </repository>
> </distributionManagement>
>
> run the same command: mvn clean package deploy
> same error : "401 unauthorized"
>
> regards,
>
>
> On Sat, Jan 14, 2017 at 1:46 AM, Baptiste
> Mathus <m...@batmat.net
> <mailto:m...@batmat.net>> wrote:
>
> Also, quick tip: you can stop trying to
> release, but only do "mvn deploy" to see
> if you can deploy snapshots, because
> this is the thing that is failing for
> you. Github pushes seem to work, only
> artifacts have an in issue IIUC.
>
> Le 14 janv. 2017 9:59 AM, "Irfan Sayed"
> <irfu....@gmail.com
> <mailto:irfu....@gmail.com>> a écrit :
>
> Yes . i am able to login to
> : https://accounts.jenkins.io/login?from=%2Fmyself%2F
> <https://accounts.jenkins.io/login?from=%2Fmyself%2F>
> i uploaded public key as well on
> above link and tried again releasing.
> but still the same error
>
> Regards,
>
>
> On Sat, Jan 14, 2017 at 3:59 AM,
> Slide <slide...@gmail.com
> <mailto:slide...@gmail.com>> wrote:
>
> Oh, I missed your message about
> the typo before I hit send. Are
> you able to login to
> https://accounts.jenkins.io/login?from=%2Fmyself%2F
> <https://accounts.jenkins.io/login?from=%2Fmyself%2F>
> with the username/password combo
> that you have in your settings.xml?
>
>
> On Fri, Jan 13, 2017, 15:17
> Slide <slide...@gmail.com
> <mailto:slide...@gmail.com>>
> wrote:
>
> From the same console, can
> you do something like this:
>
>
> https://help.github.com/articles/testing-your-ssh-connection/
> <https://help.github.com/articles/testing-your-ssh-connection/>
>
>
> On Fri, Jan 13, 2017 at
> 12:55 PM Irfan Sayed
> <irfu....@gmail.com
> <mailto:irfu....@gmail.com>>
> <http://g...@github.com/jenkinsci/sinatra-chef->
> <http://g...@github.com/jenkinsci/sinatra-chef-builder-plugin.git>'
> <mailto:slide...@gmail.com>>
> wrote:
>
> Well, the SCM
> section doesn't
> match with the repo url:
>
> https://github.com/jenkinsci/sinatra-chef-builder-plugin
> <https://github.com/jenkinsci/sinatra-chef-builder-plugin> is
> the repo URL, but
> the scm section has
>
>
> <connection>scm:git:git://github.com/jenkinsci/chefbuilder-plugin.git <http://github.com/jenkinsci/chefbuilder-plugin.git></connection>
>
>
> <developerConnection>scm:git:ssh://g...@github.com/jenkinsci/chefbuilder-plugin.git <http://g...@github.com/jenkinsci/chefbuilder-plugin.git></developerConnection>
> <url>http://github.com/jenkinsci/chefbuilder-plugin <http://github.com/jenkinsci/chefbuilder-plugin></url>
> <tag>HEAD</tag>
>
>
>
> The URL's clearly
> don't match.
>
>
> The SCM section for
> the
> token-macro-plugin
> that I maintain is
> like this:
>
>
> <connection>scm:git:git://github.com/jenkinsci/token-macro-plugin.git <http://github.com/jenkinsci/token-macro-plugin.git></connection>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Jenkins Developers" group.
> To unsubscribe from this group and stop receiving emails from it,
> send an email to jenkinsci-de...@googlegroups.com
> <mailto:jenkinsci-de...@googlegroups.com>.
> <https://groups.google.com/d/msgid/jenkinsci-dev/CAPiUgVdkKw5xgPsQtDL8CvVVNArh_Xizgj%2BAGh4qvzthydrdAA%40mail.gmail.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout
> <https://groups.google.com/d/optout>.
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Jenkins Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to jenkinsci-de...@googlegroups.com
> <mailto:jenkinsci-de...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-dev/CACGLCJZq0D5cKpDRk7mLp_orgrPiUakYhRCR%3DgGo2e5TTxrd8w%40mail.gmail.com
> <https://groups.google.com/d/msgid/jenkinsci-dev/CACGLCJZq0D5cKpDRk7mLp_orgrPiUakYhRCR%3DgGo2e5TTxrd8w%40mail.gmail.com?utm_medium=email&utm_source=footer>.

Daniel Beck

unread,
Jan 14, 2017, 8:50:05 PM1/14/17
to jenkin...@googlegroups.com

> On 14.01.2017, at 18:39, Christopher Orr <ch...@orr.me.uk> wrote:
>
> Since last month, no special permissions are needed to upload SNAPSHOTs:
> https://groups.google.com/d/msgid/jenkinsci-dev/53CC6ED4-3BBC-4FAD-A197-10AD7F922A34%40beckweb.net
>
> The permissions look correct here, and match the groupId and artifactId from your logs, plus you said that you've logged into Artifactory, so that should be fine:
> https://github.com/jenkins-infra/repository-permissions-updater/blob/176a269/permissions/plugin-sinatra-chef-builder.yml
>
> So since the permissions look ok (and aren't needed for SNAPSHOTs anyway), and you've managed to log in to the Jenkins account app and Artifactory, I would guess that's something is wrong with your Maven security config.
> But I don't know much about this stuff — maybe you've defined your id/password in multiple places, or perhaps Maven shows where it's reading the credentials from if you use --debug?

403 Forbidden is what would be caused by upload permissions.

401 Unauthorized means that Maven does not send any credentials to Artifactory, which then refuses to let anonymous upload something.

My guess (unclear to me given how this thread developed) is the server ID in settings.xml does not match the server ID in the pom.xml's distributionManagement.

Slide

unread,
Jan 15, 2017, 1:50:47 AM1/15/17
to jenkin...@googlegroups.com

The pom.xml has http instead of https for the Jenkins maven repos.


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/48C8FEE7-49DB-4208-8AC1-DAC1D0E9114B%40beckweb.net.

Irfan Sayed

unread,
Jan 15, 2017, 4:05:32 AM1/15/17
to jenkin...@googlegroups.com
Thanks Christopher.
howver, i tried plaintext and encrypted password as well but still no luck
i enabled the debug mode but still it does not have any specific hint/clue

here is the effective settings
[INFO] Scanning for projects...
[WARNING] The POM for org.eclipse.m2e:lifecycle-mapping:jar:1.0.0 is missing, no dependency information available
[WARNING] Failed to retrieve plugin descriptor for org.eclipse.m2e:lifecycle-mapping:1.0.0: Plugin org.eclipse.m2e:lifecycle-mapping:1.0.0 or one of its dependencies could not be resolved: Failure to find org.eclipse.m2e:lifecycle-mapping:jar:1.0.0 in https://repo.jenkins-ci.org/public/ was cached in the local repository, resolution will not be reattempted until the update interval of repo.jenkins-ci.org has elapsed or updates are forced
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building Chef Sinatra Jenkins plugin 1.12-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The POM for org.eclipse.m2e:lifecycle-mapping:jar:1.0.0 is missing, no dependency information available
[WARNING] Failed to retrieve plugin descriptor for org.eclipse.m2e:lifecycle-mapping:1.0.0: Plugin org.eclipse.m2e:lifecycle-mapping:1.0.0 or one of its dependencies could not be resolved: Failure to find org.eclipse.m2e:lifecycle-mapping:jar:1.0.0 in https://repo.jenkins-ci.org/public/ was cached in the local repository, resolution will not be reattempted until the update interval of repo.jenkins-ci.org has elapsed or updates are forced
[INFO] 
[INFO] --- maven-help-plugin:2.2:effective-settings (default-cli) @ sinatra-chef-builder ---
[INFO] 
Effective user-specific configuration settings:

<?xml version="1.0" encoding="UTF-8"?>
<!-- ====================================================================== -->
<!--                                                                        -->
<!-- Generated by Maven Help Plugin on 2017-01-15T12:53:13                  -->
<!-- See: http://maven.apache.org/plugins/maven-help-plugin/                -->
<!--                                                                        -->
<!-- ====================================================================== -->

<!-- ====================================================================== -->
<!--                                                                        -->
<!-- Effective Settings for 'irfanjs' on 'host-10'                          -->
<!--                                                                        -->
<!-- ====================================================================== -->

  <localRepository xmlns="http://maven.apache.org/SETTINGS/1.1.0">C:\Users\irfanjs\.m2\repository</localRepository>
    <server>
      <username>irfanjs</username>
      <password>***</password>
      <id>java.net-m2-repository</id>
    </server>
  </servers>
    <mirror>
      <mirrorOf>m.g.o-public</mirrorOf>
      <id>repo.jenkins-ci.org</id>
    </mirror>
  </mirrors>
    <profile>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <repositories>
        <repository>
          <id>repo.jenkins-ci.org</id>
          <url>https://repo.jenkins-ci.org/public/</url>
        </repository>
      </repositories>
      <pluginRepositories>
        <pluginRepository>
          <id>repo.jenkins-ci.org</id>
          <url>https://repo.jenkins-ci.org/public/</url>
        </pluginRepository>
      </pluginRepositories>
      <id>jenkins</id>
    </profile>
  </profiles>
  <pluginGroups xmlns="http://maven.apache.org/SETTINGS/1.1.0">
    <pluginGroup>org.jenkins-ci.tools</pluginGroup>
    <pluginGroup>org.apache.maven.plugins</pluginGroup>
    <pluginGroup>org.codehaus.mojo</pluginGroup>
  </pluginGroups>
</settings>

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 8.734 s
[INFO] Finished at: 2017-01-15T00:53:13-08:00
[INFO] Final Memory: 20M/50M
[INFO] ------------------------------------------------------------------------

is there any issue in this ?
regards,


On Sat, Jan 14, 2017 at 10:50 PM, Slide <slide...@gmail.com> wrote:

The pom.xml has http instead of https for the Jenkins maven repos.

On Sat, Jan 14, 2017, 18:50 Daniel Beck <m...@beckweb.net> wrote:

> On 14.01.2017, at 18:39, Christopher Orr <ch...@orr.me.uk> wrote:
>
> Since last month, no special permissions are needed to upload SNAPSHOTs:
> https://groups.google.com/d/msgid/jenkinsci-dev/53CC6ED4-3BBC-4FAD-A197-10AD7F922A34%40beckweb.net
>
> The permissions look correct here, and match the groupId and artifactId from your logs, plus you said that you've logged into Artifactory, so that should be fine:
> https://github.com/jenkins-infra/repository-permissions-updater/blob/176a269/permissions/plugin-sinatra-chef-builder.yml
>
> So since the permissions look ok (and aren't needed for SNAPSHOTs anyway), and you've managed to log in to the Jenkins account app and Artifactory, I would guess that's something is wrong with your Maven security config.
> But I don't know much about this stuff — maybe you've defined your id/password in multiple places, or perhaps Maven shows where it's reading the credentials from if you use --debug?

403 Forbidden is what would be caused by upload permissions.

401 Unauthorized means that Maven does not send any credentials to Artifactory, which then refuses to let anonymous upload something.

My guess (unclear to me given how this thread developed) is the server ID in settings.xml does not match the server ID in the pom.xml's distributionManagement.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CAPiUgVcCM4QJ9tPxev4_fQJ5uPfwqUvrHZejuu33AgeGb_FufQ%40mail.gmail.com.

Irfan Sayed

unread,
Jan 15, 2017, 11:28:56 AM1/15/17
to jenkin...@googlegroups.com
Hi,
Please suggest if what can be done . i verified again all troubleshooting step but all seems OK.

Regards,

Daniel Beck

unread,
Jan 15, 2017, 11:49:37 AM1/15/17
to jenkin...@googlegroups.com
The password is defined for the repo ID: java.net-m2-repository
The upload goes to the repo ID: repo.jenkins-ci.org

Am I missing something here? Isn't this the problem?

Irfan Sayed

unread,
Jan 15, 2017, 11:52:27 AM1/15/17
to jenkin...@googlegroups.com
Thanks Daniel.
so what would be the correct ID ?
java.net-m2-repository OR repo.jenkins-ci.org   ??

Regards




--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Daniel Beck

unread,
Jan 15, 2017, 11:54:44 AM1/15/17
to jenkin...@googlegroups.com

> On 15.01.2017, at 17:52, Irfan Sayed <irfu....@gmail.com> wrote:
>
> so what would be the correct ID ?
> java.net-m2-repository OR repo.jenkins-ci.org ??
>

Doesn't matter, just needs to match.

FWIW recent parent POMs used maven.jenkins-ci.org, so you may be able to just remove that entry from the pom.xml if I'm correct about this:

https://github.com/jenkinsci/plugin-pom/blob/afe60afe46f2466d8d7efc4829e0887cc17e146b/pom.xml#L757


Irfan Sayed

unread,
Jan 15, 2017, 12:02:21 PM1/15/17
to jenkin...@googlegroups.com
Ok. Thanks
Let me remove that entry and tray again

Regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Irfan Sayed

unread,
Jan 15, 2017, 12:34:10 PM1/15/17
to jenkin...@googlegroups.com
Still no luck.
same issue.
I have attached effective POM and effective settings.
Can you please quickly review and see any issue.

Regards,

effective-pom.txt
effective-settings.txt

Daniel Beck

unread,
Jan 15, 2017, 12:53:59 PM1/15/17
to jenkin...@googlegroups.com

> On 15.01.2017, at 18:34, Irfan Sayed <irfu....@gmail.com> wrote:
>
> Can you please quickly review and see any issue.
>

Change the IDs of distributionManagement as well.


Irfan Sayed

unread,
Jan 15, 2017, 1:08:29 PM1/15/17
to jenkin...@googlegroups.com
No. still the issue.
I have just removed the ID in the distributionManagement from POM and build again
still same unauthorized issue 

regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Daniel Beck

unread,
Jan 15, 2017, 1:34:01 PM1/15/17
to jenkin...@googlegroups.com

> On 15.01.2017, at 19:08, Irfan Sayed <irfu....@gmail.com> wrote:
>
> still same unauthorized issue
>

What's the effective POM now?

Irfan Sayed

unread,
Jan 15, 2017, 1:37:19 PM1/15/17
to jenkin...@googlegroups.com
PFA

Regards,


--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.
effective-pom.txt

Fritz Elfert

unread,
Jan 15, 2017, 1:40:12 PM1/15/17
to jenkin...@googlegroups.com
On 15.01.2017 19:08, Irfan Sayed wrote:
> No. still the issue.
> I have just removed the ID in the distributionManagement from POM and

Daniel wrote "CHANGE the IDs of distributionManagement as well.". He did
NOT wrote REMOVE them.

Of course they MUST exist AND equal in both files.

Eg.: If the Id is "foo" in your pom.xml then in your settings.xml it
must me "foo" as well.

Please, at least TRY to understand how this works instead of blindly
trial/error:

If running the deploy, maven does the following:
1. Looks for a server entry in the distributionManagement section
of the pom, reading the Id of that entry.
2. Then, using THAT Id, it searches for a server record
with the SAME id in settings.xml in order to find the credentials

Therefore, of course if you REMOVE the Id in the pom.xml and/or
settings.xml, then maven has nothing to search for.
Sounds logical?

Hope this finally helps
-Fritz


signature.asc

Daniel Beck

unread,
Jan 15, 2017, 1:40:44 PM1/15/17
to jenkin...@googlegroups.com

> On 15.01.2017, at 19:08, Irfan Sayed <irfu....@gmail.com> wrote:
>
> I have just removed the ID in the distributionManagement from POM

WHY? WHY remove it altogether after being told to change it to the same value as something else?

I give up.

Irfan Sayed

unread,
Jan 15, 2017, 1:53:54 PM1/15/17
to jenkin...@googlegroups.com
sorry. my mistake
i apologize.
i ran the command again.
will give you result in few min 

regards,



--
You received this message because you are subscribed to the Google Groups "Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-dev+unsubscribe@googlegroups.com.

Irfan Sayed

unread,
Jan 15, 2017, 2:02:56 PM1/15/17
to jenkin...@googlegroups.com
Awesome !!! you are rock 
it has resolved. I am able to upload new version . BUILD got success
Thanks all for all your tremendous support and co-operation

Regards,
 
Reply all
Reply to author
Forward
0 new messages