fix(kubernetes): etcd.replicas schema accepts 2, which the chart refuses at render time
メンテナーはふだん 3 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 72/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- helm, kubernetes
調査の方向性
packages/apps/kubernetes/values.yamlの346~348行付近と、packages/apps/kubernetes/templates/etcd.yamlのレンダリングチェックを読みます。まず、cozyvalues-genが整数の列挙型をサポートしているか、このchartがどのようにvalues.schema.jsonを生成するかを確認してください。issueには、ジェネレーターの変更が必要かもしれないと記載されています。スキーマが1と3のみを提示し、レンダリングチェックが他の値を引き続き拒否すれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Describe the bug
The tenant Kubernetes schema declares etcd.replicas as an integer with minimum: 1 and maximum: 3 (packages/apps/kubernetes/values.yaml:346-348, generated into values.schema.json), so it advertises 2 as valid. The chart accepts only 1 and 3 and fails the render on anything else (packages/apps/kubernetes/templates/etcd.yaml:3-4): an even member count tolerates no more failures than the odd count below it. Found while reviewing #4817.
Environment
- Cozystack version: main at 8cab9b7d7bbc
- Provider: any
To Reproduce
- Create or edit a Kubernetes application with
etcd.replicas: 2. - The write is accepted, the dashboard form allows it.
- The HelmRelease fails to render with
etcd.replicas must be 1 or 3, got 2.
Expected behaviour
The schema says what the chart accepts, so the form offers only 1 and 3 and a client reading the schema learns the rule before the HelmRelease fails.
Actual behaviour
The value is stored and the release fails later. A running cluster keeps its previous etcd, so this is a confusing failure, not an outage.
Logs
etcd.replicas must be 1 or 3, got 2: an even member count tolerates no more failures than the odd count below it
Screenshots
Not applicable.
Additional context
The render check stays either way: the aggregated API server does not validate application specs against the schema today (#2657), so the schema change only fixes what the dashboard and other schema readers show. I have not checked whether cozyvalues-gen can emit an integer enum; if it cannot, the description already states the rule and the fix may be in the generator.
Checklist
- I have checked the documentation
- I have searched for similar issues
- I have included all required information
- I have provided clear steps to reproduce
- I have included relevant logs
- 主要言語
- Go
- スター
- 2.2k
- フォーク
- 209
- 平均マージ
- 4日 14時間
- マージ済み PR(30日)
- 140
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
cozystack/cozystack のほかの issue
-
triage/needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
cozystack/cozystack#5464 · リアクション 1 件 ·
メンテナーはふだん 3 日以内に返信
-
test(kubernetes-nodes): stop hand-typing the default Talos version in tests that are not about itオープンarea/testing kind/cleanup triage/needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
cozystack/cozystack#5456 · リアクション 1 件 ·
メンテナーはふだん 3 日以内に返信
-
area/testing kind/cleanup triage/needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
cozystack/cozystack#5447 · リアクション 1 件 ·
メンテナーはふだん 3 日以内に返信
-
kind/bug triage/needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
cozystack/cozystack#5438 · リアクション 1 件 ·
メンテナーはふだん 3 日以内に返信
-
kind/feature triage/needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
cozystack/cozystack#5421 · リアクション 1 件 ·
メンテナーはふだん 3 日以内に返信
cozystack/cozystack の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
-
Correct local module testing instructions for Go sample contributors対応中かも @slievrly が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
-
internal/core: cleanAttachmentName splits a rune at the 255-byte cap and stores invalid UTF-8対応中かも @pacwestnobody が今日担当しました。 オープンgo good first issue help wanted
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
Podiom/Podiom#427 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
TestLaunchGolden spends about 98 seconds on fake-agent exit delays under -race対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
factory:subtask
難易度 1/5 1時間未満 初心者へのやさしさ 95/100
メンテナーはふだん 1 日以内に返信