@@ -11,6 +11,9 @@ export TERRAFORM_VERSION_REPO_PATH ?= $(REPO_DIR)/terraform/$(TERRAFORM_VERSION)
11
11
export TERRAGRUNT_VERSION ?= v$(call match_pattern_in_file,$(MIRROR_GITHUB_TOOLS ) ,'gruntwork-io/terragrunt','$(SEMVER_PATTERN ) ')
12
12
export TERRAGRUNT_VERSION_REPO_PATH ?= $(REPO_DIR ) /terragrunt/$(TERRAGRUNT_VERSION )
13
13
14
+ export PACKER_PLUGIN_AMAZON_VERSION ?= v$(call match_pattern_in_file,$(MIRROR_GITHUB_TOOLS ) ,'hashicorp/packer-plugin-amazon','$(SEMVER_PATTERN ) ')
15
+ export PACKER_PLUGIN_AMAZON_VERSION_REPO_PATH ?= $(REPO_DIR ) /packer-plugins/amazon/$(PACKER_PLUGIN_AMAZON_VERSION )
16
+
14
17
$(REPO_DIR ) /% :
15
18
@ echo " [make]: Creating directory '$@ '..."
16
19
mkdir -p $@
@@ -19,6 +22,11 @@ packer/download: | $(PACKER_VERSION_REPO_PATH) guard/program/jq
19
22
@ echo " [$@ ]: Downloading $( @D) $( PACKER_VERSION) ..."
20
23
$(call download_hashicorp_release,$(PACKER_VERSION_REPO_PATH ) /$(@D ) _$(PACKER_VERSION ) _$(OS ) _$(ARCH ) .zip,$(@D ) ,$(PACKER_VERSION ) )
21
24
25
+ packer-plugin-amazon/download : PLUGIN_FILENAME = $(shell basename $(shell $(call parse_github_download_url,hashicorp,$(@D ) ,tags/$(PACKER_PLUGIN_AMAZON_VERSION ) ,(.name | contains("$(OS ) _$(ARCH ) ") ) ) ))
26
+ packer-plugin-amazon/download : | $(PACKER_PLUGIN_AMAZON_VERSION_REPO_PATH ) guard/program/jq
27
+ @ echo " [$@ ]: Downloading $( @D) $( PACKER_PLUGIN_AMAZON_VERSION) ..."
28
+ $(call download_github_release,$(PACKER_PLUGIN_AMAZON_VERSION_REPO_PATH ) /$(PLUGIN_FILENAME ) ,hashicorp,$(@D ) ,tags/$(PACKER_PLUGIN_AMAZON_VERSION ) ,(.name | contains("$(OS ) _$(ARCH ) ") ))
29
+
22
30
terraform/download : | $(TERRAFORM_VERSION_REPO_PATH ) guard/program/jq
23
31
@ echo " [$@ ]: Downloading $( @D) $( TERRAFORM_VERSION) ..."
24
32
$(call download_hashicorp_release,$(TERRAFORM_VERSION_REPO_PATH ) /$(@D ) _$(TERRAFORM_VERSION ) _$(OS ) _$(ARCH ) .zip,$(@D ) ,$(TERRAFORM_VERSION ) )
@@ -28,4 +36,4 @@ terragrunt/download: | $(TERRAGRUNT_VERSION_REPO_PATH) guard/program/jq
28
36
@ echo " [$@ ]: Downloading $( @D) $( TERRAGRUNT_VERSION) ..."
29
37
$(call download_github_release,$(TERRAGRUNT_VERSION_REPO_PATH ) /$(TERRAGRUNT_FILENAME ) ,gruntwork-io,$(@D ) ,tags/$(TERRAGRUNT_VERSION ) ,(.name | contains("$(OS ) _$(ARCH ) ") ))
30
38
31
- download-all : packer/download terraform/download terragrunt/download
39
+ download-all : packer/download packer-plugin-amazon/download terraform/download terragrunt/download
0 commit comments