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

Automate the Perses version upgrade #35

Open
nicolastakashi opened this issue Nov 7, 2024 · 4 comments
Open

Automate the Perses version upgrade #35

nicolastakashi opened this issue Nov 7, 2024 · 4 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@nicolastakashi
Copy link
Contributor

Proposal

Automate Version Update Workflow for Perses Helm Chart

Current Situation

Whenever a new version of Perses is released, we currently need to manually perform the following steps in the perses/helm-charts repository:

  1. Update appVersion in chart.yaml.
  2. Update version in chart.yaml.
  3. Run make update-helm-readme to regenerate the README.

Goal

Automate this process using a GitHub Actions workflow that identifies new releases and automatically updates the required files, then opens a pull request for review.

Proposed Solutions

  1. Scheduled Cron Workflow

    • Create a workflow that runs on a regular schedule (e.g., every 6 hours or daily).
    • The workflow would:
      • Check for new releases of Perses.
      • Update the appVersion and version fields in chart.yaml.
      • Run make update-helm-readme.
      • Create a new branch and open a pull request with the changes.
  2. Repository Dispatch Event

    • Utilize a repository dispatch event to trigger the workflow when a new release is published in the perses/perses repository.
    • This approach can provide a more immediate response to new releases without waiting for the scheduled cron job.
    • GitHub's repository_dispatch event can be used to trigger the update workflow in perses/helm-charts whenever perses/perses releases a new version.

Benefits

  • Reduces manual work and potential human error.
  • Ensures timely updates to the Helm chart.
  • Streamlines the process of keeping the perses/helm-charts repository aligned with new releases of Perses.
@nicolastakashi nicolastakashi added enhancement New feature or request help wanted Extra attention is needed labels Nov 7, 2024
@nicolastakashi
Copy link
Contributor Author

Actually after sleep on it for a long time I have a better propose, we can leverage renovatebot it's kind a dependabot but with esteorids.

renovate can work with complex file structure by watching different dependencies types like docker, language packages, helm and so on.

we can use this kind of structure https://github.com/renovatebot/helm-charts/blob/c754175e90defed41b7981847330b23fa00b1ea4/renovate.json#L12-L21 to configure renovate to update appVersion based on the perses docker version.

wdyt @Nexucis @celian-garcia ?

@celian-garcia
Copy link
Member

Actually after sleep on it for a long time I have a better propose, we can leverage renovatebot it's kind a dependabot but with esteorids.

renovate can work with complex file structure by watching different dependencies types like docker, language packages, helm and so on.

we can use this kind of structure https://github.com/renovatebot/helm-charts/blob/c754175e90defed41b7981847330b23fa00b1ea4/renovate.json#L12-L21 to configure renovate to update appVersion based on the perses docker version.

wdyt @Nexucis @celian-garcia ?

I'm 100% with you but a bit biased as I'm using Renovate daily for one or two years now 😅 I can definitely help on that. Renovate has also a postupgrade config (don't remember the exact name) that would allow you to run a script after having updated the app version. Typically for your make command

@nicolastakashi
Copy link
Contributor Author

hahah I'm quite new to renovate but I'm pretty impressed by its power.
I'd love to have your support on that

@celian-garcia
Copy link
Member

Sure! don't hesitate to contact me directly on slack if you have questions 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants