From 225ecd79e11a2e70c412102a0ab9b98479e28ba9 Mon Sep 17 00:00:00 2001 From: hupe1980 Date: Tue, 7 Jun 2022 20:50:31 +0200 Subject: [PATCH] Fix command runner --- pkg/ec2/run.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/ec2/run.go b/pkg/ec2/run.go index 39746e1..2dfeba8 100644 --- a/pkg/ec2/run.go +++ b/pkg/ec2/run.go @@ -3,6 +3,7 @@ package ec2 import ( "context" "fmt" + "strings" "time" "github.com/aws/aws-sdk-go-v2/service/ssm" @@ -38,7 +39,7 @@ func NewCommandRunner(cfg *config.Config, inst *Instance, command []string) (*Co CloudWatchOutputEnabled: true, }, Parameters: map[string][]string{ - "commands": command, + "commands": {strings.Join(command, " ")}, }, }