-
Notifications
You must be signed in to change notification settings - Fork 56
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
🌱 Add a make target and check in CI to verify CRD compatibility #1449
Changes from 3 commits
dee8608
7d4410b
c757055
0f27438
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT | ||
|
||
go 1.22.5 | ||
everettraven marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
require github.com/everettraven/crd-diff v0.0.0-20241112183958-25304aa59cdb |
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: crd-diff | ||
on: | ||
pull_request: | ||
jobs: | ||
crd-diff: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version-file: go.mod | ||
|
||
- name: Run make verify-crd-compatibility | ||
run: make verify-crd-compatibility CRD_DIFF_ORIGINAL_REF=${{ github.event.pull_request.base.sha }} CRD_DIFF_UPDATED_REF=${{ github.event.pull_request.head.sha }} | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
checks: | ||
crd: | ||
scope: | ||
enabled: true | ||
existingFieldRemoval: | ||
enabled: true | ||
storedVersionRemoval: | ||
enabled: true | ||
version: | ||
sameVersion: | ||
enabled: true | ||
unhandledFailureMode: "Closed" | ||
everettraven marked this conversation as resolved.
Show resolved
Hide resolved
|
||
enum: | ||
enabled: true | ||
removalEnforcement: "Strict" | ||
additionEnforcement: "Strict" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This enforcement means addition of new allowed enum values is considered incompatible. I know we have some areas of our API where we anticipate adding some enum values so we may want to move this to the less strict I left this as strict as possible for now so that we can have a discussion as to whether we want to start as strict as possible and loosen as needed (where it makes sense) or leave room for planned future changes to not be "prevented" by this more restrictive configuration. |
||
default: | ||
enabled: true | ||
changeEnforcement: "Strict" | ||
removalEnforcement: "Strict" | ||
additionEnforcement: "Strict" | ||
required: | ||
enabled: true | ||
newEnforcement: "Strict" | ||
type: | ||
enabled: true | ||
changeEnforcement: "Strict" | ||
maximum: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
maxItems: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
maxProperties: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
maxLength: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
minimum: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
minItems: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
minProperties: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
minLength: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
servedVersion: | ||
enabled: true | ||
unhandledFailureMode: "Closed" | ||
enum: | ||
enabled: true | ||
removalEnforcement: "Strict" | ||
additionEnforcement: "Strict" | ||
default: | ||
enabled: true | ||
changeEnforcement: "Strict" | ||
removalEnforcement: "Strict" | ||
additionEnforcement: "Strict" | ||
required: | ||
enabled: true | ||
newEnforcement: "Strict" | ||
type: | ||
enabled: true | ||
changeEnforcement: "Strict" | ||
maximum: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
maxItems: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
maxProperties: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
maxLength: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
decreaseEnforcement: "Strict" | ||
minimum: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
minItems: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
minProperties: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" | ||
minLength: | ||
enabled: true | ||
additionEnforcement: "Strict" | ||
increaseEnforcement: "Strict" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I didn't realize I wasn't up to date on my bingo version. I don't think we should touch the auto-generated files though. If we are concerned about this particular change I can update my bingo version to v0.9