From 916375183bb6dee2f31e1f86a6cec3acdd8cba86 Mon Sep 17 00:00:00 2001 From: Anish Bhatt Date: Mon, 10 Dec 2018 15:33:19 -0800 Subject: [PATCH] Don't run StepCleanupTempKeys when communicator is set to none --- common/step_cleanup_temp_keys.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/common/step_cleanup_temp_keys.go b/common/step_cleanup_temp_keys.go index 0299257cc..64d623d8b 100644 --- a/common/step_cleanup_temp_keys.go +++ b/common/step_cleanup_temp_keys.go @@ -19,6 +19,10 @@ func (s *StepCleanupTempKeys) Run(_ context.Context, state multistep.StateBag) m // so there's no realistic situation where these keys can cause issues. // However, it's nice to clean up after yourself. + if s.Comm.Type == "none" { + return multistep.ActionContinue + } + comm := state.Get("communicator").(packer.Communicator) ui := state.Get("ui").(packer.Ui)