-
Notifications
You must be signed in to change notification settings - Fork 489
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
🌱 cron: generalize config and create optional values for scorecard and criticality (2/n) #2254
Conversation
Signed-off-by: Spencer Schrock <sschrock@google.com>
Signed-off-by: Spencer Schrock <sschrock@google.com>
Signed-off-by: Spencer Schrock <sschrock@google.com>
Signed-off-by: Spencer Schrock <sschrock@google.com>
Signed-off-by: Spencer Schrock <sschrock@google.com>
The map can be fetched with |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #2254 +/- ##
=======================================
Coverage 44.45% 44.45%
=======================================
Files 95 95
Lines 7987 7987
=======================================
Hits 3551 3551
Misses 4173 4173
Partials 263 263 |
Integration tests success for |
Thanks! LGTM with comment |
Signed-off-by: Spencer Schrock <sschrock@google.com>
Integration tests success for |
…d criticality (2/n) (ossf#2254) * Add map logic to yaml config. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add scorecard yaml test Signed-off-by: Spencer Schrock <sschrock@google.com> * Separate general config values from scorecard specific values. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add criticality values to config. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add test to confirm empty string behavior. Signed-off-by: Spencer Schrock <sschrock@google.com> * Combine scorecard and criticality values under AdditionalParams. Signed-off-by: Spencer Schrock <sschrock@google.com> Signed-off-by: Spencer Schrock <sschrock@google.com> Co-authored-by: Azeem Shaikh <azeemshaikh38@gmail.com>
…d criticality (2/n) (ossf#2254) * Add map logic to yaml config. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add scorecard yaml test Signed-off-by: Spencer Schrock <sschrock@google.com> * Separate general config values from scorecard specific values. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add criticality values to config. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add test to confirm empty string behavior. Signed-off-by: Spencer Schrock <sschrock@google.com> * Combine scorecard and criticality values under AdditionalParams. Signed-off-by: Spencer Schrock <sschrock@google.com> Signed-off-by: Spencer Schrock <sschrock@google.com> Co-authored-by: Azeem Shaikh <azeemshaikh38@gmail.com> Signed-off-by: nathaniel.wert <nathaniel.wert@kudelskisecurity.com>
…d criticality (2/n) (ossf#2254) * Add map logic to yaml config. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add scorecard yaml test Signed-off-by: Spencer Schrock <sschrock@google.com> * Separate general config values from scorecard specific values. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add criticality values to config. Signed-off-by: Spencer Schrock <sschrock@google.com> * Add test to confirm empty string behavior. Signed-off-by: Spencer Schrock <sschrock@google.com> * Combine scorecard and criticality values under AdditionalParams. Signed-off-by: Spencer Schrock <sschrock@google.com> Signed-off-by: Spencer Schrock <sschrock@google.com> Co-authored-by: Azeem Shaikh <azeemshaikh38@gmail.com> Signed-off-by: nathaniel.wert <nathaniel.wert@kudelskisecurity.com>
What kind of change does this PR introduce?
Part of a series of refactors to generalize the cron infrastructure to enable re-use by the ossf criticality score project
What is the current behavior?
Every config value was a top level yaml field
What is the new behavior (if this is a feature change)?**
Only fields which are general enough to be re-used both by
scorecard
andcriticality_score
remain as top level fields. Anything specific to either program have been moved into nested fields calledscorecard
andcriticality
. These will be parsed as key, value pairs (both strings).The values can still be overwritten by environment variables. Consider the example below, which can be overridded by setting the environment variable
SCORECARD_EXAMPLE_FIELD
:Which issue(s) this PR fixes
NONE
Special notes for your reviewer
Does this PR introduce a user-facing change?
For user-facing changes, please add a concise, human-readable release note to
the
release-note
(In particular, describe what changes users might need to make in their
application as a result of this pull request.)