Closed willkutler closed 2 years ago
@willkutler actually, the disabled
isn't available under policyDefaults
.
To add it, you'll need to do the following:
Disabled
field to this struct https://github.com/stolostron/policy-generator-plugin/blob/a26a18edfef92b6127e9d0c355b62bc0eb814a1d/internal/types/types.go#L56policyDefault.disabled
value on each policy that doesn't set it in the applyDefaults
method: https://github.com/stolostron/policy-generator-plugin/blob/a26a18edfef92b6127e9d0c355b62bc0eb814a1d/internal/plugin.go#L314getPolicyBool
to ensure that an explicit false
wasn't set on the policy.Disabled
before setting the default.@mprahl @dhaiducek thanks for the help - does my recent commit look ok?
@willkutler this looks great! Could you please squash your commits and change the commit message to something like "Add support for policyDefaults.disabled"?
@mprahl done! thanks for the reviews
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: mprahl, willkutler
The full list of commands accepted by this bot can be found here.
The pull request process is described here
Signed-off-by: Will Kutler wkutler@redhat.com
https://github.com/stolostron/backlog/issues/22350