Skip to content
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 initial (alpha) documentation about sidecar containers #41802

Merged
merged 1 commit into from
Aug 7, 2023

Conversation

matthyx
Copy link
Contributor

@matthyx matthyx commented Jun 29, 2023

@k8s-ci-robot k8s-ci-robot added this to the 1.28 milestone Jun 29, 2023
@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. language/en Issues or PRs related to English language labels Jun 29, 2023
@k8s-ci-robot k8s-ci-robot added the sig/docs Categorizes an issue or PR as relevant to SIG Docs. label Jun 29, 2023
@matthyx matthyx force-pushed the sidecar branch 2 times, most recently from 4737fc1 to 8e7bae7 Compare June 29, 2023 10:19
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. area/blog Issues or PRs related to the Kubernetes Blog subproject and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 29, 2023
@sftim
Copy link
Contributor

sftim commented Jun 30, 2023

/sig node

@k8s-ci-robot k8s-ci-robot added sig/node Categorizes an issue or PR as relevant to SIG Node. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Jun 30, 2023
@tzneal
Copy link
Contributor

tzneal commented Jul 3, 2023

/cc

@k8s-ci-robot k8s-ci-robot requested a review from tzneal July 3, 2023 13:39
@k8s-ci-robot k8s-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. area/release-eng Issues or PRs related to the Release Engineering subproject language/de Issues or PRs related to German language language/es Issues or PRs related to Spanish language language/fr Issues or PRs related to French language language/hi Issues or PRs related to Hindi language language/id Issues or PRs related to Indonesian language language/ja Issues or PRs related to Japanese language and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jul 4, 2023
@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 31, 2023
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: e4105ebb73dc503576586b77f4a0944af241601b

content/en/docs/concepts/workloads/pods/_index.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
content/en/docs/concepts/workloads/pods/init-containers.md Outdated Show resolved Hide resolved
@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 1, 2023
@sftim
Copy link
Contributor

sftim commented Aug 1, 2023

/hold
To make merges (and conflict resolution) easier, let's squash commits on this one.

OK to unhold once squashed.

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 1, 2023
@matthyx
Copy link
Contributor Author

matthyx commented Aug 1, 2023

@sftim @tengqm thanks for your valuable inputs, I have updated the PR

Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com>
Copy link
Contributor

@tzneal tzneal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 7, 2023
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 92203e45be15c15477f73f2f3d0bb2e1c2485e4b

@sftim
Copy link
Contributor

sftim commented Aug 7, 2023

/hold cancel

It's squashed

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 7, 2023
Copy link
Contributor

@sftim sftim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could use polish but is good enough for alpha.

/lgtm
/approve


{{< feature-state for_k8s_version="v1.28" state="alpha" >}}

Enabling the [SidecarContainers feature gate](/docs/reference/command-line-tools-reference/feature-gates/)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(nit

Suggested change
Enabling the [SidecarContainers feature gate](/docs/reference/command-line-tools-reference/feature-gates/)
Enabling the SidecarContainers` [feature gate](/docs/reference/command-line-tools-reference/feature-gates/)

{{< feature-state for_k8s_version="v1.28" state="alpha" >}}

Enabling the [SidecarContainers feature gate](/docs/reference/command-line-tools-reference/feature-gates/)
allows specifying a <code>restartPolicy=Always</code> to init containers, making sure they are
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
allows specifying a <code>restartPolicy=Always</code> to init containers, making sure they are
allows you to specify `restartPolicy: Always` for init containers. Setting the `Always` restart policy
ensures that the init containers where you set it are

{{< feature-state for_k8s_version="v1.28" state="alpha" >}}

Starting with Kubernetes 1.28 in alpha, a feature gate named `SidecarContainers`
allows to specify a `restartPolicy` for init containers which is independent of
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(nit)

Suggested change
allows to specify a `restartPolicy` for init containers which is independent of
allows you to specify a `restartPolicy` for init containers which is independent of

Comment on lines +312 to +314
The only difference is that they are not required to complete before the next
init container starts, so a next init container will start after the current
container status has been set to `Pod.status.containerStatuses[id of container].started=true`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The only difference is that they are not required to complete before the next
init container starts, so a next init container will start after the current
container status has been set to `Pod.status.containerStatuses[id of container].started=true`
Compared to regular init containers, sidecar-style init containers continue to
run and the next init container can being starting once the kubet has set
the `started` container status for the sidecar-style init container to true.
That status either becomes true because there is a process running in the
container and no startup probe defined, or

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sftim, tzneal

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 7, 2023
@k8s-ci-robot k8s-ci-robot merged commit 962bf89 into kubernetes:dev-1.28 Aug 7, 2023
4 checks passed
@matthyx
Copy link
Contributor Author

matthyx commented Aug 8, 2023

This could use polish but is good enough for alpha.

/lgtm /approve

Thanks @sftim should I open a new PR with your suggestions?

@sftim
Copy link
Contributor

sftim commented Aug 8, 2023

Should I open a new PR with your suggestions?

Please do if you've got the capacity for that.

@matthyx matthyx deleted the sidecar branch August 8, 2023 09:46
@matthyx
Copy link
Contributor Author

matthyx commented Aug 8, 2023

Please do if you've got the capacity for that.

#42447

Rishit-dagli pushed a commit to Rishit-dagli/website that referenced this pull request Aug 12, 2023
Add initial (alpha) documentation about sidecar containers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/blog Issues or PRs related to the Kubernetes Blog subproject area/release-eng Issues or PRs related to the Release Engineering subproject cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. language/en Issues or PRs related to English language lgtm "Looks good to me", indicates that a PR is ready to be merged. sig/docs Categorizes an issue or PR as relevant to SIG Docs. sig/node Categorizes an issue or PR as relevant to SIG Node. sig/release Categorizes an issue or PR as relevant to SIG Release. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
Development

Successfully merging this pull request may close these issues.

8 participants