[apps] Refactor resources - #1106
Conversation
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
WalkthroughThis update standardizes and clarifies resource configuration documentation and examples across multiple application Helm charts. It simplifies commented examples for resource limits, rewords descriptions for Changes
Sequence Diagram(s)Not applicable: The changes are documentation and comment updates, with no new features or control flow modifications. Possibly related PRs
Suggested labels
Suggested reviewers
Poem
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 8
♻️ Duplicate comments (1)
packages/apps/kubernetes/values.yaml (1)
126-135: Same comment as for apiServer applies to controllerManager & scheduler blocksEnsure the chosen example format (flat vs. limits/requests) is consistent across all control-plane components.
🧹 Nitpick comments (33)
packages/apps/clickhouse/values.yaml (2)
50-55: Simplified example likely mis-guides users if the chart still expectslimits/requestsnestingHelm charts typically render the
resourcesblock directly into the container spec, which in Kubernetes must be structured as:resources: limits: cpu: 4000m memory: 4Gi requests: cpu: 400m memory: 512MiThe new example shows flat
cpu/memorykeys. Unless the templates were refactored to map these keys internally, this comment could confuse users and lead to invalid manifests. Please confirm that:
values.yamlschema and templates were updated to accept the flat shape, or- Retain the canonical nested example and add a note if shorthand is supported.
56-57: Enumerate acceptedresourcesPresetvalues for discoverabilityThe comment above mentions presets (e.g.,
"small"), but users have no visibility into the valid options without diving into the templates. Adding the allowed preset names (tiny,small,medium,large, etc.) right here or linking to documentation will improve UX and prevent typos.packages/apps/rabbitmq/values.yaml (2)
46-48: Remove trailing whitespace to satisfy YAML lint
yamllintflagged trailing spaces on these comment lines. While harmless at runtime, they fail strict linters and CI.- # cpu: 4000m␠ - # memory: 4Gi␠ + # cpu: 4000m + # memory: 4Gi
49-50: Minor wording tweak for consistencyElsewhere in the repo preset names are wrapped in back-ticks for readability.
-## @param resourcesPreset Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge) +## @param resourcesPreset Use a common resources preset when `resources` is not set explicitly. (allowed values: `none`, `nano`, `micro`, `small`, `medium`, `large`, `xlarge`, `2xlarge`)packages/apps/rabbitmq/README.md (1)
25-31: Table still renders, but back-ticks aid copy-pasteConsider formatting preset names with back-ticks, mirroring the change suggested in
values.yaml, to make them stand out and reduce copy errors.-| `resourcesPreset` | Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge) | `nano` | +| `resourcesPreset` | Use a common resources preset when `resources` is not set explicitly. (allowed values: `none`, `nano`, `micro`, `small`, `medium`, `large`, `xlarge`, `2xlarge`) | `nano` |packages/apps/redis/values.yaml (2)
18-20: Remove trailing whitespace to satisfy YAML lint
Lines 18-19 contain trailing spaces flagged byyamllint. Delete the extra spaces to keep CI green.- # cpu: 4000m␠ - # memory: 4Gi␠ + # cpu: 4000m + # memory: 4Gi
17-20: Example resource block may mislead users
The simplified example showscpu/memorydirectly underresources, which is not a valid Kubernetesresourcesobject (expectslimits/requests). Unless templates have been adapted to handle this custom shape, users copy-pasting the snippet will hit rendering errors.Consider restoring the canonical structure or adding a clarifying comment:
# resources: # limits: # cpu: 4000m # memory: 4Gi # requests: # cpu: 500m # memory: 128Mipackages/apps/nats/Chart.yaml (1)
19-19: Chart version bump looks good – don’t forget the CHANGELOG
versionhas been correctly incremented to0.7.1.
Please ensure a matching entry is added to the project-wide CHANGELOG so downstream consumers can trace the patch.packages/apps/nats/values.yaml (1)
71-72: Consider adding an enum to the JSON-schema for stronger validation
resourcesPresetis documented with an allowed list but the schema does not enforce it.
Adding anenumarray invalues.schema.jsonwill give immediate feedback on typos:"resourcesPreset": { "type": "string", "description": "...", - "default": "nano" + "default": "nano", + "enum": ["none","nano","micro","small","medium","large","xlarge","2xlarge"] }packages/apps/nats/README.md (1)
7-18: Documentation table updated – ensure width rendering remains intactThe long description for
resourcesPresetmay overflow on narrow Markdown viewers, causing table wrap issues.
Consider breaking the sentence or moving allowed values to a separate “Allowed values” column/section for readability.packages/apps/nats/values.schema.json (1)
55-58: Schema description in sync – add enum for parity with docsSee prior comment in
values.yaml; adding anenumhere would enforce the documented allowed values and prevent invalid presets at validation time.packages/apps/http-cache/values.yaml (1)
21-22: Consider restoring a minimal description forresourcesPresetThe comment now only lists allowed values; adding a short purpose description (e.g., “Predefined CPU/memory sizes”) would improve clarity without re-introducing verbosity.
Also applies to: 31-32
packages/apps/http-cache/README.md (1)
70-72: Missing description cell breaks the parameters table
haproxy.resourcescurrently has an empty Description column, causing an uneven table and possible markdown render issues.-| `haproxy.resources` | | `{}` | +| `haproxy.resources` | CPU/Memory resources map | `{}` |Apply the same fix for
nginx.resourcesbelow.packages/apps/http-cache/values.schema.json (1)
28-32: Empty string in JSON-Schemadescriptionis noisyAn empty description adds no value and clutters generated docs. Either supply a meaningful sentence or drop the
descriptionfield entirely.- "resources": { - "type": "object", - "description": "", - "default": {} - }, + "resources": { + "type": "object", + "description": "CPU/Memory resources map", + "default": {} + },packages/apps/kubernetes/values.yaml (1)
118-121: Example resource format now diverges from READMEHere the example shows a flat structure:
resources: cpu: 4000m memory: 4Gi…but the README (lines 124-135) still demonstrates the traditional
requests/limitsstructure.
Please make the two examples consistent to avoid user confusion.-## cpu: 4000m -## memory: 4Gi +## limits: +## cpu: 4000m +## memory: 4Gi +## requests: +## cpu: 100m +## memory: 512Mipackages/apps/postgres/values.yaml (1)
93-95: Trailing whitespace & potentially misleading example
- Line 95 is flagged by YAMLlint for trailing spaces – please trim.
- The commented-out example now shows
cpu/memorydirectly underresources. Most templates expect the canonical Kuberneteslimits/requestsstructure, e.g.:resources: limits: cpu: 4000m memory: 4GiIf the chart’s templates still expect that shape, the simplified example may mislead users. Verify the template rendering; if
limits/requestsare still required, restore the original hierarchy or add an explanatory note.packages/apps/postgres/values.schema.json (1)
125-129: Consider enforcing allowed presets via an enumThe description lists allowed values but the schema does not declare an
"enum"array. Adding it would give consumers (e.g., IDE autocompletion, CI validation) stronger guarantees:"resourcesPreset": { "type": "string", - "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", + "description": "Use a common resources preset when `resources` is not set explicitly.", + "enum": ["none", "nano", "micro", "small", "medium", "large", "xlarge", "2xlarge"], "default": "micro" }packages/apps/postgres/README.md (1)
73-80: Section misplacement
resourcesandresourcesPresetrows were appended under the Bootstrap parameters table. They are unrelated to bootstrapping and probably belong to their own “Resources parameters” section (or “Common parameters”). Moving them prevents confusion when scanning the docs.packages/apps/kafka/values.yaml (1)
36-37: Keep comment width consistent
Minor nit: wrap comment text at ~120 chars to avoid horizontal scrolling in many editors.packages/apps/tcp-balancer/values.yaml (1)
53-54: Description now clearer – consider enum validationGreat simplification of the
resourcesPresetexplanation.
Since you explicitly list the allowed preset values, consider addingenum:tovalues.schema.jsonfor stronger client-side validation (json-schema & Helm plugin users).packages/apps/tcp-balancer/README.md (1)
22-32: Table aligns with values.yaml – minor nitThe wording is crisp; however, there are two consecutive spaces in “enabling client networks whitelisting” which render a visual gap in Markdown tables.
Not critical, but worth trimming in the next doc sweep for consistency.packages/apps/ferretdb/values.yaml (2)
55-57: Strip trailing whitespace flagged by YAML lintYAMLlint reports trailing spaces on line 57. Cleaning them up keeps the repo lint-clean.
- # memory: 4Gi␠ + # memory: 4Gi
58-59: Schema and values file may drift on allowed preset valuesThe comment now explicitly lists the allowed presets. Consider enforcing the same list in
values.schema.jsonvia anenumfield to give users immediate validation feedback."resourcesPreset": { "type": "string", - "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", + "description": "Use a common resources preset when `resources` is not set explicitly.", + "enum": ["none","nano","micro","small","medium","large","xlarge","2xlarge"], "default": "nano" }packages/apps/ferretdb/README.md (1)
24-33: Correct typo “pereiodic” in backup descriptionTypo spotted in the updated table.
-| `backup.enabled` | Enable pereiodic backups | `false` | +| `backup.enabled` | Enable periodic backups | `false` |packages/apps/ferretdb/values.schema.json (1)
90-93: Consider addingenumto reinforce allowed presets at schema levelThe description calls out specific allowed values but the schema does not validate them. Enforcing the list prevents typos and mis-configuration.
- "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", + "description": "Use a common resources preset when `resources` is not set explicitly.", + "enum": ["none","nano","micro","small","medium","large","xlarge","2xlarge"],packages/apps/versions_map (1)
97-97: Possible missing 0.15.0 entry for postgres
postgreslists0.14.0(pinned) and then0.15.1(HEAD).
Unless 0.15.0 was deliberately skipped, please add it (even if it immediately points to the same hash) to keep version history complete.packages/apps/mysql/README.md (2)
88-88: Fix typo: “pereiodic” → “periodic”-| `backup.enabled` | Enable pereiodic backups | `false` | +| `backup.enabled` | Enable periodic backups | `false` |
96-97: Consider validatingresourcesPresetvaluesThe table documents an allowed list, but the chart’s JSON schema (and templates) do not currently enforce it. Users can still pass an unsupported string, leading to silent mis-configuration at deploy time.
Adding explicit validation (enum) invalues.schema.jsonwill catch mistakes early.packages/apps/mysql/values.yaml (2)
61-63: Remove trailing spaces to satisfy YAML lintLine 63 contains only whitespace, triggering
trailing-spaceslint errors.- # memory: 4Gi␠␠ + # memory: 4Gi
64-64: Docs vs schema mismatch forresourcesPresetThe comment advertises a fixed set of presets, but the schema does not enforce them. Either:
- Add an
enuminvalues.schema.json(preferred), or- Remove the allowed-values note here.
Keeping them in sync avoids user confusion.
packages/apps/vpn/values.yaml (2)
39-40: Keep schema / values in sync with allowed presets.The comment lists explicit allowed values, but the JSON schema does not enforce
them (see separate comment). Consider referencing the enum there to avoid
configuration typos slipping through.
34-40: ```shell
#!/usr/bin/env bashSearch for any nested resources usage in the vpn chart templates
rg -n ".Values.resources.(requests|limits)" packages/apps/vpn
</blockquote></details> <details> <summary>packages/apps/vpn/README.md (1)</summary><blockquote> `25-32`: **Good doc simplification – replicate the allowed-values table across all charts.** Nice tightening of the explanation for `resourcesPreset`. To maintain cross-chart consistency, ensure every app README got the exact same wording (including the allowed value list) so users don’t have to cross-compare. </blockquote></details> </blockquote></details> <details> <summary>📜 Review details</summary> **Configuration used: CodeRabbit UI** **Review profile: CHILL** **Plan: Pro** <details> <summary>📥 Commits</summary> Reviewing files that changed from the base of the PR and between 86fdb51236e0f697e8b75b9e29ddb63002614c73 and 654778a0c796363a4225f63ac47acc9641619116. </details> <details> <summary>📒 Files selected for processing (45)</summary> * `packages/apps/clickhouse/values.yaml` (1 hunks) * `packages/apps/ferretdb/Chart.yaml` (1 hunks) * `packages/apps/ferretdb/README.md` (1 hunks) * `packages/apps/ferretdb/values.schema.json` (1 hunks) * `packages/apps/ferretdb/values.yaml` (1 hunks) * `packages/apps/http-cache/Chart.yaml` (1 hunks) * `packages/apps/http-cache/README.md` (1 hunks) * `packages/apps/http-cache/values.schema.json` (2 hunks) * `packages/apps/http-cache/values.yaml` (1 hunks) * `packages/apps/kafka/README.md` (1 hunks) * `packages/apps/kafka/values.schema.json` (2 hunks) * `packages/apps/kafka/values.yaml` (2 hunks) * `packages/apps/kubernetes/Chart.yaml` (1 hunks) * `packages/apps/kubernetes/README.md` (1 hunks) * `packages/apps/kubernetes/values.schema.json` (4 hunks) * `packages/apps/kubernetes/values.yaml` (1 hunks) * `packages/apps/mysql/Chart.yaml` (1 hunks) * `packages/apps/mysql/README.md` (1 hunks) * `packages/apps/mysql/values.schema.json` (1 hunks) * `packages/apps/mysql/values.yaml` (1 hunks) * `packages/apps/nats/Chart.yaml` (1 hunks) * `packages/apps/nats/README.md` (1 hunks) * `packages/apps/nats/values.schema.json` (1 hunks) * `packages/apps/nats/values.yaml` (1 hunks) * `packages/apps/postgres/Chart.yaml` (1 hunks) * `packages/apps/postgres/README.md` (1 hunks) * `packages/apps/postgres/values.schema.json` (1 hunks) * `packages/apps/postgres/values.yaml` (1 hunks) * `packages/apps/rabbitmq/Chart.yaml` (1 hunks) * `packages/apps/rabbitmq/README.md` (1 hunks) * `packages/apps/rabbitmq/values.schema.json` (1 hunks) * `packages/apps/rabbitmq/values.yaml` (1 hunks) * `packages/apps/redis/Chart.yaml` (1 hunks) * `packages/apps/redis/README.md` (1 hunks) * `packages/apps/redis/values.schema.json` (1 hunks) * `packages/apps/redis/values.yaml` (1 hunks) * `packages/apps/tcp-balancer/Chart.yaml` (1 hunks) * `packages/apps/tcp-balancer/README.md` (1 hunks) * `packages/apps/tcp-balancer/values.schema.json` (1 hunks) * `packages/apps/tcp-balancer/values.yaml` (1 hunks) * `packages/apps/versions_map` (8 hunks) * `packages/apps/vpn/Chart.yaml` (1 hunks) * `packages/apps/vpn/README.md` (1 hunks) * `packages/apps/vpn/values.schema.json` (1 hunks) * `packages/apps/vpn/values.yaml` (1 hunks) </details> <details> <summary>🧰 Additional context used</summary> <details> <summary>🪛 YAMLlint (1.37.1)</summary> <details> <summary>packages/apps/ferretdb/values.yaml</summary> [error] 57-57: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/postgres/values.yaml</summary> [error] 95-95: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/nats/values.yaml</summary> [error] 70-70: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/mysql/values.yaml</summary> [error] 63-63: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/redis/values.yaml</summary> [error] 20-20: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/http-cache/values.yaml</summary> [error] 15-15: trailing spaces (trailing-spaces) --- [error] 20-20: trailing spaces (trailing-spaces) --- [error] 30-30: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/rabbitmq/values.yaml</summary> [error] 48-48: trailing spaces (trailing-spaces) </details> <details> <summary>packages/apps/kafka/values.yaml</summary> [error] 22-22: trailing spaces (trailing-spaces) --- [error] 35-35: trailing spaces (trailing-spaces) </details> </details> <details> <summary>🪛 GitHub Actions: Pre-Commit Checks</summary> <details> <summary>packages/apps/tcp-balancer/values.schema.json</summary> [error] 1-1: File 'values.schema.json.tmp' not found when running 'cat values.schema.json.tmp | jq ... > values.schema.json'. This caused failure in make generate step. </details> </details> </details> <details> <summary>⏰ Context from checks skipped due to timeout of 90000ms (1)</summary> * GitHub Check: Build </details> <details> <summary>🔇 Additional comments (25)</summary><blockquote> <details> <summary>packages/apps/rabbitmq/Chart.yaml (1)</summary> `19-19`: **Version bump looks good** Chart version correctly incremented to `0.7.1` following SemVer. No further action required. </details> <details> <summary>packages/apps/rabbitmq/values.schema.json (1)</summary> `37-38`: **Schema description update matches docs** Description now aligns with the simplified wording in `values.yaml` and `README.md`. Looks good. </details> <details> <summary>packages/apps/redis/Chart.yaml (1)</summary> `19-19`: **Patch-level version bump LGTM** The chart version increment is consistent with a non-breaking documentation change. No further action required. </details> <details> <summary>packages/apps/redis/values.yaml (1)</summary> `21-22`: **Clarified `resourcesPreset` wording looks good** The updated description accurately states the fallback behaviour and lists allowed values. No concerns. </details> <details> <summary>packages/apps/redis/README.md (1)</summary> `23-25`: **Documentation update approved** The rewritten note for `resourcesPreset` is clearer and consistent with `values.yaml` / JSON schema. Nice cleanup. </details> <details> <summary>packages/apps/redis/values.schema.json (1)</summary> `37-38`: **Schema description aligns with README/values.yaml** The simplified wording keeps the spec authoritative and avoids redundant advice. Looks good. </details> <details> <summary>packages/apps/nats/values.yaml (1)</summary> `65-70`: **Example no longer reflects Kubernetes resource structure – double-check template expectations** The commented example was flattened to two scalar keys (`cpu`, `memory`). Standard Kubernetes manifests expect: ```yaml resources: limits: cpu: 4000m memory: 4Gi requests: cpu: 2000m memory: 2GiIf the chart’s templates still assume the canonical
limits/requestslayout, end-users copying this example will deploy invalid manifests.
Verify the Helm templates; either revert to the nested example or update the templates & schema to accept the flat form.packages/apps/http-cache/Chart.yaml (1)
19-19: Chart patch-level bump LGTMThe version increment to
0.5.2is semantically correct for a documentation-only change.packages/apps/kubernetes/Chart.yaml (1)
19-19: Patch bump LGTM – please double-check whetherappVersionshould track a related change
versionhas been incremented from0.24.1→0.24.2, which is perfectly in line with a doc-only change.
If the underlying application (appVersion) also moved forward you may want to bump it as well; otherwise everything is fine.packages/apps/kubernetes/values.yaml (1)
114-121: Good call – allowed preset values are now explicitExplicitly listing the eight supported
resourcesPresetvalues clarifies usage and prevents invalid input. 👍packages/apps/kubernetes/README.md (1)
113-122: Table update is clear, but verify wording consistency across docsThe parameter table now mirrors the new description with the explicit value list – great.
Minor: the sentence “This value is ignored if the correspondingresourcesvalue is set.” (line 138-139) still exists and is useful; make sure the same note wasn’t accidentally removed from the comments invalues.yaml.packages/apps/kubernetes/values.schema.json (1)
26-39: Schema descriptions updated – matches the docsDescriptions now enumerate the eight allowed presets, matching the existing
enumlists. No further action required.Also applies to: 51-64, 76-89, 104-118
packages/apps/postgres/Chart.yaml (1)
19-20: Chart version bump looks correct
Patch-level increment (0.15.0➜0.15.1) is appropriate because the PR is doc-only and does not introduce breaking changes or new features.packages/apps/postgres/values.yaml (1)
96-97: Description update is fine
New wording clarifies the precedence betweenresourcesandresourcesPreset; no further action needed.packages/apps/kafka/README.md (1)
7-19: Looks good – wording now consistent across charts
The new wording clarifies when the preset is applied and explicitly lists allowed values – nice alignment with the other charts.packages/apps/kafka/values.yaml (1)
23-24: Example shape may no longer match K8sresourcesobject
If the templates still expect the canonicalresources: limits: cpu: … requests: …structure, this flattened example will confuse users. Confirm that the chart accepts the simplified form; otherwise, revert to the canonical example.
packages/apps/tcp-balancer/Chart.yaml (1)
19-19: Chart version bump looks correctChart
versionwas incremented to0.4.2with no other manifest changes – this is the minimum required change when templates/docs are updated.
Remember to add a matching entry in the chart’sCHANGELOG.md(if maintained) so downstream consumers can track what changed.packages/apps/tcp-balancer/values.yaml (1)
50-53: Verify resource-example format matches templating logicThe commented example was flattened from the canonical Kubernetes structure:
resources: # cpu: 4000m # memory: 4GiIf the templates still expect the standard
requests/limitsnesting, users copying this snippet will end up with invalid manifests.
Please confirm the templates render these flat keys, or revert to the nested example for accuracy.packages/apps/tcp-balancer/values.schema.json (1)
68-70: ```shell
#!/bin/bash
set -eecho "🔍 Searching for values.schema.json.tmp in tcp-balancer package..."
find packages/apps/tcp-balancer -type f -name 'values.schema.json.tmp' -print || echo "⚠️ Not found"echo
echo "📂 Listing all .tmp files in the repo..."
find . -type f -name '*.tmp' | sed 's/^/ - /' || echo "No .tmp files found"echo
echo "📝 Checking for a 'generate' target in the Makefile..."
grep -R "generate" -n Makefile || echo "Makefile or 'generate' target not found"</details> <details> <summary>packages/apps/ferretdb/Chart.yaml (1)</summary> `19-19`: **Chart patch-level bump looks good** The version increment to `0.7.1` is consistent with a documentation-only change. No further action required. </details> <details> <summary>packages/apps/versions_map (3)</summary> `53-53`: **Gap in version sequence – was 0.24.1 intentionally skipped?** `kubernetes` jumps from 0.24.0 → 0.24.2 (`HEAD`). If 0.24.1 was ever tagged or merged separately, it should appear here; otherwise, consider bumping to 0.24.1 to avoid confusion for downstream tooling that expects monotonic sequences. --- `65-66`: **Sequence & hash consistency look good** `mysql`, `nats`, `rabbitmq`, `redis`, `tcp-balancer`, and `vpn` all follow the expected pattern: pin the just-released version to `62cb694d` and create the next `HEAD` placeholder. No issues spotted here. Also applies to: 76-77, 108-109, 119-120, 125-126, 167-168 --- `27-36`: ```shell #!/bin/bash set -euo pipefail for pkg in ferretdb http-cache; do chart_file=$(fd -t f "^Chart.yaml$" "packages/apps/$pkg" | head -n1) echo "📦 $pkg → $(basename "$chart_file")" grep -E '^(version|appVersion):' "$chart_file" echo donepackages/apps/mysql/Chart.yaml (1)
19-19: Chart version bump looks goodPatch-level increment to
0.8.1is appropriate for non-functional doc updates.
Please remember to regenerate/commitChart.lock(if present) and update any CHANGELOG release notes so that downstream automation picks up the new version.packages/apps/vpn/Chart.yaml (1)
17-20: ```shell
#!/usr/bin/env bashCheck for CHANGELOG.md presence and entries for version 0.6.2
fd -t f -i CHANGELOG.md || echo "No CHANGELOG.md found"
grep -R "0\.6\.2" -n CHANGELOG.md || echo "No entry for 0.6.2 in CHANGELOG.md"</details> </blockquote></details> </details> <!-- This is an auto-generated comment by CodeRabbit for review status -->
| # cpu: 4000m | ||
| # memory: 4Gi | ||
|
|
There was a problem hiding this comment.
Trailing whitespace violates YAMLlint rule
values.yaml currently trips the trailing-spaces rule (see static-analysis hint).
Strip the extra spaces to keep the file linter-clean.
- # cpu: 4000m␠
- # memory: 4Gi␠
+ # cpu: 4000m
+ # memory: 4Gi📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| # cpu: 4000m | |
| # memory: 4Gi | |
| # cpu: 4000m | |
| # memory: 4Gi | |
🧰 Tools
🪛 YAMLlint (1.37.1)
[error] 70-70: trailing spaces
(trailing-spaces)
🤖 Prompt for AI Agents
In packages/apps/nats/values.yaml around lines 68 to 70, there are trailing
spaces after the commented resource limits. Remove any trailing whitespace at
the end of these lines to comply with the YAMLlint trailing-spaces rule and keep
the file clean.
| ## @param haproxy.resources | ||
| resources: {} | ||
| # resources: | ||
| # limits: | ||
| # cpu: 4000m | ||
| # memory: 4Gi | ||
| # requests: | ||
| # cpu: 100m | ||
| # memory: 512Mi | ||
| # cpu: 4000m | ||
| # memory: 4Gi | ||
|
|
There was a problem hiding this comment.
YAML-lint fails due to trailing spaces — remove them
yamllint reports trailing whitespace on the marked lines. CI will fail until these are cleaned.
- ## @param haproxy.resources␠
+ ## @param haproxy.resources
...
- # cpu: 4000m␠
+ # cpu: 4000m
- # memory: 4Gi␠
+ # memory: 4Gi
...
- # cpu: 4000m␠
+ # cpu: 4000m
- # memory: 4Gi␠
+ # memory: 4GiAlso applies to: 28-30
🧰 Tools
🪛 YAMLlint (1.37.1)
[error] 15-15: trailing spaces
(trailing-spaces)
[error] 20-20: trailing spaces
(trailing-spaces)
🤖 Prompt for AI Agents
In packages/apps/http-cache/values.yaml around lines 15 to 20 and also lines 28
to 30, there are trailing spaces causing yamllint to fail. Remove all trailing
whitespace characters at the end of these lines to fix the linting errors and
ensure the CI passes.
| "resourcesPreset": { | ||
| "type": "string", | ||
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | ||
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | ||
| "default": "small" | ||
| } |
There was a problem hiding this comment.
🛠️ Refactor suggestion
Duplicate of comment above – apply enum to Zookeeper block as well
🤖 Prompt for AI Agents
In packages/apps/kafka/values.schema.json around lines 63 to 67, the
"resourcesPreset" property defines allowed values in the description but lacks
an explicit "enum" array to enforce these values. Add an "enum" field listing
the allowed values (none, nano, micro, small, medium, large, xlarge, 2xlarge) to
the "resourcesPreset" property in the Zookeeper block as well to ensure schema
validation enforces these options.
| "resourcesPreset": { | ||
| "type": "string", | ||
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | ||
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | ||
| "default": "small" | ||
| } |
There was a problem hiding this comment.
🛠️ Refactor suggestion
Add enum to enforce the “allowed values” you document
The description lists eight allowed presets, but nothing in the schema prevents a misspelling such as "smal" from passing validation.
"resourcesPreset": {
"type": "string",
- "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)",
+ "description": "Use a common resources preset when `resources` is not set explicitly.",
+ "enum": ["none", "nano", "micro", "small", "medium", "large", "xlarge", "2xlarge"],
"default": "small"
}Apply the same change to the zookeeper.resourcesPreset block below to keep the schema self-validating.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "resourcesPreset": { | |
| "type": "string", | |
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | |
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | |
| "default": "small" | |
| } | |
| "resourcesPreset": { | |
| "type": "string", | |
| "description": "Use a common resources preset when `resources` is not set explicitly.", | |
| "enum": ["none", "nano", "micro", "small", "medium", "large", "xlarge", "2xlarge"], | |
| "default": "small" | |
| } |
🤖 Prompt for AI Agents
In packages/apps/kafka/values.schema.json around lines 33 to 37, add an "enum"
property to the "resourcesPreset" schema to explicitly list the allowed string
values ("none", "nano", "micro", "small", "medium", "large", "xlarge",
"2xlarge") to enforce validation against misspellings. Then, locate the
"zookeeper.resourcesPreset" block further down in the file and apply the same
"enum" property with the identical allowed values to ensure consistent
self-validation for both fields.
| # cpu: 4000m | ||
| # memory: 4Gi | ||
|
|
There was a problem hiding this comment.
Trailing spaces – same issue as above
Line 35 ends with unnecessary spaces.
- # memory: 4Gi
+ # memory: 4Gi📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| # cpu: 4000m | |
| # memory: 4Gi | |
| # cpu: 4000m | |
| # memory: 4Gi |
🧰 Tools
🪛 YAMLlint (1.37.1)
[error] 35-35: trailing spaces
(trailing-spaces)
🤖 Prompt for AI Agents
In packages/apps/kafka/values.yaml at line 35, remove the trailing spaces at the
end of the line to clean up unnecessary whitespace.
| # cpu: 4000m | ||
| # memory: 4Gi | ||
|
|
There was a problem hiding this comment.
Trailing spaces flagged by YAML-lint
Lines 21 – 22 contain extra whitespace, causing lint errors.
- # cpu: 4000m
- # memory: 4Gi
+ # cpu: 4000m
+ # memory: 4Gi📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| # cpu: 4000m | |
| # memory: 4Gi | |
| # cpu: 4000m | |
| # memory: 4Gi |
🧰 Tools
🪛 YAMLlint (1.37.1)
[error] 22-22: trailing spaces
(trailing-spaces)
🤖 Prompt for AI Agents
In packages/apps/kafka/values.yaml at lines 20 to 22, remove the trailing spaces
at the end of lines 21 and 22 to fix the YAML lint errors caused by extra
whitespace.
| "resourcesPreset": { | ||
| "type": "string", | ||
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | ||
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | ||
| "default": "nano" |
There was a problem hiding this comment.
Schema should restrict resourcesPreset to the documented allowed values
Without an enum, any arbitrary string is accepted, potentially breaking template rendering.
"resourcesPreset": {
"type": "string",
- "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)",
+ "description": "Use a common resources preset when `resources` is not set explicitly.",
+ "enum": ["none", "nano", "micro", "small", "medium", "large", "xlarge", "2xlarge"],
"default": "nano"
}📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "resourcesPreset": { | |
| "type": "string", | |
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | |
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | |
| "default": "nano" | |
| "resourcesPreset": { | |
| "type": "string", | |
| "description": "Use a common resources preset when `resources` is not set explicitly.", | |
| "enum": ["none", "nano", "micro", "small", "medium", "large", "xlarge", "2xlarge"], | |
| "default": "nano" | |
| } |
🤖 Prompt for AI Agents
In packages/apps/mysql/values.schema.json around lines 75 to 78, the
resourcesPreset property is defined as a string but lacks an enum to restrict
its values. Add an enum listing the allowed values: none, nano, micro, small,
medium, large, xlarge, and 2xlarge to ensure only these specific strings are
accepted and prevent invalid inputs that could break template rendering.
| "resourcesPreset": { | ||
| "type": "string", | ||
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | ||
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | ||
| "default": "nano" | ||
| } |
There was a problem hiding this comment.
🛠️ Refactor suggestion
Add an enum to enforce the allowed resourcesPreset values.
The docstring lists allowed presets, but the schema will happily accept
arbitrary strings. Tighten validation by introducing an enum field.
"resourcesPreset": {
"type": "string",
- "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)",
+ "description": "Use a common resources preset when `resources` is not set explicitly.",
+ "enum": [
+ "none",
+ "nano",
+ "micro",
+ "small",
+ "medium",
+ "large",
+ "xlarge",
+ "2xlarge"
+ ],
"default": "nano"
}📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| "resourcesPreset": { | |
| "type": "string", | |
| "description": "Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production).", | |
| "description": "Use a common resources preset when `resources` is not set explicitly. (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge)", | |
| "default": "nano" | |
| } | |
| "resourcesPreset": { | |
| "type": "string", | |
| "description": "Use a common resources preset when `resources` is not set explicitly.", | |
| "enum": [ | |
| "none", | |
| "nano", | |
| "micro", | |
| "small", | |
| "medium", | |
| "large", | |
| "xlarge", | |
| "2xlarge" | |
| ], | |
| "default": "nano" | |
| } |
🤖 Prompt for AI Agents
In packages/apps/vpn/values.schema.json around lines 33 to 37, the
resourcesPreset property currently allows any string, but the description lists
specific allowed values. To fix this, add an enum field to the resourcesPreset
schema with the allowed values: none, nano, micro, small, medium, large, xlarge,
and 2xlarge. This will enforce validation to accept only these preset strings.
Mirroring cozystack/cozystack#1106 Signed-off-by: Nick Volynkin <nick.volynkin@gmail.com>
Mirroring changes from: * cozystack/cozystack#1103 * cozystack/cozystack#1105 * cozystack/cozystack#1106 Signed-off-by: Nick Volynkin <nick.volynkin@gmail.com>
Mirroring changes from: * cozystack/cozystack#1103 * cozystack/cozystack#1105 * cozystack/cozystack#1106 Signed-off-by: Nick Volynkin <nick.volynkin@gmail.com>
Signed-off-by: Andrei Kvapil kvapss@gmail.com
Summary by CodeRabbit
Documentation
resourcesPresetparameter across all app documentation, emphasizing it is used only whenresourcesis not explicitly set and listing allowed values.Style
Chores