Skip to content

docs: document container security context in v1.6.6 - #3165

Merged
ti-chi-bot[bot] merged 7 commits into
pingcap:release-1.6from
fgksgf:codex/document-container-security-context
Aug 14, 2026
Merged

docs: document container security context in v1.6.6#3165
ti-chi-bot[bot] merged 7 commits into
pingcap:release-1.6from
fgksgf:codex/document-container-security-context

Conversation

@fgksgf

@fgksgf fgksgf commented Jul 30, 2026

Copy link
Copy Markdown
Member

Summary

  • Document Pod-level and container-level security context configuration for CR-generated containers starting from TiDB Operator v1.6.6.
  • Add a copyable PD example that combines container identity settings with Pod-level fsGroup.
  • Clarify supported CRs and container paths, configuration precedence, rolling updates, and migration from deprecated TiKV/TiFlash privileged fields.

Why

The existing guide only documents Pod-level podSecurityContext. The feature introduced by pingcap/tidb-operator#6404 and cherry-picked to release-1.6 by pingcap/tidb-operator#6858 also lets users configure generated containers directly. Without precise scope and precedence guidance, users can select unsupported fields or create containers that cannot write to their volumes.

How

  • Separate Pod-level and container-level configuration into dedicated sections.
  • Distinguish TidbCluster and DMCluster component paths from TidbDashboard, TidbNGMonitoring, and TidbMonitor paths, and identify CRs that only support Pod-level settings.
  • Explain Pod/container precedence, enumerate supported auxiliary-container fields, and warn that adding securityContext disables the legacy TiKV/TiFlash privileged fallback.

Testing

  • npx --yes markdownlint-cli@0.47.0 en/containers-run-as-non-root-user.md zh/containers-run-as-non-root-user.md
  • npx --yes markdown-link-check@3.13.7 for both changed files using the repository link-check configuration
  • git diff --check

Risks and Reviewer Focus

  • The documentation is based on the current release-1.6 implementation. The public v1.6.6 tag has not been published yet, so the version statement should remain aligned with the release schedule.
  • Updating securityContext on a deployed component changes its Pod template and triggers a rolling update.

@coderabbitai

coderabbitai Bot commented Jul 30, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 49d2e3ba-b030-4056-88a1-3fa08c47cf9b

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@ti-chi-bot ti-chi-bot Bot added missing-translation-status This PR does not have translation status info. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 30, 2026
fgksgf

This comment was marked as outdated.

@ti-chi-bot ti-chi-bot Bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 30, 2026
@fgksgf

This comment was marked as outdated.

fgksgf

This comment was marked as outdated.

@fgksgf

This comment was marked as outdated.

fgksgf

This comment was marked as outdated.

@qiancai qiancai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Rest LGTM

Comment thread zh/containers-run-as-non-root-user.md Outdated
Comment thread en/containers-run-as-non-root-user.md Outdated
Comment thread en/containers-run-as-non-root-user.md Outdated
Comment thread en/containers-run-as-non-root-user.md
Comment thread zh/containers-run-as-non-root-user.md
@ti-chi-bot

ti-chi-bot Bot commented Aug 3, 2026

Copy link
Copy Markdown

[LGTM Timeline notifier]

Timeline:

  • 2026-08-03 03:47:34.6189845 +0000 UTC m=+2413440.655079546: ☑️ agreed by qiancai.

@ti-chi-bot ti-chi-bot Bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Aug 3, 2026
@qiancai qiancai added needs-cherry-pick-release-1.x Should cherry pick this PR to release-1.x branch. translation/done This PR has been translated from English into Chinese and updated to pingcap/docs-cn in a PR. and removed missing-translation-status This PR does not have translation status info. labels Aug 3, 2026
Co-authored-by: Grace Cai <qqzczy@126.com>
@ti-chi-bot

ti-chi-bot Bot commented Aug 11, 2026

Copy link
Copy Markdown

@time-and-fate: adding LGTM is restricted to approvers and reviewers in OWNERS files.

Details

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.

Comment thread zh/containers-run-as-non-root-user.md Outdated
@qiancai
qiancai force-pushed the codex/document-container-security-context branch from 7894b5f to d114455 Compare August 12, 2026 02:30
Comment thread zh/containers-run-as-non-root-user.md Outdated
Co-authored-by: Grace Cai <qqzczy@126.com>
@ti-chi-bot

ti-chi-bot Bot commented Aug 14, 2026

Copy link
Copy Markdown

@qiancai: Your lgtm message is repeated, so it is ignored.

Details

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.

@qiancai

qiancai commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator

/approve

@qiancai qiancai added the lgtm label Aug 14, 2026
@ti-chi-bot

ti-chi-bot Bot commented Aug 14, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: qiancai

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

The pull request process is described here

Details 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

@ti-chi-bot ti-chi-bot Bot added the approved label Aug 14, 2026
@qiancai qiancai self-assigned this Aug 14, 2026
@ti-chi-bot
ti-chi-bot Bot merged commit cb63d0c into pingcap:release-1.6 Aug 14, 2026
15 checks passed
@ti-chi-bot

Copy link
Copy Markdown
Member

In response to a cherrypick label: new pull request created to branch release-1.x: #3170.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved lgtm needs-1-more-lgtm Indicates a PR needs 1 more LGTM. needs-cherry-pick-release-1.x Should cherry pick this PR to release-1.x branch. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. translation/done This PR has been translated from English into Chinese and updated to pingcap/docs-cn in a PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants