From c6d9571b076faf5d02305bd93faeda7bf23fe766 Mon Sep 17 00:00:00 2001 From: Anil Belur Date: Sat, 16 Jan 2021 15:21:59 +1000 Subject: [PATCH] Remove the -only CLI option for packer build Remove the -only CLI option for packer build The #CR 90dd675df482a8 submitted with common-packer v0.7.0 fails to build packer jobs because of a bug in the packer build CLI. The `-only` option packer build CLI does not set the cloud provider name/type as per the documentation. The alternative is to use an environment variable that is passed through the packer job and can be reference in the packer templates. Issue: JIRA IT-21300 Github Issue: https://github.com/hashicorp/packer/issues/10495 Ref: https://gerrit.linuxfoundation.org/infra/c/releng/common-packer/+/66528 Change-Id: I97bc479ddac9a8f1f0dc83201735b0a084a8b3e4 Signed-off-by: Anil Belur --- .../remove-packer-build-only-flag-2b5a53cf34dc9c6d.yaml | 15 +++++++++++++++ shell/packer-build.sh | 1 - 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/remove-packer-build-only-flag-2b5a53cf34dc9c6d.yaml diff --git a/releasenotes/notes/remove-packer-build-only-flag-2b5a53cf34dc9c6d.yaml b/releasenotes/notes/remove-packer-build-only-flag-2b5a53cf34dc9c6d.yaml new file mode 100644 index 00000000..78ead642 --- /dev/null +++ b/releasenotes/notes/remove-packer-build-only-flag-2b5a53cf34dc9c6d.yaml @@ -0,0 +1,15 @@ +--- +fixes: + - | + Remove the -only CLI option for packer build + + The #CR 90dd675df482a8 submitted with common-packer v0.7.0 + fails to build packer jobs because of a bug in the packer build CLI. + + The `-only` option packer build CLI does not set the cloud provider + name/type as per the documentation. The alternative is to use an environment + variable that is passed through the packer job and can be reference in the + packer templates. + + Ref: + Github Issue: https://github.com/hashicorp/packer/issues/10495 diff --git a/shell/packer-build.sh b/shell/packer-build.sh index 73e74965..1a44e4fd 100644 --- a/shell/packer-build.sh +++ b/shell/packer-build.sh @@ -63,7 +63,6 @@ fi set +x packer.io build -color=false \ - -only "${PACKER_BUILDER}" \ -var-file="$CLOUDENV" \ -var-file="$platform_file" \ "templates/$PACKER_TEMPLATE.json" -- 2.16.6