diff --git a/cmd/zitadel/caos_local.sh b/cmd/zitadel/caos_local.sh index 6ecc0814af..28db695887 100755 --- a/cmd/zitadel/caos_local.sh +++ b/cmd/zitadel/caos_local.sh @@ -61,4 +61,7 @@ export ZITADEL_SHORT_CACHE_SHARED_MAXAGE=15m export ZITADEL_CONSOLE_ENV_DIR=../../console/src/assets/ #Org -export ZITADEL_DEFAULT_DOMAIN=zitadel.ch \ No newline at end of file +export ZITADEL_DEFAULT_DOMAIN=zitadel.ch + +#Tracing +export TRACING_TYPE=google \ No newline at end of file diff --git a/cmd/zitadel/startup.yaml b/cmd/zitadel/startup.yaml index 345d83f3f1..895c1a7e13 100644 --- a/cmd/zitadel/startup.yaml +++ b/cmd/zitadel/startup.yaml @@ -4,7 +4,7 @@ Log: Format: text Tracing: - Type: google + Type: $TRACING_TYPE Config: ProjectID: $ZITADEL_TRACING_PROJECT_ID MetricPrefix: ZITADEL-V1 diff --git a/internal/tracing/config/config.go b/internal/tracing/config/config.go index 3681ddf107..0f25feea6f 100644 --- a/internal/tracing/config/config.go +++ b/internal/tracing/config/config.go @@ -17,6 +17,8 @@ type TracingConfig struct { var tracer = map[string]func() tracing.Config{ "google": func() tracing.Config { return &tracing_g.Config{} }, "log": func() tracing.Config { return &tracing_log.Config{} }, + "none": func() tracing.Config { return &NoTracing{} }, + "": func() tracing.Config { return &NoTracing{} }, } func (c *TracingConfig) UnmarshalJSON(data []byte) error { @@ -57,3 +59,9 @@ func newTracingConfig(tracerType string, configData []byte) (tracing.Config, err return tracingConfig, nil } + +type NoTracing struct{} + +func (_ *NoTracing) NewTracer() error { + return nil +}