-
-
Notifications
You must be signed in to change notification settings - Fork 108
Description
Is there an existing issue for this?
- I have searched the existing issues
Current Behavior
The versionfilter of kind: latest is not correctly identifying the most recently published artifact when targeting a Helm chart in an AWS ECR repository.
When multiple image tags exist, the filter selects a version with an older imagePushedAt timestamp instead of the one with the newest timestamp, which contradicts the expected behavior of the latest filter.
Expected Behavior
Expected Behavior
UpdateCLI should select 2.3.0-Test-Promotion.1 as the result because its imagePushedAt timestamp is the most recent.
Actual Behavior
UpdateCLI incorrectly selects 1.5.0-Test-Promotion-troubleshooting-v5.2, which has an older imagePushedAt timestamp.
Supporting Evidence
The aws ecr describe-images command confirms the imagePushedAt timestamp for the incorrectly selected version is older:
{
"imageDetails": [
{
"repositoryName": "atlas-helm/prometheus-agent",
"imageTags": [ "1.5.0-Test-Promotion-troubleshooting-v5.2" ],
"imagePushedAt": "2025-03-25T15:58:14.235000+08:00"
}
]
}This suggests the filter might not be correctly parsing or sorting by the imagePushedAt field from the ECR API response.
Steps To Reproduce
Steps to Reproduce
- Configure an UpdateCLI source for an OCI Helm chart in AWS ECR using
versionfilter: latest.sources: my-chart: kind: helmchart spec: url: "oci://<aws_account_id>.dkr.ecr.<region>.amazonaws.com/my-repo" name: "my-chart" auth: helm: username: "AWS" password: '{{ requiredEnv "ECR_TOKEN" }}' versionfilter: kind: latest
- Ensure the repository contains at least two versions with different
imagePushedAttimestamps, for example:- Version A:
2.3.0-Test-Promotion.1(Pushed at:2025-07-29) - Version B:
1.5.0-Test-Promotion-troubleshooting-v5.2(Pushed at:2025-03-25)
- Version A:
- Run
updatecli apply.
Environment
- OS: Ubuntu 24.04.2
- updatecli: updatecli/updatecli-action@v2
Set default value for version to v0.104.0
VERSION
Application: 0.104.0
Golang : 1.24.5 linux/amd64
Build Time : 2025-07-13T07:48:55ZPipeline Graph
Anything else?
No response
Metadata
Metadata
Assignees
Labels
Type
Projects
Status