Skip to content

Adapt for memos 0.30.0 - #5

Open
RobSlgm wants to merge 8 commits into
usememos:mainfrom
RobSlgm:feature/app-config
Open

Adapt for memos 0.30.0#5
RobSlgm wants to merge 8 commits into
usememos:mainfrom
RobSlgm:feature/app-config

Conversation

@RobSlgm

@RobSlgm RobSlgm commented Aug 8, 2026

Copy link
Copy Markdown

Description

Updates the Helm chart to support Memos v0.30.0, introducing Kubernetes Gateway API support and expanded configuration options.

Key Changes

  • HTTPRoute Support: Added support for Kubernetes Gateway API HTTPRoute resources.
  • Database Configuration: Added Helm values to configure database settings directly.
  • Deployed Application Configuration: Added support for passing application configuration.

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: f16b9693-eb0b-445f-a5c0-a92eb1b702a7

📥 Commits

Reviewing files that changed from the base of the PR and between dbb5a4c and cb7354a.

📒 Files selected for processing (1)
  • templates/deployment.yaml
🚧 Files skipped from review as they are similar to previous changes (1)
  • templates/deployment.yaml

Walkthrough

The Helm chart adds managed application settings through generated ConfigMaps and Deployment mounts. It adds database, instance, and grouped application configuration values. It adds conditional Gateway API HTTPRoute rendering and installation notes. README documentation covers database, application, and OAuth2 identity-provider configuration. The chart version becomes 0.3.0, the application version becomes 0.30.0, and the default image tag becomes empty.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: adapting the Helm chart for Memos 0.30.0.
Description check ✅ Passed The description accurately summarizes Memos 0.30.0 support, HTTPRoute support, database configuration, and application configuration.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 5

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Line 53: Replace every newly added tilde code fence in README.md with backtick
fences, including the fences near the referenced sections, so the README
complies with the configured MD048 Markdownlint rule.

In `@templates/deployment.yaml`:
- Around line 79-89: The deployment template currently renders duplicate
MEMOS_DSN entries when both database.connectionString and
database.existingSecret are configured. Make these inputs mutually exclusive by
changing the conditional flow around database.connectionString and
database.existingSecret, preferably failing template rendering when both are
nonempty; otherwise use an else-if structure and document the connectionString
precedence in the existing configuration documentation.

In `@templates/httproute.yaml`:
- Around line 24-37: Update the HTTPRoute rules loop to emit a list item
immediately for each entry in .Values.httpRoute.rules. Nest matches, filters,
and backendRefs under that item, while allowing rules without matches to remain
valid and use the default "/" prefix behavior.

In `@templates/NOTES.txt`:
- Around line 2-14: Update the HTTPRoute visit message near APP_HOSTNAME to
avoid hardcoding https://; derive the scheme from a configurable value or print
a scheme-neutral hostname and path. Preserve the existing hostname and rule-path
rendering for both HTTP and HTTPS listener configurations.

In `@templates/settings.yaml`:
- Around line 8-33: Update templates/settings.yaml (lines 8-33) so
credential-bearing settings, especially settings.idps[*].config with
clientSecret, are supplied through Secret-backed settings-file support rather
than serialized into the ConfigMap; retain only non-sensitive settings in the
ConfigMap. Update README.md (lines 101-130) to replace the plaintext
clientSecret example with the Secret-backed configuration flow.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 6b3d290a-e7c2-4adb-99c6-a5f1411e3d4f

📥 Commits

Reviewing files that changed from the base of the PR and between 8a33612 and 93f151b.

📒 Files selected for processing (8)
  • CHANGELOG.md
  • Chart.yaml
  • README.md
  • templates/NOTES.txt
  • templates/deployment.yaml
  • templates/httproute.yaml
  • templates/settings.yaml
  • values.yaml

