Failed to deploy new release of git client plugin to maven.jenkins-ci.org

246 views
Skip to first unread message

Mark Waite

unread,
Aug 20, 2016, 10:40:18 PM8/20/16
to Jenkins Developers
I received the following error message while trying to deploy a new version of the git client plugin:

[INFO] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy (default-deploy) on project git-client: Failed to deploy artifacts: Could not transfer artifact org.jenkins-ci.plugins:git-client:hpi:1.20.1 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 refused -> [Help 1]

Any hints what mistake I've made?

Thanks,
Mark Waite

Daniel Beck

unread,
Aug 20, 2016, 10:41:51 PM8/20/16
to jenkin...@googlegroups.com
This host name is obsolete (and has been for years, but now Tyler pulled the plug). Update to the plugins POM 2.6 or newer, or override the host to be used to point to repo.jenkins-ci.org.
> --
> 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/4610855b-20e9-42fb-8e8b-d06c3808f78a%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Mark Waite

unread,
Aug 20, 2016, 11:23:46 PM8/20/16
to jenkin...@googlegroups.com
I'm trying to not switch the git client plugin from the really old (1.532.1) jenkins release on which it is currently based until the release of git client plugin 2.0.0.  Then it can switch to a JDK 7 based build, dependent on Jenkins 1.625 and on the most recent pom.

I inserted the override to point to repo.jenkins-ci.org.  Unfortunately, I now have the message:

