Skip to content

Add Workflows to test kapp-ctrl against latest k8s#1785

Closed
CodesbyUnnati wants to merge 20 commits intocarvel-dev:developfrom
CodesbyUnnati:automation-k8s-nightly-test
Closed

Add Workflows to test kapp-ctrl against latest k8s#1785
CodesbyUnnati wants to merge 20 commits intocarvel-dev:developfrom
CodesbyUnnati:automation-k8s-nightly-test

Conversation

@CodesbyUnnati
Copy link
Copy Markdown
Member

What this PR does / why we need it:

This PR adds workflow files that will be used to test kapp-controller against latest k8s release and a minimum supported version release. This will be an automation which will be triggered at 2am everyday and run kapp-controller tests on the latest kubernetes kind node image generated from the latest commit of that branch.

Which issue(s) this PR fixes:

Fixes #

Does this PR introduce a user-facing change?


Additional Notes for your reviewer:

Review Checklist:
  • Follows the developer guidelines
  • Relevant tests are added or updated
  • Relevant docs in this repo added or updated
  • Relevant carvel.dev docs added or updated in a separate PR and there's
    a link to that PR
  • Code is at least as readable and maintainable as it was before this
    change

Additional documentation e.g., Proposal, usage docs, etc.:


dependabot Bot and others added 20 commits January 16, 2026 11:45
Bumps [sigstore/cosign-installer](https://github.com/sigstore/cosign-installer) from 3.8.2 to 3.9.1.
- [Release notes](https://github.com/sigstore/cosign-installer/releases)
- [Commits](sigstore/cosign-installer@v3.8.2...v3.9.1)

---
updated-dependencies:
- dependency-name: sigstore/cosign-installer
  dependency-version: 3.9.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [softprops/action-gh-release](https://github.com/softprops/action-gh-release) from 2.2.2 to 2.3.2.
- [Release notes](https://github.com/softprops/action-gh-release/releases)
- [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md)
- [Commits](softprops/action-gh-release@v2.2.2...v2.3.2)

---
updated-dependencies:
- dependency-name: softprops/action-gh-release
  dependency-version: 2.3.2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
* Fix PKGI reconciliation taking old App status during upgrade

Signed-off-by: Marin Dzhigarov <mdzhigarov@vmware.com>

* Addresses comments

Signed-off-by: Marin Dzhigarov <mdzhigarov@vmware.com>

---------

Signed-off-by: Marin Dzhigarov <mdzhigarov@vmware.com>
Co-authored-by: Marin Dzhigarov <mdzhigarov@vmware.com>
* Bump minimum k8s version in tests

Signed-off-by: Praveen Rewar <8457124+praveenrewar@users.noreply.github.com>

* Use grafana chart to test helm

Signed-off-by: Praveen Rewar <8457124+praveenrewar@users.noreply.github.com>

* Skip some example helm tests for now

Signed-off-by: Praveen Rewar <8457124+praveenrewar@users.noreply.github.com>

---------

Signed-off-by: Praveen Rewar <8457124+praveenrewar@users.noreply.github.com>
…onflicts (#1766)

* Add retry logic for App CR updates to handle optimistic concurrency conflicts

- Implement updateAppWithRetry() function in PackageInstall reconciler
- Add retry logic with up to 5 attempts for App CR updates
- Re-fetch App CR after each failed update to get latest resourceVersion
- Handle NotFound errors immediately without retries
- Add comprehensive unit tests for retry logic covering:
  - Conflict error handling with retries
  - NotFound error immediate return
  - Update function error propagation
- Use NewApp function for App transformations in retry logic

Fixes optimistic concurrency control conflicts that occur when
multiple operations attempt to update the same App CR simultaneously.

Signed-off-by: Marin Dzhigarov <m.dzhigarov@gmail.com>

* Fix golangci-lint unused parameter warnings in tests

- Rename unused 'action' parameters to '_' in test reactors
- Rename unused 'app' parameter to '_' in failing update function test
- Addresses revive linter warnings for unused parameters

Signed-off-by: Marin Dzhigarov <m.dzhigarov@gmail.com>

* Fix app update retry logic to only retry on conflict errors

- Update updateAppWithRetry to only retry on conflict errors, not on NotFound errors
- Change retry condition from !errors.IsNotFound(err) to !errors.IsConflict(err)
- Update unit tests to reflect new retry behavior:
  - Fix Test_UpdateAppWithRetry_HandlesNotFoundError to expect no retries for NotFound
  - Add Test_UpdateAppWithRetry_HandlesNonConflictError for non-conflict error handling
  - Update Test_UpdateAppWithRetry_HandlesConflictErrors to use proper errors.NewConflict()
  - Add k8s.io/apimachinery/pkg/api/errors import for proper error types

This ensures that only conflict errors trigger retries, while all other errors
(including NotFound) are returned immediately without retries.

Signed-off-by: Marin Dzhigarov <m.dzhigarov@gmail.com>

---------

Signed-off-by: Marin Dzhigarov <m.dzhigarov@gmail.com>
Signed-off-by: Carvel Bot <svc.bot.carvel@vmware.com>
Signed-off-by: Carvel Bot <svc.bot.carvel@vmware.com>
Signed-off-by: Devanshu <devanshu.d@broadcom.com>
Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>
Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>
Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>
Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Resolve build failures

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Update go mod

Update go mod + vendor

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Add kctrl with blank imports

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Update go mod for cli dir

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>
Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Fix formatted string error

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>
Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Update secret

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Update secret name

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Triggering a new build

Triggering a new build

Add checkout repo action

Update branch name

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Triggering a new build

Update branch name to fork's branch

Triggering a new build

Update branch to develop

Update HEAD to develop

Update kind version + pull method

Update workflow extension + add rw permission

Overwrite github-runners preinstalled older kind version to v0.26.0

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Delete older kind cluster and manually create using v0.26.0 version

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Convert username to lowercase

Update code to use updated kind version

Update kind build

Update kind version folder

cleanup
Skip Palcage Install tests to avoid double checking

Signed-off-by: Unnati Mishra <unnati.mishra@broadcom.com>

Update kind version to v0.31.0
Added a debug step to check the default Kind version before forcing installation.
Removed force installation of Kind v0.31.0 and updated cluster creation to use the pre-installed version.
Removed steps for checking and force installing Kind version.
@CodesbyUnnati CodesbyUnnati marked this pull request as draft February 9, 2026 17:37
@carvel-bot carvel-bot added this to Carvel Feb 9, 2026
@github-project-automation github-project-automation Bot moved this to Closed in Carvel Feb 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants