From 247146f8dd7968eb291591919201fc8805269fd1 Mon Sep 17 00:00:00 2001 From: Hugo <10965479+hugoghx@users.noreply.github.com> Date: Wed, 18 Sep 2024 18:28:55 +0100 Subject: [PATCH] fixup! feat(service): Add support for host plugin AssumeRole --- plugin/service/host/plugin.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/plugin/service/host/plugin.go b/plugin/service/host/plugin.go index fdb40a0..944523a 100644 --- a/plugin/service/host/plugin.go +++ b/plugin/service/host/plugin.go @@ -669,9 +669,10 @@ func awsInstanceToHost(instance types.Instance) (*pb.ListHostsResponseHost, erro return result, nil } -// dryRunValidation validates that the IAM role policy attached to the given secrets of the -// storage bucket has the minimum required permissions needed for this plugin to function -// as expected. This function will attempt to list AWS hosts. +// dryRunValidation performs an AWS DescribeInstances call to verify the state's +// credentials, the host listing functionality as well as the filters, if any +// are passed in. This function can therefore be used for both host catalog and +// host set validation. func dryRunValidation(ctx context.Context, state *awsCatalogPersistedState, filters ...types.Filter) *status.Status { if state == nil { return status.New(codes.InvalidArgument, "persisted state is required")