[INFO] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy (default-deploy) on project git-client: Failed to deploy metadata: Could not transfer metadata org.jenkins-ci.plugins:git-client/maven-metadata.xml from/to maven.jenkins-ci.org (https://repo.jenkins-ci.org/releases/): Access denied to: https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/git-client/maven-metadata.xml, ReasonPhrase: Forbidden. -> [Help 1]

The message seems to indicate that it is trying to upload to https://repo.jenkins-ci.org/releases/, but I don't have permission to write to https://repo.jenkins-ci.org/releases/org/jenkins-ci/plugins/git-client/maven-metadata.xml .

As far as I can tell from https://github.com/jenkins-infra/repository-permissions-updater/blob/master/permissions/plugin-git-client.yml , I should have permission to that repository (though I'm accustomed to using "MarkEWaite" as my GitHub login name rather than "markewaite").

Any further hints of mistakes I'm making?

Mark Waite

Daniel Beck

unread,
Aug 20, 2016, 11:34:54 PM8/20/16
to jenkin...@googlegroups.com

> On 21.08.2016, at 05:23, Mark Waite <mark.ea...@gmail.com> wrote:
>
> I'm trying to not switch the git client plugin from the really old (1.532.1) jenkins release

2.x plugin POMs are independent of Jenkins releases (except maybe unexpected problems with using an old release like that).

WRT the permissions issue, I'm looking into this now. Feel free to join me on IRC to be kept up to date.

Daniel Beck

unread,
Aug 20, 2016, 11:52:43 PM8/20/16
to jenkin...@googlegroups.com

> On 21.08.2016, at 05:23, Mark Waite <mark.ea...@gmail.com> wrote:
>
> As far as I can tell from https://github.com/jenkins-infra/repository-permissions-updater/blob/master/permissions/plugin-git-client.yml , I should have permission to that repository (though I'm accustomed to using "MarkEWaite" as my GitHub login name rather than "markewaite").

I changed the permissions to specifically whitelist maven-metadata.xml as well. You should now be able to deploy.

Note that the Jenkins LDAP login is relevant here, and not the GitHub login (which is a reason why we don't just reuse GitHub permissions in some way).

Sorry about this. I believed JFrog support when they told me I don't need to grant permissions on these files explicitly, and didn't verify.

Gabe Montero

unread,
Aug 25, 2016, 9:49:02 AM8/25/16
to Jenkins Developers, m...@beckweb.net
I ran into the same issue, and updated my ~/.m2/settings.xml file's <server> entry to point to repo.jenkins-ci.org instead of maven.jenkins-ci.org,
but when running mvn release:prepare release:perform afterward, the deploy step still tries to access maven.jenkins-ci.org.

I also tried clearing out the cache for the plugin (https://github.com/jenkinsci/openshift-pipeline-plugin) I'm trying to update under ~/.m2/repository as well.  Still no luck.

Any suggestions?

thanks

Robert Sandell

unread,
Aug 25, 2016, 9:57:35 AM8/25/16
to jenkin...@googlegroups.com
distributionManagement is specified in the plugin parent pom, so you should either add your own distributionManagement to your pom, like here https://github.com/jenkinsci/repo-plugin/blob/master/pom.xml#L122 or migrate to the latest plugin parent.

/B

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/a4aadc1f-b1d6-44a2-8c64-bf86369f84b5%40googlegroups.com.

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



--
Robert Sandell
Software Engineer
CloudBees Inc.

Jesse Glick

unread,
Aug 25, 2016, 10:04:48 AM8/25/16
to Jenkins Dev
On Thu, Aug 25, 2016 at 9:57 AM, Robert Sandell <rsan...@cloudbees.com> wrote:
> migrate to the latest plugin parent.

This is the recommendation. Use version 2.6 or later of the plugin
parent POM. (As of 2.0, the Jenkins baseline version is determined by
a property, not the version of the parent POM.)

Gabe Montero

unread,
Aug 25, 2016, 11:31:16 AM8/25/16
to Jenkins Developers
Thanks - that got me past the host issue.  I'm now getting a permission issue.  Not exactly like the one Mark noted last week, but hopefully
it can be resolved in similar fashion:

[INFO] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy (default-deploy) on project openshift-pipeline: Failed to deploy artifacts: Could not transfer artifact com.openshift.jenkins:openshift-pipeline:hpi:1.0.22 from/to maven.jenkins-ci.org (https://repo.jenkins-ci.org/releases): Failed to transfer file: https://repo.jenkins-ci.org/releases/com/openshift/jenkins/openshift-pipeline/1.0.22/openshift-pipeline-1.0.22.hpi. Return code is: 401, ReasonPhrase: Unauthorized. -> [Help 1]

Is there some whitelist tweaking that can be done?

thanks

Gabe Montero

unread,
Aug 25, 2016, 11:33:50 AM8/25/16
to Jenkins Developers
I've looked into moving up, but some issues with dependencies are currently preventing me to build successfully with 2.6.  Short term, I need to get
the next release to the plugin in question (https://github.com/jenkinsci/openshift-pipeline-plugin) published, but then will circle back and work on the
parent POM upgrade.

thanks

Jesse Glick

unread,
Aug 25, 2016, 12:08:09 PM8/25/16
to Jenkins Dev
On Thu, Aug 25, 2016 at 11:31 AM, Gabe Montero <gabemo...@gmail.com> wrote:
> Failed to
> transfer file:
> https://repo.jenkins-ci.org/releases/com/openshift/jenkins/openshift-pipeline/1.0.22/openshift-pipeline-1.0.22.hpi.
> Return code is: 401, ReasonPhrase: Unauthorized.

@Daniel, maybe an artifact permission issue?

Gabe Montero

unread,
Aug 25, 2016, 12:29:23 PM8/25/16
to Jenkins Developers
I believe I sorted it out.  I needed <server> entries for both maven.jenkins-ci.org and repo.jenkins-ci.org in my ~/.m2/settings.xml.
With that, `mvn release:prepare release:perform" completed successfully for me, at least on my local host side.

Assuming the "upstream side mechanics" that result in the new plugin version showing up at https://updates.jenkins-ci.org/download/plugins,
I should be good to go.

Thanks to everyone for the quick responses.

Gabe Montero

unread,
Oct 1, 2016, 10:59:04 AM10/1/16
to Jenkins Developers
I'm trying to publish a new plugin (vs. the existing plugin I ultimately got working with everyone's help back in August), and this time I got the
same error Mark posted back in August (though on my plugin file vs. the metadata.xml file):

[INFO] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.6:deploy (default-deploy) on project openshift-login: Failed to deploy artifacts: Could not transfer artifact org.openshift.jenkins:openshift-login:hpi:0.1 from/to maven.jenkins-ci.org (https://repo.jenkins-ci.org/releases): Access denied to: https://repo.jenkins-ci.org/releases/org/openshift/jenkins/openshift-login/0.1/openshift-login-0.1.hpi, ReasonPhrase: Forbidden. -> [Help 1]

Any chance that updating the whitelist like Daniel did back in August be necessary / help here?

thanks

Baptiste Mathus

unread,
Oct 1, 2016, 11:54:28 AM10/1/16
to Jenkins Developers

Hi Gabe,
Seems not exactly the same.

Check you're in https://github.com/jenkins-infra/repository-permissions-updater/ as you should. If not file a PR to add your account to allow yourself.

(Beware, it's your Jenkins ID, not GitHub)


--
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/389fd949-8c09-4c7a-a058-2ea673e35282%40googlegroups.com.

Gabe Montero

unread,
Oct 2, 2016, 2:01:35 PM10/2/16
to Jenkins Developers, m...@batmat.net
Thanks for the pointer Baptiste.  My new plugin does not even have a yml file present in https://github.com/jenkins-infra/repository-permissions-updater/ .
I hadn't created a new plugin since this was put into place and missed the prior announcements regarding it.

I'll file a PR to *create* the file, with myself added to the account, and go from there.

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

Gabe Montero

unread,
Oct 2, 2016, 2:28:43 PM10/2/16
to Jenkins Developers, m...@batmat.net

Tatiana Didik

unread,
Nov 9, 2016, 10:36:01 PM11/9/16
to Jenkins Developers
Hi,
I have the similar issue.


I've checked and looks like everything is in order and I do have a permission.

My username and password are in my settings.xml and they are Jenkins ID and password. I have both repo.jenkins-ci.org and maven.jenkins-ci.org in the <servers> section, <pluginRepositories> contains <url>https://repo.jenkins-ci.org/public/</url>.

Any advices? Am I foreseen something?

Daniel Beck

unread,
Nov 10, 2016, 10:00:18 AM11/10/16
to jenkin...@googlegroups.com

> On 10.11.2016, at 04:36, Tatiana Didik <aquar...@gmail.com> wrote:
>
> Any advices? Am I foreseen something?

You changed your plugin's group ID 13 hours ago, and that one isn't allowed in the YAML file that grants you upload permission:

https://github.com/jenkinsci/sonar-gerrit-plugin/commit/75af479bd0f0e9d2d21fdfa5f91df989dc70f83f#diff-600376dffeb79835ede4a0b285078036R13

Tatiana Didik

unread,
Nov 10, 2016, 2:58:28 PM11/10/16
to Jenkins Developers
Thank you Daniel! I've messed it up with copy-paste... 
Reply all
Reply to author
Forward
0 new messages