Skip to content

Conversation

@vishen
Copy link

@vishen vishen commented Jul 10, 2025

This fixes an issue where "resourceKoBuildCreate" uses the result of "doPublish" as the "image_ref", but in "resourceKoBuildRead" the result of "doBuild" as the "image_ref". This causes an issue when a single "tags" is configured and the "image_ref" from "doPublish" will include the tag, but the the "image_ref" from "doBuild" does not, and will always cause the resource to be recreated.

This PR:

  • Add includeTag boolean parameter to doBuild function
  • When includeTag is true, return tagged reference with digest appended
  • Update doBuild calls: false for Create, true for Read operations
  • Maintains backward compatibility with existing behavior

This fixes an issue where "resourceKoBuildCreate" uses the result of
"doPublish" as the "image_ref", but in "resourceKoBuildRead" the result
of "doBuild" as the "image_ref". This causes an issue when a single
"tags" is configured and the "image_ref" from "doPublish" will include
the tag, but the the "image_ref" from "doBuild" does not, and will always
cause the resource to be recreated.

- Add includeTag boolean parameter to doBuild function
- When includeTag is true, return tagged reference with digest appended
- Update doBuild calls: false for Create, true for Read operations
- Maintains backward compatibility with existing behavior
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant