Google 會運用 AI 技術將內容翻譯成您偏好的語言,但可能會出錯。
ConfigManagement 欄位
透過集合功能整理內容
您可以依據偏好儲存及分類內容。
本頁說明您可以在 ConfigManagement 物件中設定的不同欄位。使用 kubectl 指令設定 Config Sync 時,可以使用這個物件。
| 鍵 |
說明 |
spec.enableMultiRepo |
如果為 true,則會啟用 RootSync 和 RepoSync API。這些 API 提供額外的 Config Sync 功能,例如從多個存放區同步。和同步 Kustomize 與 Helm 設定。預設為 false。 |
spec.preventDrift |
如果設為 true,則會啟用 Config Sync 許可 Webhook,拒絕將不一致的變更推送至運作中的叢集,藉此防止偏差。預設為 false。
無論這個欄位的值為何,Config Sync 一律會修正偏差。 |
ConfigManagement 物件行為設定
| 鍵 |
說明 |
spec.clusterName |
使用者定義的叢集名稱,由 ClusterSelectors 用於將叢集分組。在 Config Sync 安裝作業中不得重複。您無法在 Google Cloud 控制台設定這個欄位。 |
ConfigManagement 物件範例
apiVersion: configmanagement.gke.io/v1
kind: ConfigManagement
metadata:
name: config-management
spec:
clusterName: my-cluster
enableMultiRepo: true
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["難以理解","hardToUnderstand","thumb-down"],["資訊或程式碼範例有誤","incorrectInformationOrSampleCode","thumb-down"],["缺少我需要的資訊/範例","missingTheInformationSamplesINeed","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2026-12-04 (世界標準時間)。"],[],[]]