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

feat(datasource/helm): add digest to release #23432

Merged
merged 6 commits into from
Aug 25, 2023

Conversation

scmeli
Copy link
Contributor

@scmeli scmeli commented Jul 18, 2023

Changes

Add support for the digest of a chart archive within the helm datasource.

Context

discussion#23430

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@CLAassistant
Copy link

CLAassistant commented Jul 18, 2023

CLA assistant check
All committers have signed the CLA.

Copy link
Member

@viceice viceice left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nope, doesn't work like this.

@scmeli
Copy link
Contributor Author

scmeli commented Jul 18, 2023

nope, doesn't work like this.

Thanks for the response. I updated the snapshot to fix the test cases. Can you elaborate if this is not what you meant? This change allows the regex manager to also update the digest for a helm datasource.

@scmeli scmeli requested a review from viceice July 18, 2023 22:48
@scmeli
Copy link
Contributor Author

scmeli commented Aug 24, 2023

@viceice Hi, can you provide more details? These changes work in my local environment so not sure what is broken. My use case involves updating the version/digest of a helm archive within a bazel http_file rule. This PR adds the digest to the helm datasource so I can use it with a regex manager. The digest is in the index.yaml which is already parsed by the helm datasource, but is not captured since it is missing from the HelmRelease type.

@viceice viceice changed the title feat: helm add digest feat(datasource/helm): add digest to release Aug 25, 2023
@viceice viceice enabled auto-merge August 25, 2023 07:40
@viceice viceice added this pull request to the merge queue Aug 25, 2023
Merged via the queue into renovatebot:main with commit aa25017 Aug 25, 2023
36 checks passed
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 36.58.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

mpkorstanje added a commit to mpkorstanje/renovate that referenced this pull request Sep 6, 2023
In renovatebot#23432 support was added for digests. This introduces a regression
when used in combination with the Helm repository on Gitlab.

In the `index.yaml` generated by Gitlabs Helm Repository the digest is left
blank. For example:

```
apiVersion: v2
entries:
  blank-digest:
  - apiVersion: v2
    created: '2023-09-05T13:25:19.046604000Z'
    description: A Helm chart with a blank digest
    digest:
    name: blank-digest
    urls:
    - https://charts.helm.sh/stable/packages/ambassador-2.7.0.tgz
    version: 2.7.0
```

As a result `newDigest: release.digest` will set the `newDigest`
to `null` and this causes the update to be removed in
`workers/repository/process/lookup/index.ts`.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants