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

Chore use click invoke yardstick #373

Merged
merged 9 commits into from
Sep 24, 2024

Conversation

willmurphyscode
Copy link
Contributor

@willmurphyscode willmurphyscode commented Sep 3, 2024

One possible implementation to use anchore/yardstick#380

TODOs

  • make validate into list of validations
  • figure out why wire_values needed to set defaults:
    if wire_values:
    # wire up the gate configuration so any gates created will use values from the application config
    db.validation.set_default_gate_config(cfg.validate.db.gate)
    gate_instance = db.validation.Gate(None, None)
    if gate_instance.config != cfg.validate.db.gate:
    msg = f"failed to set default gate config: {gate_instance.config} != {cfg.validate.db.gate}"
    raise ValueError(msg)

This is put up to contrast with a CLI invocation of yardstick, which
might be preferable.

Signed-off-by: Will Murphy <[email protected]>
This allows us to specify a set of images that will be validated against
2022 vulns without having to label a new year of vulns on every image at
once.

Signed-off-by: Will Murphy <[email protected]>
Copy link
Contributor

@wagoodman wagoodman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 wire values is used to set the default behavior (statically) of certain objects -- such as the gate. This is no longer needed with your approach (😄 )

@willmurphyscode willmurphyscode marked this pull request as ready for review September 24, 2024 13:06
@willmurphyscode willmurphyscode added the changelog-ignore Don't consider when generating the changelog label Sep 24, 2024
@willmurphyscode willmurphyscode merged commit 757feed into main Sep 24, 2024
14 checks passed
@willmurphyscode willmurphyscode deleted the chore-use-click-invoke-yardstick branch September 24, 2024 13:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog-ignore Don't consider when generating the changelog
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants