There is an igw attached to the VPC, and adding associate_public_ip_address 
does not help. It was already producing a public IP, that's how I was able 
to RDP to it, but the packer log shows it trying to connect to the internal 
IP... 

Thanks,
Jon


On Thursday, June 20, 2019 at 5:01:15 PM UTC-4, Rickard von Essen wrote:
>
> Most likely you are launching the instans in a private network (I.e 
> instances don't get a public IP).
>
> Try setting associate_public_ip_address to true. That will work if you 
> have an igw correctly setup for that subnet work. 
>
>
> https://packer.io/docs/builders/amazon-ebs.html#associate_public_ip_address
>
> https://docs.aws.amazon.com/vpc/latest/userguide/VPC_Internet_Gateway.html
>
> On Thu, Jun 20, 2019, 22:52 Jon A. <[email protected] <javascript:>> 
> wrote:
>
>>
>> Hello, 
>> I'm trying to use the "A Windows Example" on the Packer build-image 
>> tutorial. 
>> https://www.packer.io/intro/getting-started/build-image.html
>>
>> The ONLY thing I've changed to get it partially working, is setting 
>> "vpc_id" and "subnet_id" in the builders section because we do not have a 
>> default VPC. I also have tried this with Win 2012 base and Win 2016 base.
>>
>> The machine spins up, but freezes at 
>>
>> ==> amazon-ebs: Waiting for WinRM to become available...
>>
>>
>> I enabled RDP in the temporary packer security group and can connect to 
>> the machine. I verified that the bootstrap_win is at least partially 
>> running by putting in a powershell command to create a file on the new 
>> machine and it did so. I ran Test-WSMan on the machine and I don't get any 
>> errors. 
>>
>> I enabled debug, and the log is just filled with: 
>>
>> 2019/06/20 16:13:02 packer.exe: 2019/06/20 16:13:02 [INFO] Attempting 
>> WinRM connection...
>> 2019/06/20 16:13:02 packer.exe: 2019/06/20 16:13:02 [DEBUG] connecting to 
>> remote shell using WinRM
>> 2019/06/20 16:13:02 packer.exe: 2019/06/20 16:13:02 [ERROR] connection 
>> error: unknown error Post http://ip-10-0-0-37.ec2.internal:5985/wsman: 
>> dial tcp: lookup ip-10-0-0-37.ec2.internal: no such host
>> 2019/06/20 16:13:02 packer.exe: 2019/06/20 16:13:02 [ERROR] WinRM 
>> connection err: unknown error Post 
>> http://ip-10-0-0-37.ec2.internal:5985/wsman: dial tcp: lookup 
>> ip-10-0-0-37.ec2.internal: no such host
>>
>>
>> Is the problem that it is trying to use the internal IP vs. external? Is 
>> there a way to force external? The newly created machine is not on any 
>> domain. I also tried manually creating a different machine on the same VPC, 
>> installed Packer, and went through these same steps with the same result. 
>>
>> I've seen others with the same or similar behavior, but the 
>> cause/solution seems different.
>> Any ideas?
>>
>> Thanks,
>> Jon
>>
>> -- 
>> 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 [email protected] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/packer-tool/f5da2ce0-8e4b-4cd0-97f8-9b6eb75aba1c%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/packer-tool/f5da2ce0-8e4b-4cd0-97f8-9b6eb75aba1c%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/packer-tool/f2aac118-1b70-4251-bfe7-91e4abf6c218%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to