diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/cloud_project_handler.ts b/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/cloud_project_handler.ts index 2d8c97da44896..fb6b0ac0f5e9b 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/cloud_project_handler.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/cloud_project_handler.ts @@ -41,9 +41,15 @@ export class CloudHandler extends ProjectHandler { } // The qualityGate variable has been added here to ensure that when the quality gate runs, there will be - // no kibana image override. The tests will be executed against the commit which is already promoted to QA. + // no kibana image override unless it is running for the daily monitoring. + // The tests will be executed against the commit which is already promoted to QA. + const monitoringQualityGate = + process.env.KIBANA_MKI_QUALITY_GATE_MONITORING && + process.env.KIBANA_MKI_QUALITY_GATE_MONITORING === '1'; const qualityGate = - process.env.KIBANA_MKI_QUALITY_GATE && process.env.KIBANA_MKI_QUALITY_GATE === '1'; + process.env.KIBANA_MKI_QUALITY_GATE && + process.env.KIBANA_MKI_QUALITY_GATE === '1' && + !monitoringQualityGate; const override = commit && commit !== '' ? commit : process.env.KIBANA_MKI_IMAGE_COMMIT; if (override && !qualityGate) { const kibanaOverrideImage = `${override?.substring(0, 12)}`; diff --git a/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/proxy_project_handler.ts b/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/proxy_project_handler.ts index adf8f6209a80f..100764b0504bc 100644 --- a/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/proxy_project_handler.ts +++ b/x-pack/plugins/security_solution/scripts/run_cypress/project_handler/proxy_project_handler.ts @@ -41,9 +41,15 @@ export class ProxyHandler extends ProjectHandler { } // The qualityGate variable has been added here to ensure that when the quality gate runs, there will be - // no kibana image override. The tests will be executed against the commit which is already promoted to QA. + // no kibana image override unless it is running for the daily monitoring. + // The tests will be executed against the commit which is already promoted to QA. + const monitoringQualityGate = + process.env.KIBANA_MKI_QUALITY_GATE_MONITORING && + process.env.KIBANA_MKI_QUALITY_GATE_MONITORING === '1'; const qualityGate = - process.env.KIBANA_MKI_QUALITY_GATE && process.env.KIBANA_MKI_QUALITY_GATE === '1'; + process.env.KIBANA_MKI_QUALITY_GATE && + process.env.KIBANA_MKI_QUALITY_GATE === '1' && + !monitoringQualityGate; const override = commit && commit !== '' ? commit : process.env.KIBANA_MKI_IMAGE_COMMIT; if (override && !qualityGate) { const kibanaOverrideImage = `${override?.substring(0, 12)}`;