diff --git a/typescript/infra/scripts/deploy-infra-external-secrets.ts b/typescript/infra/scripts/deploy-infra-external-secrets.ts index 91ab37ec3..6bc0e9b1f 100644 --- a/typescript/infra/scripts/deploy-infra-external-secrets.ts +++ b/typescript/infra/scripts/deploy-infra-external-secrets.ts @@ -1,11 +1,16 @@ import { runExternalSecretsHelmCommand } from '../src/infrastructure/external-secrets/external-secrets'; import { HelmCommand } from '../src/utils/helm'; -import { getCoreEnvironmentConfig, getEnvironment } from './utils'; +import { + assertCorrectKubeContext, + getCoreEnvironmentConfig, + getEnvironment, +} from './utils'; async function main() { const environment = await getEnvironment(); const config = getCoreEnvironmentConfig(environment); + await assertCorrectKubeContext(config); return runExternalSecretsHelmCommand( HelmCommand.InstallOrUpgrade, config.infra, diff --git a/typescript/infra/scripts/deploy-infra-monitoring.ts b/typescript/infra/scripts/deploy-infra-monitoring.ts index 1f8517620..9a2133b49 100644 --- a/typescript/infra/scripts/deploy-infra-monitoring.ts +++ b/typescript/infra/scripts/deploy-infra-monitoring.ts @@ -1,11 +1,16 @@ import { runPrometheusHelmCommand } from '../src/infrastructure/monitoring/prometheus'; import { HelmCommand } from '../src/utils/helm'; -import { getCoreEnvironmentConfig, getEnvironment } from './utils'; +import { + assertCorrectKubeContext, + getCoreEnvironmentConfig, + getEnvironment, +} from './utils'; async function main() { const environment = await getEnvironment(); const config = getCoreEnvironmentConfig(environment); + await assertCorrectKubeContext(config); return runPrometheusHelmCommand( HelmCommand.InstallOrUpgrade, config.infra,