Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workflow CD fails to deploy plugin modules with 403 #2592

Open
Dohbedoh opened this issue Jun 14, 2022 · 2 comments
Open

Workflow CD fails to deploy plugin modules with 403 #2592

Dohbedoh opened this issue Jun 14, 2022 · 2 comments
Labels

Comments

@Dohbedoh
Copy link
Contributor

Reproduction steps

The automated CD release of a new plugin jenkinsci/mina-sshd-api-plugin fails to deploy the module plugins in nexus. Note that the plugin is a multi module plugin (like the aws java sdk plugin for example)

Expected Results

The CD release should deploy the following:

  • https://repo.jenkins-ci.org/releases/io/jenkins/plugins/mina-sshd-api/mina-sshd-api-parent/ (parent pom)
  • https://repo.jenkins-ci.org/releases/io/jenkins/plugins/mina-sshd-api/mina-sshd-common-api/ (hpi)
  • https://repo.jenkins-ci.org/releases/io/jenkins/plugins/mina-sshd-api/mina-sshd-core-api/ (hpi)
  • https://repo.jenkins-ci.org/releases/io/jenkins/plugins/mina-sshd-api/mina-sshd-sftp-api/ (hpi)
  • https://repo.jenkins-ci.org/releases/io/jenkins/plugins/mina-sshd-api/mina-sshd-ssh-api/ (hpi)

Actual Results

The CD release fails to deploy the modules:

[INFO] --- maven-deploy-plugin:2.8.2:deploy(default-deploy) @ mina-sshd-common-api ---
[INFO] Using alternate deployment repository maven.jenkins-ci.org::default::https://repo.jenkins-ci.org/releases/
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Mina SSHD API :: Parent 2.8.0-14.va_eb_e1a_e0145a_:
[INFO] 
[INFO] Mina SSHD API :: Parent ............................ SUCCESS [01:08 min]
[INFO] Mina SSHD API :: Common ............................ FAILURE [  9.282 s]
[INFO] Mina SSHD API :: Core .............................. SKIPPED
[INFO] Mina SSHD API :: SCP ............................... SKIPPED
[INFO] Mina SSHD API :: SFTP .............................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  02:24 min
[INFO] Finished at: 2022-06-14T23:02:46Z
[INFO] ------------------------------------------------------------------------
[WARNING] The requested profile "consume-incrementals" could not be activated because it does not exist.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy(default-deploy) on project mina-sshd-common-api: Failed to deploy artifacts: Could not transfer artifact io.jenkins.plugins.mina-sshd-api:mina-sshd-common-api:hpi:2.8.0-14.va_eb_e1a_e0145a_ from/to maven.jenkins-ci.org (https://repo.jenkins-ci.org/releases/): authorization failed for https://repo.jenkins-ci.org/releases/io/jenkins/plugins/mina-sshd-api/mina-sshd-common-api/2.8.0-14.va_eb_e1a_e0145a_/mina-sshd-common-api-2.8.0-14.va_eb_e1a_e0145a_.hpi, status: 403 Forbidden -> [Help 1]

Anything else?

The plugin was hosted recently and haven't been released yet:

There is some discussion about the repository paths in:

cc @jglick

@Dohbedoh Dohbedoh added the bug label Jun 14, 2022
@daniel-beck
Copy link
Contributor

daniel-beck commented Jun 15, 2022

The wildcard in the permissions file doesn't actually work, because the file names are (dis)allowed based on the name. See this repo's readme.

It works for https://github.com/jenkins-infra/repository-permissions-updater/blob/master/permissions/plugin-aws-java-sdk.yml because the name is a true prefix of all file names (we cannot only allow name-version, so it's name-*). It doesn't work here because name includes -api.

Just don't use this trick. Nobody understands how this actually works, and it creates tons of problems.

@Dohbedoh
Copy link
Contributor Author

I see. Thanks for the explanation, will propose a fix then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants