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

replicalimits unit tests do not include checks for Scale resources #419

Open
skaven81 opened this issue Oct 20, 2023 · 4 comments
Open

replicalimits unit tests do not include checks for Scale resources #419

skaven81 opened this issue Oct 20, 2023 · 4 comments
Labels

Comments

@skaven81
Copy link

The general/replicalimits ConstraintTemplate in the library only has unit tests that validate updates to a Deployment resource. It does not check for Scale resources, which get generated when running kubectl scale commands.

There is also a bug in the Rego because in the event of kubectl scale deploy <name> --replicas=0, the Scale resource has an empty spec (so input.review.object.spec is empty) and a violation is generated, even if a range allows zero as a valid value.

Copy link

stale bot commented Dec 20, 2023

This issue/PR has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 20, 2023
@stale stale bot closed this as completed Jan 3, 2024
@ritazh ritazh reopened this Jan 3, 2024
@ritazh ritazh removed the stale label Jan 3, 2024
Copy link

stale bot commented Mar 3, 2024

This issue/PR has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Mar 3, 2024
@maxsmythe
Copy link
Contributor

poke the bot

@stale stale bot removed the stale label Mar 5, 2024
Copy link

stale bot commented May 4, 2024

This issue/PR has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label May 4, 2024
@ritazh ritazh added triaged and removed stale labels May 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants