From d8de875b5c05ce810e66a166e5cfd463f5a1cb82 Mon Sep 17 00:00:00 2001 From: Stamsy Date: Fri, 13 Dec 2024 14:33:56 +0200 Subject: [PATCH] add ssm endpoint to aws credentials --- .../nodes-base/credentials/Aws.credentials.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/packages/nodes-base/credentials/Aws.credentials.ts b/packages/nodes-base/credentials/Aws.credentials.ts index bb7b30d4cf..77589cb5f9 100644 --- a/packages/nodes-base/credentials/Aws.credentials.ts +++ b/packages/nodes-base/credentials/Aws.credentials.ts @@ -139,6 +139,7 @@ export type AwsCredentialsType = { sesEndpoint?: string; sqsEndpoint?: string; s3Endpoint?: string; + ssmEndpoint?: string; }; // Some AWS services are global and don't have a region @@ -295,6 +296,19 @@ export class Aws implements ICredentialType { default: '', placeholder: 'https://s3.{region}.amazonaws.com', }, + { + displayName: 'SSM Endpoint', + name: 'ssmEndpoint', + description: 'Endpoint for AWS Systems Manager (SSM)', + type: 'string', + displayOptions: { + show: { + customEndpoints: [true], + }, + }, + default: '', + placeholder: 'https://ssm.{region}.amazonaws.com', + }, ]; async authenticate( @@ -357,6 +371,8 @@ export class Aws implements ICredentialType { endpointString = credentials.sqsEndpoint; } else if (service) { endpointString = `https://${service}.${region}.amazonaws.com`; + } else if (service === 'ssm' && credentials.ssmEndpoint) { + endpointString = credentials.ssmEndpoint; } endpoint = new URL(endpointString!.replace('{region}', region) + path); } else {