diff --git a/cluster/pulumi/infra/src/config.ts b/cluster/pulumi/infra/src/config.ts index fb14964180..a9c192c537 100644 --- a/cluster/pulumi/infra/src/config.ts +++ b/cluster/pulumi/infra/src/config.ts @@ -92,6 +92,7 @@ export const InfraConfigSchema = z.object({ }), istio: z.object({ enableIngressAccessLogging: z.boolean(), + enableClusterAccessLogging: z.boolean().default(false), }), extraCustomResources: z.object({}).catchall(z.any()).default({}), }), diff --git a/cluster/pulumi/infra/src/istio.ts b/cluster/pulumi/infra/src/istio.ts index 775ecf992f..923276cd0c 100644 --- a/cluster/pulumi/infra/src/istio.ts +++ b/cluster/pulumi/infra/src/istio.ts @@ -100,10 +100,8 @@ function configureIstiod( }, // https://istio.io/latest/docs/reference/config/istio.mesh.v1alpha1/ meshConfig: { - // Uncomment to turn on access logging across the entire cluster (we disabled it by default to reduce cost): - // accessLogFile: '/dev/stdout', // taken from https://github.com/istio/istio/issues/37682 - accessLogFile: '', + accessLogFile: infraConfig.istio.enableClusterAccessLogging ? '/dev/stdout' : '', accessLogEncoding: 'JSON', // https://istio.io/latest/docs/ops/integrations/prometheus/#option-1-metrics-merging disable as we don't use annotations enablePrometheusMerge: false,