https://gist.github.com/anonymous/335a3f50d359c6b5de57ce546ddbc56a
On Saturday, March 25, 2017 at 8:22:16 AM UTC-4, Sachin wrote: > > 2017/03/25 07:55:09 packer.exe: 2017/03/25 07:55:09 [DEBUG] connecting to > remote shell using WinRM > 2017/03/25 07:55:09 packer.exe: 2017/03/25 07:55:09 [ERROR] connection > error: http response error: 401 - invalid content type > 2017/03/25 07:55:09 packer.exe: 2017/03/25 07:55:09 [ERROR] WinRM > connection err: http response error: 401 - invalid content type > 2017/03/25 07:55:14 packer.exe: 2017/03/25 07:55:14 [INFO] Attempting > WinRM connection... > 2017/03/25 07:55:14 packer.exe: 2017/03/25 07:55:14 [DEBUG] connecting to > remote shell using WinRM > 2017/03/25 07:55:14 packer.exe: 2017/03/25 07:55:14 [ERROR] connection > error: http response error: 401 - invalid content type > 2017/03/25 07:55:14 packer.exe: 2017/03/25 07:55:14 [ERROR] WinRM > connection err: http response error: 401 - invalid content type > 2017/03/25 07:55:19 packer.exe: 2017/03/25 07:55:19 [INFO] Attempting > WinRM connection... > 2017/03/25 07:55:19 packer.exe: 2017/03/25 07:55:19 [DEBUG] connecting to > remote shell using WinRM > 2017/03/25 07:55:19 packer.exe: 2017/03/25 07:55:19 [ERROR] connection > error: http response error: 401 - invalid content type > 2017/03/25 07:55:19 packer.exe: 2017/03/25 07:55:19 [ERROR] WinRM > connection err: http response error: 401 - invalid content type > > On Saturday, March 25, 2017 at 7:25:00 AM UTC-4, Rickard von Essen wrote: >> >> By default the GCE firewall doen't allow WinRM connections (from the >> outside). Have you opened up port 5986 in the firewall? If that doesn't >> help can you run PACKER_LOG=1 packer build template.json and attach/gist >> the output? >> >> // Rickard >> >> On 25 March 2017 at 12:02, Sachin <[email protected]> wrote: >> >>> *Hello,* >>> >>> *I am having issue with use of winrm communicator in Google Cloud, I >>> even tried to run packer scrip from same subnet where I am building >>> instance in GCE, I can connect to instance with power shell with this >>> command, * >>> >>> >>> *Enter-PSSession -ComputerName [IP_ADDRESS] -UseSSL -SessionOption >>> (New-PSSessionOption -SkipCACheck -SkipCNCheck) -Credential $credentials* >>> >>> *So network connectivity is not problem,* >>> >>> *But packer script waits for winrm and its times out.* >>> >>> *Is any one using packer in Google cloud to build windows instance >>> please give me some idea of what I am doing wrong.* >>> >>> *Here is my builders section, I tried using both port 5985 and 5986. I >>> set time out to 300 for testing. with this new windows instance comes up >>> but packer never able to connect to it with winrm.* >>> >>> *"builders": [* >>> * {* >>> * "account_file": "xxxx.json",* >>> * "communicator": "winrm",* >>> * "disk_size": "80",* >>> * "disk_type": "pd-ssd",* >>> * "image_description": "xxxxxxx",* >>> * "image_family": "xxxxxx",* >>> * "image_name": "xxxxxx",* >>> * "instance_name": "xxxxxx",* >>> * "machine_type": "n1-standard-1",* >>> * "project_id": "xxxxxxx",* >>> * "source_image": "windows-server-2012-r2-dc-v20170214",* >>> * "type": "googlecompute",* >>> * "use_internal_ip": true,* >>> * "winrm_insecure": true,* >>> * "winrm_port": 5986,* >>> * "winrm_timeout": "300m",* >>> * "winrm_use_ssl": true,* >>> * "winrm_username": "packer",* >>> * "zone": "us-east1-d"* >>> * }* >>> * ],* >>> >>> -- >>> 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/8a1c0d67-bb35-4ae8-a007-22ab980f795d%40googlegroups.com >>> >>> <https://groups.google.com/d/msgid/packer-tool/8a1c0d67-bb35-4ae8-a007-22ab980f795d%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/75902c4a-c50d-43b9-9db0-e1ad623b010c%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
