diff --git a/charts/openab/templates/configmap.yaml b/charts/openab/templates/configmap.yaml index 2ca6aa6c..43e895e3 100644 --- a/charts/openab/templates/configmap.yaml +++ b/charts/openab/templates/configmap.yaml @@ -112,8 +112,8 @@ data: session_ttl_hours = {{ ($cfg.pool).sessionTtlHours | default 24 }} [reactions] - enabled = {{ ($cfg.reactions).enabled | default true }} - remove_after_reply = {{ ($cfg.reactions).removeAfterReply | default false }} + enabled = {{ if hasKey ($cfg.reactions) "enabled" }}{{ ($cfg.reactions).enabled }}{{ else }}true{{ end }} + remove_after_reply = {{ if hasKey ($cfg.reactions) "removeAfterReply" }}{{ ($cfg.reactions).removeAfterReply }}{{ else }}false{{ end }} {{- if ($cfg.reactions).toolDisplay }} {{- if not (has ($cfg.reactions).toolDisplay (list "full" "compact" "none")) }} {{- fail (printf "agents.%s.reactions.toolDisplay must be one of: full, compact, none — got: %s" $name ($cfg.reactions).toolDisplay) }} @@ -163,14 +163,14 @@ data: {{- if or ($cfg.cronjobs) (($cfg.cron).usercronEnabled) (($cfg.cron).usercronPath) }} [cron] - usercron_enabled = {{ (($cfg.cron).usercronEnabled) | default false }} + usercron_enabled = {{ if hasKey ($cfg.cron) "usercronEnabled" }}{{ (($cfg.cron).usercronEnabled) }}{{ else }}false{{ end }} {{- if (($cfg.cron).usercronPath) }} usercron_path = {{ ($cfg.cron).usercronPath | toJson }} {{- end }} {{- range ($cfg.cronjobs) }} [[cron.jobs]] - enabled = {{ .enabled | default true }} + enabled = {{ if hasKey . "enabled" }}{{ .enabled }}{{ else }}true{{ end }} schedule = {{ .schedule | toJson }} channel = {{ .channel | toJson }} message = {{ .message | toJson }} diff --git a/charts/openab/values.yaml b/charts/openab/values.yaml index c60ea39e..54661a38 100644 --- a/charts/openab/values.yaml +++ b/charts/openab/values.yaml @@ -206,7 +206,7 @@ agents: # - schedule: "0 9 * * 1-5" # channel: "123456789" # message: "summarize yesterday's merged PRs" - # enabled: true # set to false to disable this job without removing it + # enabled: true # false = skip scheduling (job config is still validated at startup) # platform: "discord" # senderName: "DailyOps" # timezone: "Asia/Taipei"