Comment thread README.md Outdated
Comment thread templates/deployment.yaml Outdated
Comment on lines +79 to +89
{{- if .Values.database.connectionString }}
- name: MEMOS_DSN
value: {{ .Values.database.connectionString }}
{{- end }}
{{- if .Values.database.existingSecret }}
- name: MEMOS_DSN
valueFrom:
secretKeyRef:
name: {{ .Values.database.existingSecret.name }}
key: {{ .Values.database.existingSecret.key }}
{{- end }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🌐 Web query:

According to the current Kubernetes API documentation, what is the behavior when a container env list contains multiple EnvVar entries with the same name?

💡 Result:

According to the Kubernetes API documentation and established behavior, when a container's environment variable list (env) contains multiple entries with the same name, the values defined in the env list take precedence over values defined in envFrom [1][2][3]. While Kubernetes allows these duplicates to be persisted, they are generally discouraged [4][5]. The behavior associated with duplicate env entries is as follows: 1. Precedence: Values defined explicitly in the env list take precedence over those defined via envFrom [1][2][3]. 2. Patching and Updates: The presence of duplicate names in the env list can cause significant issues with kubectl apply and other patching mechanisms [4][5]. Because the env list uses the name field as a merge key, these tools often treat the key as ambiguous [5]. Consequently, attempting to update or remove one duplicate entry can result in all entries with that name being deleted or cause patch errors [4][5][6][7]. 3. Validation: Historically, Kubernetes has not strictly enforced uniqueness for the name field within the env list at the API level, allowing such configurations to be created and run [7]. However, it is strongly recommended to avoid duplicate names to prevent unexpected application behavior and operational issues with tooling [4][5]. Users are advised to maintain unique names for all environment variables within a container's configuration [4][5].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== locate deployment.yaml and values docs =="
fd -a 'deployment.yaml|README|values\.yaml|\.yaml$' . | sed 's#^\./##' | head -200

echo
echo "== templates/deployment.yaml relevant section =="
if [ -f templates/deployment.yaml ]; then
  nl -ba templates/deployment.yaml | sed -n '60,105p'
else
  fd -a 'deployment.yaml' .
fi

echo
echo "== search MEMOS_DSN and database values doc =="
rg -n "MEMOS_DSN|database:|existingSecret|connectionString|existingSecret:" -S .

Repository: usememos/helm

Length of output: 774


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== templates/deployment.yaml relevant section =="
sed -n '60,105p' templates/deployment.yaml

echo
echo "== search MEMOS_DSN and database values doc =="
rg -n "MEMOS_DSN|database:|existingSecret|connectionString|existingSecret:" -S .

echo
echo "== values.yaml database section =="
sed -n '1,160p' values.yaml

Repository: usememos/helm

Length of output: 5939


Make MEMOS_DSN inputs mutually exclusive.

values.yaml and README.md present database.connectionString and database.existingSecret as an either-or choice. If both are set, this template emits two MEMOS_DSN env entries; the connectionString value will take precedence over the secretKeyRef, but Kubernetes still keeps both entries and can make later kubectl apply updates ambiguous. Fail when both are nonempty, or replace the second block with else if so connectionString takes precedence and document that precedence.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@templates/deployment.yaml` around lines 79 - 89, The deployment template
currently renders duplicate MEMOS_DSN entries when both
database.connectionString and database.existingSecret are configured. Make these
inputs mutually exclusive by changing the conditional flow around
database.connectionString and database.existingSecret, preferably failing
template rendering when both are nonempty; otherwise use an else-if structure
and document the connectionString precedence in the existing configuration
documentation.

Comment thread templates/httproute.yaml
Comment thread templates/NOTES.txt
Comment thread templates/settings.yaml Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
templates/deployment.yaml (1)

19-19: 🩺 Stability & Availability | 🔵 Trivial

Document the restart requirement for subPath Secret rotation.

checksum/settings hashes templates/settings.yaml, so it does not track changes in an external existingSecret. The Secret is mounted with subPath: setting, and Memos loading files under /etc/secrets applies once at startup. A rotated Secret stays stale unless the Helm deployer restarts each memos Pod. Document this in README.md or add a supported rollout path.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@templates/deployment.yaml` at line 19, Document in README.md that rotating an
external existingSecret requires restarting each memos Pod because the
subPath-mounted Secret is loaded only at startup and checksum/settings does not
detect external Secret changes; alternatively, add a supported Helm rollout
mechanism that performs this restart during Secret rotation.

Source: MCP tools

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@templates/deployment.yaml`:
- Line 111: Update the database connection string value in the deployment
template to pass .Values.database.connectionString through Helm’s quote function
before embedding it in YAML, preserving it as a string during rendering.

---

Nitpick comments:
In `@templates/deployment.yaml`:
- Line 19: Document in README.md that rotating an external existingSecret
requires restarting each memos Pod because the subPath-mounted Secret is loaded
only at startup and checksum/settings does not detect external Secret changes;
alternatively, add a supported Helm rollout mechanism that performs this restart
during Secret rotation.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: ee1af937-b8df-4388-9800-d8aeae504af4

📥 Commits

Reviewing files that changed from the base of the PR and between 93f151b and dbb5a4c.

📒 Files selected for processing (5)
  • README.md
  • templates/NOTES.txt
  • templates/deployment.yaml
  • templates/settings.yaml
  • values.yaml
🚧 Files skipped from review as they are similar to previous changes (3)
  • templates/NOTES.txt
  • values.yaml
  • README.md

Comment thread templates/deployment.yaml Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant