-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
feat: initial OpenAPI spec for webhook provider #4148
Conversation
This needs far better descriptions, but provides the initial OpenAPI doc describing the webhook API as described in the code.
Welcome @lyda! |
Hi @lyda. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
\o many thanks for this PR ! Do you think you can add in this PR:
|
Didn't know vacuum - will definitely add that.
Ideas for the second one? I know prism can run in proxy mode to do this.
Any other tools you can suggest?
…On Thu 4 Jan 2024, 07:38 Michel Loiseleur, ***@***.***> wrote:
\o many thanks for this PR !
Do you think you can add in this PR:
1. a linter test, for instance with vacuum
<https://github.com/daveshanley/vacuum>
2. integrate this spec with unit test, to ensure real validation
—
Reply to this email directly, view it on GitHub
<#4148 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAFOLDHRJ5SVWAYNP7LLDYLYMZMAFAVCNFSM6AAAAABBLEMWMWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZWGYZDANZSGQ>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
I can suggest either https://github.com/getkin/kin-openapi or https://pb33f.io/libopenapi/. |
The vacuum run is now clean.
Explain some of the schemas and endpoints in more detail.
Sorry, @mloiseleur can you confirm my descriptions? I've reviewed a few webook providers and think I have them. I'm still a little unclear what BTW, I'm using this for a provider for my home lab and so far has worked well. |
OK, added the linter spec - I think correctly. Not used to github workflows as I've mainly used gitlab for the past decade. Will look at the unit test changes but likely not till next weekend. Will also look at serving it. |
/ok-to-test |
Cool. I think I have a version that fixes the warnings. Will do it this evening. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Hi, I started to implement a provider from the openapi spec, and i found some few things.
regards, |
/retitle feat: initial OpenAPI spec for webhook provider |
- name: Install Vacuum | ||
# See: https://quobix.com/vacuum/installing/ | ||
run: | | ||
curl -fsSL https://quobix.com/scripts/install_vacuum.sh | sh > /dev/null |
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.
piping shell from curl seems to be wrong. This seems also a personal website from which we would fetch the script.
I wonder why we can't just do go run https://github.com/daveshanley/vacuum
or go install github.com/daveshanley/vacuum@latest
.
Right now it would be a blocking issue given the time after seeing too many supply-chain attacks in the wild.
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.
+1 on avoiding this.
The Kubernetes project currently lacks enough contributors to adequately respond to all PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
PR needs rebase. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
The Kubernetes project currently lacks enough active contributors to adequately respond to all PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /close |
@k8s-triage-robot: Closed this PR. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
This provides the initial OpenAPI doc describing the webhook API as described in the code. Really need far better descriptions for each endpoint and for each element in the schemas.
The goal is to make it far easier to implement providers. I'm using a similar document here
Relates to #4138
Not a goal for this PR, but possibly for a future one is to generate the webhook client with oapi-codegen.