Skip to content

Commit

Permalink
Debug level in gitops deployment
Browse files Browse the repository at this point in the history
* don't set debug level if default
  • Loading branch information
manno committed Jul 3, 2024
1 parent 3394e0e commit ba92a32
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions charts/fleet/templates/deployment_gitjob.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ spec:
- "{{ template "system_default_registry" $ }}{{ $.Values.image.repository }}:{{ $.Values.image.tag }}"
{{- if $.Values.debug }}
- --debug
- --debug-level
- {{ quote $.Values.debugLevel }}
{{- end }}
{{- if $shard.id }}
- --shard-id
Expand Down
2 changes: 1 addition & 1 deletion internal/cmd/debug.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func (c *DebugConfig) OverrideZapOpts(zopts *crzap.Options) *crzap.Options {

zopts.Development = c.Debug

if c.Debug {
if c.Debug && c.DebugLevel > 0 {
zopts.Level = zapcore.Level(c.DebugLevel * -1)
}

Expand Down

0 comments on commit ba92a32

Please sign in to comment.