-
-
Notifications
You must be signed in to change notification settings - Fork 40
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
Support aqua update
command updating packages and registries
#1657
Comments
This exact question came up today in my project team. A must have is that |
What do you mean? |
I like and strongly recommend Renovate, so I'd like to know why users who want this feature don't use Renovate.
Some users manage aqua.yaml in their |
In my case: because the company policies do not allow it. It is not allowed - or requires a separate and lengthy review/audit - to use such managed services. We are experimenting with running Renovate selfhosted, but it is not the same. |
Thank you for your explanation. |
Currently I try to use |
I don't know updatecli well, but I wonder you can update And I think Self hosted Renovate by GitHub Actions is also useful if it is allowed in your company. |
I am working on a PoC for this and will share my findings.
This is a completely different story: we are using the self-hosted Bitbucket (formerly known as Stash) and finishing the migration to GitHub Enterpise will take several more months. |
Thanks. I'm looking forward to it. I'll also take a look updatecli when I have a time.
Oh, I see. |
aqua.yaml---
# aqua - Declarative CLI Version Manager
# https://aquaproj.github.io/
registries:
- type: standard
ref: v3.138.0
packages:
- name: argoproj/[email protected]
- name: dagger/[email protected] # latest is v0.3.13
- name: kubernetes/kubectl
version: v1.24.10 updatecli.dagger.yamlname: Update Dagger GitHub Release
sources:
dagger:
name: Get latest Dagger version from GitHub releases
kind: githubrelease
spec:
owner: dagger
repository: dagger
token: '{{ requiredEnv "GITHUB_TOKEN" }}'
username: '{{ requiredEnv "GITHUB_ACTOR" }}'
versionfilter:
kind: regex
pattern: ^v(\d+)\.(\d+)\.(\d+)$
conditions:
dagger:
name: Check latest Dagger release
kind: githubrelease
sourceid: dagger
spec:
owner: dagger
repository: dagger
token: '{{ requiredEnv "GITHUB_TOKEN" }}'
username: '{{ requiredEnv "GITHUB_ACTOR" }}'
typefilter:
release: true
targets:
dagger:
name: Update Dagger version in aqua.yaml
kind: yaml
transformers:
- addprefix: "dagger/dagger@"
spec:
file: "aqua.yaml"
key: "packages[1].name" # array access is limited to indices The updatecli diff --config updatecli.dagger.yaml
|
Originally I only referred to "3. Exclude packages using long syntax". But in the meantime I also believe that version ranges - especially based on semver - can be an interesting pattern. |
Oh, thank you for sharing! It looks interesting. And the restriction |
I see. Thanks. I think version range is interesting too, but it can make aqua complicated and hard to maintain. |
This is the reason why I am evaluating Updatecli. I think that tools like Renovate or Updatecli are better suited for this kind of tasks. |
I'm not sure what the best layout would be. It was just a first shot, to be more used as a prototype. Check out this exhaustive update definition, where they are using one file (pipeline) per tool: https://github.com/jenkins-infra/packer-images/tree/main/updatecli/updatecli.d
Looking at the source code, I come to the conclusion that this is a self-made implementation of Yamlpath. I just noticed that there is a target type Otherwise you will propaply need a special type "aqua" whose implementation encapsulates some of the necessary but verbose yaml configuration. |
I think one configuration (pipeline) per tool has the advantage to have individual commits/pr per tool to be updated. If you dont need or want this then you are fine to add all pairs of source-target (one per tool) to the same configuration. Update: Kind |
https://github.com/CrystalMethod/aqua-meets-updatecli TODO:
|
sorry to jump in your discussion, accidentally found it and it was too much interesting to ignore it.
You are right, at the beginning of the project I didn't find a library that suited my need and went with the custom one. The situation changed and I am evaluating different library. updatecli/updatecli#903 (comment) when those situation happen do not hesitate to add a +1 on an issue, it helps to prioritize. |
We also use goccy/go-yaml to patch YAML. goccy/go-yaml is awesome, but let me share some known issues.
|
Update only the specific packageChange the version of $ aqua update cli/[email protected] Select the version of $ aqua update -s cli/cli Update cli/cli to the latest. $ aqua update cli/cli |
Idea:
|
Hey @suzuki-shunsuke I was wondering if you might have plans to add this command to the CLI. |
Yeah, we have a plan to work on this, but we're working on other tasks so we can't work on this for a while. |
We're working on it. |
I'm working on it at #2329 . For the detail, please see the description of the pull request. You can try the prerelease version by downloading the prebuilt binary from GitHub Release or running aqua update-aqua v2.14.0-1 Note that this is still work in progress so there may be bugs and the specification may be changed. |
aqua v2.14.0 is out 🎉 |
You are amazing as usual. Thank you so much for this. A great quality of life improvement even if renovate is possible. Great for adhoc updates. Cheers! |
Feature Overview
Add a command to update packages and registries.
Why is the feature needed?
Feedback from @sheldonhull
Does the feature include Breaking Changes?
No.
Example Code
Prepare aqua.yaml which contains old registries and packages
Run
aqua update
.$ aqua update
Then all registries and packages are updated.
Support
-tag
. https://aquaproj.github.io/docs/tutorial-extras/package-tag/aqua update -t dev
Ideas
^1.0.0
I prefer
3
than2
.This is nice to have but isn't mandatory.
I guess it is a bit difficult to implement this feature.
Reference
The text was updated successfully, but these errors were encountered: