From b259b54c1e622eead0f2144b3e94383ca2940c66 Mon Sep 17 00:00:00 2001 From: Pablo Carle Date: Mon, 23 Dec 2024 14:01:14 +0100 Subject: [PATCH] zosmf static def scheme in attls Signed-off-by: Pablo Carle --- bin/libs/component.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/bin/libs/component.ts b/bin/libs/component.ts index 5f5bbe5160..bab68185d1 100644 --- a/bin/libs/component.ts +++ b/bin/libs/component.ts @@ -418,6 +418,22 @@ export function processComponentApimlStaticDefinitions(componentDir: string): bo const contents = xplatform.loadFileUTF8(path,xplatform.AUTO_DETECT); if (contents) { + const zosmfScheme = std.getenv("ZOSMF_SCHEME"); + const attls = std.getenv("ZWE_zowe_network_client_tls_attls"); + const schemeEnv = std.getenv("ZWE_zOSMF_scheme"); + + let scheme = "https"; + + if (zosmfScheme) { + scheme = zosmfScheme; + } else if (schemeEnv) { + scheme = schemeEnv; + } else if (attls) { + scheme = "http"; + } + + std.setenv('ZOSMF_SCHEME', scheme); + const resolvedContents = varlib.resolveShellTemplate(contents); const zweCliParameterHaInstance=std.getenv("ZWE_CLI_PARAMETER_HA_INSTANCE");