Conversation
|
|
|
Welcome @itnazeer! It looks like this is your first PR to knative/serving 🎉 |
|
Hi @itnazeer. Thanks for your PR. I'm waiting for a knative member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions 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. |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: itnazeer The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Add the feature flag kubernetes.containerspec-restartpolicy, disabled by default. With it enabled, the serving container may set restartPolicy and restartPolicyRules (Kubernetes ContainerRestartRules, KEP-5307), which are copied unchanged to the Deployment and validated by Kubernetes. Both fields stay disallowed on init containers, where restartPolicy Always makes a native sidecar, and on non-serving containers.
fd967ee to
0f1669f
Compare
|
Hi @dprotaso @skonto, gentle ping when you have time. I rebased on main yesterday. This PR is the API part of #16750 (flag off by default). Before you review the code, it'd help to know if the overall approach in the issue works for you, mainly the follow-up that removes pods whose serving container stopped for good. With only this PR and the flag on, such a pod stays Running and not ready, and the Revision still shows Ready (I checked on kind with Knative built from this branch). I'm happy to fold the follow-up into this PR, keep them separate, or discuss it at a Serving WG meeting, whichever you prefer. If it looks fine to test, could someone add |
|
This needs discussion: #16750 (comment) /hold |
Part of #16750
Proposed Changes
kubernetes.containerspec-restartpolicy, disabled by default.restartPolicyandrestartPolicyRules(Kubernetes ContainerRestartRules, KEP-5307, beta and on by default since 1.35). Knative copies them unchanged to the Deployment, and Kubernetes validates them.restartPolicy: Alwayswould make a native sidecar, and on non-serving containers.ContainerMasknow takes a context, likePodSpecMaskandVolumeMountMask.Release Note