Skip to content

Instantly share code, notes, and snippets.

@dduportal
Last active July 14, 2021 11:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dduportal/4f41a48ff32e7a5c3fbcc2114378b326 to your computer and use it in GitHub Desktop.
Save dduportal/4f41a48ff32e7a5c3fbcc2114378b326 to your computer and use it in GitHub Desktop.

Let's start by finding the latest valid release as a control sample:

Let's find when the release 0.3.0 went wrong:

There could be 2 reasons for the HTTP/403:

  • Either the credentials were rejected during the authentication (credentials changed, authentication server down, etc.),
  • OR the artefacts were already exsiting at the time of the "Release" step so the artifactory defined policy is to reject the request with.. HTTP/403.

=> As the credentials have not been changed and there was no incident known at this time on jfrog, let's check the second option.

Why would we have already existing artifacts for the release 0.3.0?

  • Someone did the release manually => no way, as the credentials used are the one from the automated system as per @olblak's checks.
  • Another build already uploaded the artifacts

=> If we check the "timestamps":

It sounds like that the cd workflow was able to upload the release around 16:xx UTC but somehow was re-triggered (or run) only at 23:xx UTC. => this hypothesis should be verified (by fetching the GitHub API for all the workflow run associated to this workflow AND this commit and cross-reference: I feel like GitHub UI is not showing everything). It would explain the behavior (assuming something went wrong and the job failed right after the upload) and is plausbible as "workflow_dispatch" is used in the workflow trigger event for cd.

Remediations:

  • It sounds like that if we ensure that there is a tag 0.3.0 created to the commit https://github.com/jenkinsci/conventional-commits-plugin/commit/dd8604eb36cbf58bec9d1742c001ece719982bbb
  • If the tag 0.3.0 is correctly done, then the GitHub release 0.3.0 can manually created and should point to this tag. Then it should be filled manually by cross-referencing the content of the "next" release and the commits sinces 0.2.1 (not a lot)
  • Then, you can re-run the draft releaser build to ensure that the "next" GitHub release is updated (or update it manually by removing items from 0.3.0)
  • Finally, you should be able to trigger the next release
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment