* 'temporary_security_group_source_cidrs': source data must be an array or slice, got map

28 views
Skip to first unread message

John Roh

unread,
Aug 8, 2019, 3:22:31 AM8/8/19
to Packer
Hi there?
I need to figure out how to define mutiple cidrs while the packer build runs. 
Per documentation, temporary_security_group_source_cidrs (list of string) - A list of IPv4 CIDR blocks to be authorized access to the instance, when packer is creating a temporary security group.".

I must be defined wrong that I'm getting the error message as below. 
 'temporary_security_group_source_cidrs': source data must be an array or slice, got map

What might be the appropriate way to define the multiple cdirs?

Thank you in advance,

John.

Rickard von Essen

unread,
Aug 8, 2019, 5:20:16 AM8/8/19
to packe...@googlegroups.com
It's a list of strings (CIDRs) [ "10.0.0.0/16" ].


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/250cf400-53cf-4e08-a774-4762c559c2dc%40googlegroups.com.

John Roh

unread,
Aug 8, 2019, 5:31:06 PM8/8/19
to Packer
Thank you, Rickard.

However, it goes to "variable packer_temporary_security_group_source_cidrs: '' expected type 'string', got unconvertible type '[]interface {}'" 
I'm on version 1.4.2

John. 


On Thursday, August 8, 2019 at 2:20:16 AM UTC-7, Rickard von Essen wrote:
It's a list of strings (CIDRs) [ "10.0.0.0/16" ].


On Thu, Aug 8, 2019, 09:22 John Roh <johnr...@gmail.com> wrote:
Hi there?
I need to figure out how to define mutiple cidrs while the packer build runs. 
Per documentation, temporary_security_group_source_cidrs (list of string) - A list of IPv4 CIDR blocks to be authorized access to the instance, when packer is creating a temporary security group.".

I must be defined wrong that I'm getting the error message as below. 
 'temporary_security_group_source_cidrs': source data must be an array or slice, got map

What might be the appropriate way to define the multiple cdirs?

Thank you in advance,

John.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packe...@googlegroups.com.

Rickard von Essen

unread,
Aug 9, 2019, 1:09:26 AM8/9/19
to packe...@googlegroups.com
Please attach your packer template. 

To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/88aa4ffd-5afd-42ce-b5ff-68e9ad6da185%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages