chef / knife-windows

Plugin for Chef's knife tool for working with Windows nodes
Apache License 2.0
152 stars 110 forks source link

knife windows bootstrap fails with WINRM on Shell execution. #413

Closed airom closed 5 years ago

airom commented 7 years ago

Hi,

Every time running:

knife bootstrap windows winrm mynode.mydomain.local -N "myNode" --winrm-user administrator --winrm-password 'SOMEPASSWORD' -r "role[MySwerver]" -j '{ "SomeOptions": { "Option": "value" }}' -V -y --secret-file THISISMYSECRETKEY

fails with :

ERROR: WinRM::WinRMWSManFault: [WSMAN ERROR CODE: 2147942606]: <f:WSManFault Code='2147942606' Machine='winrm mynode.mydomain.local' xmlns:f='http://schemas.microsoft.com/wbem/wsman/1/wsmanfault'><f:Message><f:ProviderFault path='%systemroot%\system32\winrscmd.dll' provider='Shell cmd plugin'>The filename or extension is too long. </f:ProviderFault></f:Message></f:WSManFault>`

The machine: AWS EC2 instance Windows 2012 R2 Here is the knife with -VV option:

INFO: Using configuration from /Users/MYUSER/source/MYCHEFREPO/.chef/knife.rb
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key winrm_shell and found value cmd
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key ca_trust_file and found value
DEBUG: Looking for key winrm_user and found value administrator
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key winrm_transport and found value plaintext
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key winrm_password and found value ceN3Vq..o%
DEBUG: Looking for key winrm_port and found value 5985
DEBUG: Looking for key session_timeout and found value 30
DEBUG: Looking for key session_timeout and found value 30
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key winrm_transport and found value plaintext
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key winrm_transport and found value plaintext
DEBUG: Looking for key winrm_authentication_protocol and found value negotiate
DEBUG: Looking for key ca_trust_file and found value
DEBUG: Looking for key ssl_peer_fingerprint and found value
DEBUG: Looking for key winrm_shell and found value cmd
DEBUG: Looking for key winrm_codepage and found value 65001
DEBUG: Looking for key ca_trust_file and found value
DEBUG: Adding mynode.mydomain.local
DEBUG: WinRM::WinRMWebService options: {:user=>".\\administrator", :password=>"mSOMEPASSWORD", :basic_auth_only=>false, :disable_sspi=>false, :no_ssl_peer_verification=>false, :ssl_peer_fingerprint=>nil, :endpoint=>"http://mynode.mydomain.local:5985/wsman", :transport=>:negotiate, :ca_trust_path=>nil, :operation_timeout=>1800}
DEBUG: Endpoint: http://mynode.mydomain.local:5985/wsman
DEBUG: Transport: negotiate
DEBUG: Looking for key chef_node_name and found value myNode
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as exilia
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating GET to https://chef.mydomain.local/organizations/MyOrganization/nodes/myNode
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: exilia
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:05Z
DEBUG: X-OPS-CONTENT-HASH: 2jmj7l5rSw0yVb/vlWAYkK/YBwk=
DEBUG: X-OPS-AUTHORIZATION-1: VIWYVzfltAzqSPUOqJqYRUcRenk6DetT44q7zOrJ+3VL3ON8nFkXivA7C5I4
DEBUG: X-OPS-AUTHORIZATION-2: RJ4htpjeEpBchg5d+0JGqm95FNTW8bnrfoaywH2o/u/keV3E+CpZZUfxemvI
DEBUG: X-OPS-AUTHORIZATION-3: gCV410IRCl2PJTMYjjfM9RmzUHwLoH/rtxuruX6Ps+Jq1JvxQukpg8yYvkjL
DEBUG: X-OPS-AUTHORIZATION-4: HnNJoxgim3/icEBqB/358iRceVyCKkCHntNnUWSzLPD1e7TTwfhlnQpv8/4Z
DEBUG: X-OPS-AUTHORIZATION-5: BGITG4QT0Q2PdDhEnUYdgnaH1iwNRtGrKlgZKsIsV5ORRaSpaydrHWyGD1kJ
DEBUG: X-OPS-AUTHORIZATION-6: E4pqvHhiIZVISmGAwDlmfbCzUj+D2DYcYJtYZia8Hg==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 200 OK
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:06 GMT
DEBUG: content-type: application/json
DEBUG: transfer-encoding: chunked
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: content-encoding: gzip
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: HTTP server did not include a Content-Length header in response, cannot identify truncated downloads.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Decompressing gzip response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as exilia
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating DELETE to https://chef.mydomain.local/organizations/MyOrganization/nodes/myNode
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: exilia
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:06Z
DEBUG: X-OPS-CONTENT-HASH: 2jmj7l5rSw0yVb/vlWAYkK/YBwk=
DEBUG: X-OPS-AUTHORIZATION-1: GCiKO8TsfFf5wYVKlsCV7gGsYHtYWTlkrftiZCbQQ0DZ4nSKjjErI1mIp11x
DEBUG: X-OPS-AUTHORIZATION-2: 14mJXhiCcxQUYOTp8xNo0+xIzXh7xRzshyINQuHqZDtvcXhjVrEEDX8T49Bc
DEBUG: X-OPS-AUTHORIZATION-3: udUobJp/pq5EEGkJRZWmW76qeVkT0TPg+fjg4hkBWPe6pjialG3hxcksHi7F
DEBUG: X-OPS-AUTHORIZATION-4: qU7eRHNhipix/X+uup5i7lpN5/yLTTgQeiKxA5TzhFBXbBcdUOFmZ1pLyPJE
DEBUG: X-OPS-AUTHORIZATION-5: NDiER+xUo0Ll+HZ9yuPVXA6BfQ/eZR8Flz+Ek93EFvX2gyv/GLPmn6+AESP9
DEBUG: X-OPS-AUTHORIZATION-6: CQRGelPZDgehUYlT3JOwIqKbKK7wzNSykuWJ3EOdmQ==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 200 OK
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:07 GMT
DEBUG: content-type: application/json
DEBUG: transfer-encoding: chunked
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: content-encoding: gzip
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: HTTP server did not include a Content-Length header in response, cannot identify truncated downloads.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Decompressing gzip response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as exilia
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating GET to https://chef.mydomain.local/organizations/MyOrganization/clients/myNode
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: exilia
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:07Z
DEBUG: X-OPS-CONTENT-HASH: 2jmj7l5rSw0yVb/vlWAYkK/YBwk=
DEBUG: X-OPS-AUTHORIZATION-1: EbVbIZDfwDAvlRGY0ByrtderG0OOgE8wk+IihhSPfNZfTivK14FBdtIWC2bd
DEBUG: X-OPS-AUTHORIZATION-2: vZLcXQAVpyivjJosluP7cwcnZt6+H/fJzdpS5O/OaxmR9t+O9ZBp0MLZu22p
DEBUG: X-OPS-AUTHORIZATION-3: 7yyKCh9B2ivZ1ojMzWyEFem+MAGuMGpj6aAB3vo3t4ajwczBiI7ni8t8yED/
DEBUG: X-OPS-AUTHORIZATION-4: RuPKxCvIVDO/+GDXXXNnUD2GDI4txZxfb5/4Omk/dg2uCdZNoiUoRgBbpBuC
DEBUG: X-OPS-AUTHORIZATION-5: f1Y3mDjZewfl3PXEJ70ZNztA5C6HHftlrRgVyRNMecbje7AWkJ4biZt0wtAk
DEBUG: X-OPS-AUTHORIZATION-6: 42wS3fddrJrSUxfnROeDACgzX5W5ntEq36hOPCdasg==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 200 OK
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:08 GMT
DEBUG: content-type: application/json
DEBUG: transfer-encoding: chunked
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: content-encoding: gzip
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: HTTP server did not include a Content-Length header in response, cannot identify truncated downloads.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Decompressing gzip response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as exilia
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating DELETE to https://chef.mydomain.local/organizations/MyOrganization/clients/myNode
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: exilia
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:07Z
DEBUG: X-OPS-CONTENT-HASH: 2jmj7l5rSw0yVb/vlWAYkK/YBwk=
DEBUG: X-OPS-AUTHORIZATION-1: eL1sgwK/ng+ENRaCNTEXrUbkq26/ZJAzBejTXuM2Hv28X8okrtI3DJwliSvb
DEBUG: X-OPS-AUTHORIZATION-2: KuxcHAkZkjJHA0xGNln87FXgyQww6k9aQ7rx0gwEmvyPimrvI1c26egDLGTA
DEBUG: X-OPS-AUTHORIZATION-3: T/iulx+WOOWsnNm+b9XNNe8Grzf8CisOwjSbJxonyyTGB9UrLxIP3cZrv07b
DEBUG: X-OPS-AUTHORIZATION-4: gmvrZYCa/d+69vJUdNtjATZIymx/Q1lGGHWVsRFIebmLemiMhGTKD/kSCREk
DEBUG: X-OPS-AUTHORIZATION-5: eb/DZp1RG1gcsn77g0DSxj77nx2umqWcpqBteSATnfHCz8SGD3vcfvg4FkLc
DEBUG: X-OPS-AUTHORIZATION-6: 6Kt19L7b8SGcl8309NYeUFaEnWOud8a+7xrbBaWQPw==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 200 OK
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:08 GMT
DEBUG: content-type: application/json
DEBUG: transfer-encoding: chunked
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: content-encoding: gzip
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: HTTP server did not include a Content-Length header in response, cannot identify truncated downloads.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Decompressing gzip response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
Creating new client for myNode
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as exilia
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating POST to https://chef.mydomain.local/organizations/MyOrganization/clients
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Content-Type: application/json
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: exilia
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:08Z
DEBUG: X-OPS-CONTENT-HASH: 4rZxCSeKjht57xM7zlM1lpbFA9I=
DEBUG: X-OPS-AUTHORIZATION-1: T+BPNxwhIfTKnRzFLxkkghj0i12Gs/+H4MfdpH0NwuXxdvPLVZZZ8zH7dTnf
DEBUG: X-OPS-AUTHORIZATION-2: OQzjtV3j1i+MfUvFHcHr8Zu8ggXuYRfNxH7TbEADlCDgdhNN4RhdIPv77RaZ
DEBUG: X-OPS-AUTHORIZATION-3: +dPz6ElMHM2Az+kX5eS7FyQDhudD1X067seo28LRc/O4PjdXKneVLhCCOVQI
DEBUG: X-OPS-AUTHORIZATION-4: YoFkSWpXzL180xW93WGZ12Fo6ML4PFglc5yq/rc/4Agpd92IekmPbtKdJA6r
DEBUG: X-OPS-AUTHORIZATION-5: ilePNj3aa2bgCttzXaKMgT3hRlyecEyrtc2bPBvYKuIvqQ8Gwp4vB13BtXj1
DEBUG: X-OPS-AUTHORIZATION-6: vJsXtr2GMG6d3+ghyclnzK9GYp5zf0JD4Z7srBeIQA==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: Content-Length: 514
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 201 Created
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:09 GMT
DEBUG: content-type: application/json
DEBUG: content-length: 715
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: location: https://chef.mydomain.local/organizations/MyOrganization/clients/myNode
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: Content-Length validated correctly.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
Creating new node for myNode
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as myNode
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating PUT to https://chef.mydomain.local/organizations/MyOrganization/nodes/myNode
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Content-Type: application/json
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: myNode
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:09Z
DEBUG: X-OPS-CONTENT-HASH: rGeeEb1SdrIGMWgERM9NIpo6koo=
DEBUG: X-OPS-AUTHORIZATION-1: PnSfm/r26SpYGBg3dYPdKl89paAckSIWNxnrcvsAeQ1Zma51Xwd09vIUfB5Y
DEBUG: X-OPS-AUTHORIZATION-2: 3WeKMCLMXu7oAyTrAajl5sT1cZmFSm9eDN3T5HXaRSTPqid0DPFYCyb+K//p
DEBUG: X-OPS-AUTHORIZATION-3: zzYB53Xqq8gqShhh+ssf+GstQYd+ymRqKAaCbq5ClN2FdbtHHTjR/b2IRfeK
DEBUG: X-OPS-AUTHORIZATION-4: qQMRNrx0cD8g2VgeDmEouDuaiJbtDyFx+YuekHY4PUKQy7Cv8vK5WZ0onDuL
DEBUG: X-OPS-AUTHORIZATION-5: lLi+4zctsBOajPkcf8gRQUrYUCXX65C0ApEf8ywzXRzFNJurtNaAkUEueO2Z
DEBUG: X-OPS-AUTHORIZATION-6: jZbna77wA1o67oGNwg9qTfjLeIiczOk7vNf5xhzBDg==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: Content-Length: 216
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 404 Object Not Found
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:10 GMT
DEBUG: content-length: 44
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: ---- HTTP Response Body ----
DEBUG: {"error":["node 'myNode' not found"]}
DEBUG: ---- End HTTP Response Body -----
DEBUG: ---- HTTP Request Body ----
DEBUG: {"name":"myNode","chef_environment":"Staging","json_class":"Chef::Node","automatic":{},"normal":{"mitk_windows_helper":{"hostname":"myNode"}},"chef_type":"node","default":{},"override":{},"run_list":[]}
DEBUG: ---- End HTTP Request Body ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: Content-Length validated correctly.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Expected JSON response, but got content-type ''
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
INFO: HTTP Request Returned 404 Object Not Found: error
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
DEBUG: Signing the request as myNode
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_request
DEBUG: Initiating POST to https://chef.mydomain.local/organizations/MyOrganization/nodes
DEBUG: ---- HTTP Request Header Data: ----
DEBUG: Content-Type: application/json
DEBUG: Accept: application/json
DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
DEBUG: X-Ops-Server-API-Version: 1
DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.1;
DEBUG: X-OPS-USERID: myNode
DEBUG: X-OPS-TIMESTAMP: 2016-12-01T16:16:10Z
DEBUG: X-OPS-CONTENT-HASH: rGeeEb1SdrIGMWgERM9NIpo6koo=
DEBUG: X-OPS-AUTHORIZATION-1: GJ0RtlTPRk/UCgrcdlHPjBlfO2vVeuTRRwPX4kl5Z6QbZA0zNVw+00j31M95
DEBUG: X-OPS-AUTHORIZATION-2: pmboICclYwhCHRs63skYVc6hGe7mjT9aznaqU9Df8QcFlahzpydA+jPwpFFP
DEBUG: X-OPS-AUTHORIZATION-3: 8rwzsWMXk7eGT0jVUWF9QhQWwsH+OGNyOUZKDR7zK4Ob6lK3R6FCnRQtMXIE
DEBUG: X-OPS-AUTHORIZATION-4: s/tQ4YTUGrNl6eSxjpadvlbKyM+NuEeHC+M8w910NMFWds0d2aUiqRCjsRbF
DEBUG: X-OPS-AUTHORIZATION-5: ZuaJ75ouXLd+38oCXnvJsQQFD9SE0w1Hp/kDz5j8ABFRmHxQ5viu7r94MGXN
DEBUG: X-OPS-AUTHORIZATION-6: pj9wM5CiENeNNjDB0LkyI1nRmi0ruQRsWhgZcNbo2g==
DEBUG: HOST: chef.mydomain.local:443
DEBUG: X-REMOTE-REQUEST-ID: 85e79077-b76b-4140-8cb0-1f354828a7ea
DEBUG: Content-Length: 216
DEBUG: ---- End HTTP Request Header Data ----
DEBUG: ---- HTTP Status and Header Data: ----
DEBUG: HTTP 1.1 201 Created
DEBUG: server: openresty/1.11.2.1
DEBUG: date: Thu, 01 Dec 2016 16:16:11 GMT
DEBUG: content-type: application/json
DEBUG: content-length: 82
DEBUG: connection: close
DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"1","response_version":"1"}
DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.10.0
DEBUG: location: https://chef.mydomain.local/organizations/MyOrganization/nodes/myNode
DEBUG: ---- End HTTP Status/Header Data ----
DEBUG: Chef::HTTP calling Chef::HTTP::ValidateContentLength#handle_response
DEBUG: Content-Length validated correctly.
DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response

Waiting for remote response before bootstrap.DEBUG: echo . & echo Response received.
DEBUG: [WinRM] opening remote shell on http://mynode.mydomain.local:5985/wsman
DEBUG: [WinRM] remote shell created with shell_id: F91735BD-92CD-4053-9B37-80224703EC8E
DEBUG: [WinRM] Command created for echo . & echo Response received. with id: C19C279F-E0D4-443C-BBC7-CC2F1DB34169
DEBUG: [WinRM] creating command_id: C19C279F-E0D4-443C-BBC7-CC2F1DB34169 on shell_id F91735BD-92CD-4053-9B37-80224703EC8E
DEBUG: [WinRM] Waiting for output...
DEBUG: [WinRM] Processing output
mynode.mydomain.local .
mynode.mydomain.local Response received.
DEBUG: [WinRM] cleaning up command_id: C19C279F-E0D4-443C-BBC7-CC2F1DB34169 on shell_id F91735BD-92CD-4053-9B37-80224703EC8E
Remote node responded after 0.01 minutes.
Bootstrapping Chef on mynode.mydomain.local
DEBUG: Looking for bootstrap template in /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap/templates
DEBUG: Looking for bootstrap template in /Users/MYUSER/source/CHEF_REPO/.chef/bootstrap
DEBUG: Looking for bootstrap template in /Users/MYUSER/.chef/bootstrap
DEBUG: Looking for bootstrap template in /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap
DEBUG: Found bootstrap template in /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap
DEBUG: cmd.exe /C echo Rendering "%TEMP%\bootstrap-58702-1480608972.bat" chunk 1 && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Author:: Seth Chisamore ^(^<schisamo@chef.io^>^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Copyright:: Copyright ^(c^) 2011-2016 Chef Software, Inc.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem License:: Apache License, Version 2.0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Licensed under the Apache License, Version 2.0 ^(the "License"^);) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem you may not use this file except in compliance with the License.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem You may obtain a copy of the License at) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem     http://www.apache.org/licenses/LICENSE-2.0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Unless required by applicable law or agreed to in writing, software) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem distributed under the License is distributed on an "AS IS" BASIS,) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem See the License for the specific language governing permissions and) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem limitations under the License.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Use delayed environment expansion so that ERRORLEVEL can be evaluated with the) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem !ERRORLEVEL! syntax which evaluates at execution of the line of script, not when) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem the line is read. See help for the /E switch from cmd.exe /? .) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@setlocal ENABLEDELAYEDEXPANSION) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set BOOTSTRAP_DIRECTORY=C:\chef) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Checking for existing directory "%BOOTSTRAP_DIRECTORY%"...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if NOT EXIST %BOOTSTRAP_DIRECTORY% ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Existing directory not found, creating.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@mkdir %BOOTSTRAP_DIRECTORY%) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Existing directory found, skipping creation.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef\wget.vbs ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.url = WScript.Arguments.Named^^^("url"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.path = WScript.Arguments.Named^^^("path"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.proxy = null) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.'* Vaguely attempt to handle file:// scheme urls by url unescaping and switching all) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.'* / into .  Also assume that file:/// is a local absolute path and that file://^^^<foo^^^>) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.'* is possibly a network file path.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If InStr^^^(url, "file://"^^^) = 1 Then) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.url = Unescape^^^(url^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If InStr^^^(url, "file:///"^^^) = 1 Then) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.sourcePath = Mid^^^(url, Len^^^("file:///"^^^) + 1^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Else) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.sourcePath = Mid^^^(url, Len^^^("file:"^^^) + 1^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.End If) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.sourcePath = Replace^^^(sourcePath, "/", "\"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objFSO = CreateObject^^^("Scripting.FileSystemObject"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If objFSO.Fileexists^^^(path^^^) Then objFSO.DeleteFile path) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objFSO.CopyFile sourcePath, path, true) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objFSO = Nothing) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Else) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objXMLHTTP = CreateObject^^^("MSXML2.ServerXMLHTTP"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set wshShell = CreateObject^^^( "WScript.Shell" ^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objUserVariables = wshShell.Environment^^^("USER"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.rem http proxy is optional) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.rem attempt to read from HTTP_PROXY env var first) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.On Error Resume Next) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If NOT ^^^(objUserVariables^^^("HTTP_PROXY"^^^) = ""^^^) Then) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.proxy = objUserVariables^^^("HTTP_PROXY"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.rem fall back to named arg) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ElseIf NOT ^^^(WScript.Arguments.Named^^^("proxy"^^^) = ""^^^) Then) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.proxy = WScript.Arguments.Named^^^("proxy"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.End If) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If NOT isNull^^^(proxy^^^) Then) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.rem setProxy method is only available on ServerXMLHTTP 6.0+) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objXMLHTTP = CreateObject^^^("MSXML2.ServerXMLHTTP.6.0"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objXMLHTTP.setProxy 2, proxy) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.End If) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.On Error Goto 0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objXMLHTTP.open "GET", url, false) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objXMLHTTP.send^^^(^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If objXMLHTTP.Status = 200 Then) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objADOStream = CreateObject^^^("ADODB.Stream"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objADOStream.Open) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objADOStream.Type = 1) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objADOStream.Write objXMLHTTP.ResponseBody) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objADOStream.Position = 0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objFSO = Createobject^^^("Scripting.FileSystemObject"^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.If objFSO.Fileexists^^^(path^^^) Then objFSO.DeleteFile path) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objFSO = Nothing) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objADOStream.SaveToFile path) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.objADOStream.Close) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objADOStream = Nothing) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.End If) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Set objXMLHTTP = Nothing) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.End If) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef\wget.ps1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.param^^^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.   [String] $remoteUrl,) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.   [String] $localPath) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.$ProxyUrl = $env:http_proxy;) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.$webClient = new-object System.Net.WebClient;) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.if ^^^($ProxyUrl -ne ''^^^) {) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.  $WebProxy = New-Object System.Net.WebProxy^^^($ProxyUrl,$true^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.  $WebClient.Proxy = $WebProxy) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.}) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.$webClient.DownloadFile^^^($remoteUrl, $localPath^^^);) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Determine the version and the architecture) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@FOR /F "usebackq tokens=1-8 delims=.[] " %%A IN ^(`ver`^) DO ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set WinMajor=%%D) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set WinMinor=%%E) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set WinBuild=%%F) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Detected Windows Version %WinMajor%.%WinMinor% Build %WinBuild%) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set LATEST_OS_VERSION_MAJOR=6) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set LATEST_OS_VERSION_MINOR=3) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if /i %WinMajor% GTR %LATEST_OS_VERSION_MAJOR% goto VersionUnknown) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if /i %WinMajor% EQU %LATEST_OS_VERSION_MAJOR%  ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if /i %WinMinor% GTR %LATEST_OS_VERSION_MINOR% goto VersionUnknown) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto Version%WinMajor%.%WinMinor%) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:VersionUnknown) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem If this is an unknown version of windows set the default) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MACHINE_OS=2008r2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Warning: Unknown version of Windows, assuming default of Windows %MACHINE_OS%) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto architecture_select) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:Version6.0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MACHINE_OS=2008) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto architecture_select) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:Version5.2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MACHINE_OS=2003r2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto architecture_select) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:Version6.1) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MACHINE_OS=2008r2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto architecture_select) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:Version6.2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MACHINE_OS=2012) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto architecture_select) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Currently Windows Server 2012 R2 is treated as equivalent to Windows Server 2012) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:Version6.3) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto Version6.2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:architecture_select) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MACHINE_ARCH=x86_64) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.IF "%PROCESSOR_ARCHITECTURE%"=="x86" IF not defined PROCESSOR_ARCHITEW6432 @set MACHINE_ARCH=i686) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.goto install) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.:install) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem If user has provided the custom installation command for chef-client then execute it) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Install Chef using chef-client MSI installer) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set "LOCAL_DESTINATION_MSI_PATH=%TEMP%\chef-client-latest.msi") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set "CHEF_CLIENT_MSI_LOG_PATH=%TEMP%\chef-client-msi%RANDOM%.log") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Clear any pre-existing downloads) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Checking for existing downloaded package at "%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if EXIST "%LOCAL_DESTINATION_MSI_PATH%" ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Found existing downloaded package, deleting.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@del /f /q "%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Warning: Failed to delete pre-existing package with status code !ERRORLEVEL! ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo No existing downloaded packages to delete.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem If there is somehow a name collision, remove pre-existing log) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if EXIST "%CHEF_CLIENT_MSI_LOG_PATH%" del /f /q "%CHEF_CLIENT_MSI_LOG_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Attempting to download client package using PowerShell if available...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set "REMOTE_SOURCE_MSI_URL=https://www.chef.io/chef/download?p=windows&pv=%MACHINE_OS%&m=%MACHINE_ARCH%&DownloadContext=PowerShell&v=12") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set powershell_download=powershell.exe -ExecutionPolicy Unrestricted -InputFormat None -NoProfile -NonInteractive -File  C:\chef\wget.ps1 "%REMOTE_SOURCE_MSI_URL%" "%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo !powershell_download!) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@call !powershell_download!) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set DOWNLOAD_ERROR_STATUS=!ERRORLEVEL!) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Failed PowerShell download with status code !DOWNLOAD_ERROR_STATUS! ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if !DOWNLOAD_ERROR_STATUS!==0 set DOWNLOAD_ERROR_STATUS=2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Sometimes the error level is not set even when the download failed,) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem so check for the file to be sure it is there -- if it is not, we will retry) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if NOT EXIST "%LOCAL_DESTINATION_MSI_PATH%" ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Failed download: download completed, but downloaded file not found ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.set DOWNLOAD_ERROR_STATUS=2) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Download via PowerShell succeeded.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if NOT %DOWNLOAD_ERROR_STATUS%==0 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Warning: Failed to download "%REMOTE_SOURCE_MSI_URL%" to "%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Warning: Retrying download with cscript ...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if EXIST "%LOCAL_DESTINATION_MSI_PATH%" del /f /q "%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set "REMOTE_SOURCE_MSI_URL=https://www.chef.io/chef/download?p=windows&pv=%MACHINE_OS%&m=%MACHINE_ARCH%&v=12") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.cscript /nologo C:\chef\wget.vbs /url:"%REMOTE_SOURCE_MSI_URL%" /path:"%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if NOT ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem Sometimes the error level is not set even when the download failed,) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@rem so check for the file to be sure it is there.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if NOT EXIST "%LOCAL_DESTINATION_MSI_PATH%" ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Failed download: download completed, but downloaded file not found ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Exiting without bootstrapping due to download failure. ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.exit /b 1) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Download via cscript succeeded.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Failed to download "%REMOTE_SOURCE_MSI_URL%" with status code !ERRORLEVEL!. ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Exiting without bootstrapping due to download failure. ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.exit /b 1) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Installing downloaded client package...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.msiexec /qn /log "%CHEF_CLIENT_MSI_LOG_PATH%" /i "%LOCAL_DESTINATION_MSI_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set MSIERRORCODE=!ERRORLEVEL!) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo WARNING: Failed to install Chef Client MSI package in remote context with status code !MSIERRORCODE!.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo WARNING: This may be due to a defect in operating system update KB2918614: http://support.microsoft.com/kb/2918614) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@set OLDLOGLOCATION="%CHEF_CLIENT_MSI_LOG_PATH%-fail.log") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@move "%CHEF_CLIENT_MSI_LOG_PATH%" "!OLDLOGLOCATION!" ^> NUL) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo WARNING: Saving installation log of failure at !OLDLOGLOCATION!) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo WARNING: Retrying installation with local context...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@schtasks /create /f  /sc once /st 00:00:00 /tn chefclientbootstraptask /ru SYSTEM /rl HIGHEST /tr "cmd /c msiexec /qn /log '%CHEF_CLIENT_MSI_LOG_PATH%' /i '%LOCAL_DESTINATION_MSI_PATH%' & sleep 2 & waitfor /s %computername% /si chefclientinstalldone") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo ERROR: Failed to create Chef Client installation scheduled task with status code !ERRORLEVEL! ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Successfully created scheduled task to install Chef Client.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@schtasks /run /tn chefclientbootstraptask) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo ERROR: Failed to execut Chef Client installation scheduled task with status code !ERRORLEVEL!. ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Successfully started Chef Client installation scheduled task.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Waiting for installation to complete -- this may take a few minutes...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.waitfor chefclientinstalldone /t 600) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo ERROR: Timed out waiting for Chef Client package to install) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Finished waiting for Chef Client package to install.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@schtasks /delete /f /tn chefclientbootstraptask ^> NUL) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Successfully installed Chef Client package.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@if ERRORLEVEL 1 ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Chef-client package failed to install with status code !ERRORLEVEL!. ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo See installation log for additional detail: %CHEF_CLIENT_MSI_LOG_PATH%. ^> "&2") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^) else ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Installation completed successfully) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.del /f /q "%CHEF_CLIENT_MSI_LOG_PATH%") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@endlocal) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo off) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef\client.pem ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----BEGIN RSA PRIVATE KEY-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MIIEogIBAAKCAQEA8qTMGvrTPb034a3EPLjNG4d9vfeM9po03FM85HUJ7Is/g0KT) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.1kos7h9kPOGNP6sLrQPlWOT+9SMDSOlQh9cjPqvMJPdkcrawL7p4TYDdyAkq/ori) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dVOE4IinXSCsk+G67p1Y1+O5S+Xbj5aszWGrHr/6T6kf5c+r4RioAAADZ3cgi7zM) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ZJ0UNgFKkmUz7qBks1FJeAibtvZYqdLD3QipMf88a+tlUhC5d3H/5NLa4r3umpTJ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.qHXd3MIm++6CP3kJF8im2EjRnopGwezPiJ9hTjagwj6eNb9ILp6/HzUjfjVDNoko) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.nFIxK4khJSdoUc1m1vSzQhMFfvOXJfiyTokb9wIDAQABAoIBAGAKQo9bQElrn7a/) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.5LB0JRsEYgzS8wSYvNuIRs3WVXs/EoCN1Z439di6rB482H+e4Bw3Mowg95lnpmEx) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.mCJsURL5RPBMy4FsNghuMjfbDe2jU1U0+7WcvTdyX2xJBoXyDt9rgELTbABSlrka) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.1oLkaareKeFl+64mqM2LyNNXLgHBK9JuIQByto0Og/xC2IXJVlyXvhXkiU20SbKa) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.sMHJZTahNTEiMNBWgJBoT3uNR5F43kqfwFDLgUbXZqRVAwC81GSUbAcFXRR2jMb0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.TxI4yNjEKyTCdhXfq2cqQBGHHFQeZzKnPzOYdTvE+jUqHFPvUjqdyku/sThh58iE) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.+twaB8ECgYEA/xsQTy9ogsm55kLGn1E58I39C9k1SIaKbGSJ7dIo1KlTsIbXW2jY) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.wRuwTm2mGd4P09HZ7VussXtc+z1JRKHs8iQs5ELIFCQwreyQ7Rs8nTA2Gf+CiXPJ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.SGKzFuBiyjDCL6+f3ig8LzMlS3e8S+zJmQC6Cu8eUGYSIZ8UhlXNX18CgYEA836M) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.y7MYoQ7AGSlM0Y8hkS5PCv8UtGVNpqV7pcxnC12J6jf7ve9N/Rs0h3b4TKf8n8hk) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.2nqKOodxbuVBkjHR1QNkA69Yg248DpMbozOiXuLbf8OqkLVFm+88J99go/VuYqpW) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.G2jq7nePFJ669J9S7nbQ7rvIpJh5jrBBGo1ZwmkCgYAxbnITlfEfXq1Z89h+6INc) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.nHbLA/SyL/fElxqu7Ykh5AmmbApw2PkfOhlIqTCFVKUme0RKHPhyj5/twutelC3Q) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.obfdJx+T34tbODrA5wUwxDXHhd4qejgngZCIP0SFPztxeAt3Rb6busJgRDxFTgWm) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.UyC5m6n5FD4xK50Thq676wKBgFVgIvftdQ5LwLlRzNiRiiCAj0B4zgaumnp6/Y7V) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.y6+lfYz9Uix3su2zU0jIQymFoUNZHVupqbv576EFi2c6Rqucw72zBqMWzMIDfKZN) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.nXoNqw7ySWTx2lVhncMRRK5YiPrZZNW5hN5WV3nQahcJoidwy7NZbnGf8MdCL6Gi) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.vD05AoGANx7woTZu2SxZOUmk/kCvx25sodQ69OwtXvF+TSAXTlkg1QsNAyJD7w1+) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo./J5x8gLioeGduyWpWeBU+SXcbjdN6faHSJKXy7xAndBx0Ap3+ylAUI9ajsmUMpmC) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.bxeFrRYd2aMaomVV+khCw7aOb83c48nJrzWs+2hbxeDbDRgmnnI=) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----END RSA PRIVATE KEY-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Writing validation key...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo Validation key written.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo on) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.mkdir C:\chef\trusted_certs) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef/trusted_certs/chef_mitekcloud_local.crt ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----BEGIN CERTIFICATE-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MIIHOTCCBSGgAwIBAgITbAAAABdqPY+kuc+BhgABAAAAFzANBgkqhkiG9w0BAQsF) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ADBsMRUwEwYKCZImiZPyLGQBGRYFbG9jYWwxGjAYBgoJkiaJk/IsZAEZFgptaXRl) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.a2Nsb3VkMTcwNQYDVQQDEy5NaXRlayBDbG91ZE9wcyBTZWN1cmUgQ2VydGlmaWNh) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dGUgQXV0aG9yaXR5IEcxMB4XDTE2MTEwMzE2Mjg0OVoXDTE4MTEwMzE2Mzg0OVow) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.gYExCzAJBgNVBAYTAlVTMRMwEQYDVQQIEwpDYWxpZm9ybmlhMRIwEAYDVQQHEwlT) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.YW4gRGllZ28xFjAUBgNVBAoTDU1pdGVrIFN5c3RlbXMxETAPBgNVBAsTCENsb3Vk) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.T3BzMR4wHAYDVQQDExVjaGVmLm1pdGVrY2xvdWQubG9jYWwwggEiMA0GCSqGSIb3) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.DQEBAQUAA4IBDwAwggEKAoIBAQDDQATRKcpglU6pKfSrX8jHR1AInE2VIlzr9FdV) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.XZp9FgAi7ZifkDKfNJoHZFf02pjDJ7zJktHPYyvFVi3C6lyHRbFT/cFmk6bphFiF) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.3XZ/4QT/SNe632H7p/LjHNhPtc7GsTtohFHieox1p8DeD575pOAyn0wz3H9+5vA3) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.VFdtLWKRn4+ptYjRKMN8X1bZWoJyUPxKJF47+6OdC/R4EmOlEARWK/7Cc51d1IQJ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Kbkgiu/cyWhb4ajSsGfrGM8q6i6lDekB8BXuK1xCdff573pK268LJFcESqPLRvqy) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.r/zWwBWD5LreKqcB9n5lOpn0KrOfou/34w5Kh007HoEsMCFXAgMBAAGjggK8MIIC) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.uDAdBgNVHQ4EFgQUcORqusf12tj9Iq1ytJDrRqhgJzkwHwYDVR0jBBgwFoAUvsLt) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.R/vry4cbMML2kgFHN/Vl/2UwggECBgNVHR8EgfowgfcwgfSggfGgge6GgetsZGFw) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Oi8vL0NOPU1pdGVrJTIwQ2xvdWRPcHMlMjBTZWN1cmUlMjBDZXJ0aWZpY2F0ZSUy) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MEF1dGhvcml0eSUyMEcxKDEpLENOPUNMT1VELUNBLTAyLENOPUNEUCxDTj1QdWJs) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.aWMlMjBLZXklMjBTZXJ2aWNlcyxDTj1TZXJ2aWNlcyxDTj1Db25maWd1cmF0aW9u) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.LERDPW1pdGVrY2xvdWQsREM9bG9jYWw/Y2VydGlmaWNhdGVSZXZvY2F0aW9uTGlz) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dD9iYXNlP29iamVjdENsYXNzPWNSTERpc3RyaWJ1dGlvblBvaW50MIHvBggrBgEF) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.BQcBAQSB4jCB3zCB3AYIKwYBBQUHMAKGgc9sZGFwOi8vL0NOPU1pdGVrJTIwQ2xv) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dWRPcHMlMjBTZWN1cmUlMjBDZXJ0aWZpY2F0ZSUyMEF1dGhvcml0eSUyMEcxLENO) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.PUFJQSxDTj1QdWJsaWMlMjBLZXklMjBTZXJ2aWNlcyxDTj1TZXJ2aWNlcyxDTj1D) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.b25maWd1cmF0aW9uLERDPW1pdGVrY2xvdWQsREM9bG9jYWw/Y0FDZXJ0aWZpY2F0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ZT9iYXNlP29iamVjdENsYXNzPWNlcnRpZmljYXRpb25BdXRob3JpdHkwDgYDVR0P) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.AQH/BAQDAgWgMDwGCSsGAQQBgjcVBwQvMC0GJSsGAQQBgjcVCIHNgBGKuxGByZUw) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.h5vmN7XcXoFIheGyG4bRzl0CAWYCAQAwEwYDVR0lBAwwCgYIKwYBBQUHAwEwGwYJ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.KwYBBAGCNxUKBA4wDDAKBggrBgEFBQcDATANBgkqhkiG9w0BAQsFAAOCAgEAZnrz) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.NAxuj9LlRU5LmT99Ys6q+hSoSTtApk/1UyINr9U9eMCMfeGCv+cxnpacjTPKCCm0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.DfYhHvTLBWZVcDqSkzK0VpCkQ8cBqo3K9PI7DQMVIpgaVZsd89W1VjFIXhRqfQ1Y) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.03glbvl8q7nC9Q3ikcQDbIBLbKuTMOxNwYmB0ri57TyYp6Kk/IiXq8eCdHuBMXBI) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.FjDlmxnhidgfkz6yYPEz4e3drSgYGsBgL4rH28PRUYb3qpoZNHPrWy6dW1Feo7pQ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.PyMC4AZSUlzij/F/yrK+On3rFx4J8VL7jHLI7WEhkYfIV8NRJt3wmDXA9fnVH+C/) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.piK63SnMM0XTdLkNua7cZCW9F3lkQmaIxefOdYS9HotjUk5YqYEQAjYd7dYBxec4) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.pFwaBnxZHDES613k6Eivvto3EelVK5Mzlvs7qxm+M60H1hN43TdBYppkRsvhyqMJ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.2xbVUXZBh63P98NDsPAWdSw/GEMiVShgO1BEVSWYlueuLT+PP46B858XKpKKckJw) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.88PNPkh1c+HBcRL8Om8+UHr6WN66Ah3F7Bsfwft/cztX8IwQo3AFLhWjuH6xJpu6) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Nq53bdRXq/E8Wd0Fxu0yqrOcAzdvQq2p0Ht7dZbI5ytmzgRTx7EdHWDWftjZjryO) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.7lTiGI/OyXb75Z7/LLSDFvAwmukI0gnzffJIKHk=) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----END CERTIFICATE-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef/trusted_certs/Mitek_MyOrganization_Root_Certificate_Authority_G1.crt ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----BEGIN CERTIFICATE-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MIIFrzCCA5egAwIBAgIQc9d5VwjC+bxGZYl6+mWr3zANBgkqhkiG9w0BAQsFADBq) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MRUwEwYKCZImiZPyLGQBGRYFbG9jYWwxGjAYBgoJkiaJk/IsZAEZFgptaXRla2Ns) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.b3VkMTUwMwYDVQQDEyxNaXRlayBDbG91ZE9wcyBSb290IENlcnRpZmljYXRlIEF1) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dGhvcml0eSBHMTAeFw0xNjEwMDIyMDQ0MzVaFw0yNjEwMDIyMDU0MzVaMGoxFTAT) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.BgoJkiaJk/IsZAEZFgVsb2NhbDEaMBgGCgmSJomT8ixkARkWCm1pdGVrY2xvdWQx) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.NTAzBgNVBAMTLE1pdGVrIENsb3VkT3BzIFJvb3QgQ2VydGlmaWNhdGUgQXV0aG9y) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.aXR5IEcxMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAjAszZSxBfVDx) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.nNcPcV/02EisHw6k3fU00J+ARE9/lhLLyCtGjGJoTsVjdn69a6DzlMq4wEJ7XxiB) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.4le1/UjOeV9MtI+qzGTSNXzqyf9jsIBCm/7lUn+V9DAR8FX9RZhaCCnHgnRiCCAG) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.gKkk56gwQSAl0rf1LXMrfyqYG9+nhh0+SvvoaXwwp83NcLCSU4HPIs7zENCs5oz/) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.gedBnNU5lxsmb3ywkHWIpsCisCUb20RK8s4IDSbkGlCwxwMp9ssFrlMF61x90oV0) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.SGMkeuadxc7FtCski8syljE1i/Fpj5DGByPhQKpgqneDOCEGkO8pnwu/Y/o0c8lT) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ic/tet5yc7lhCosW/RWNblQmlLrNNVoo2P1UXtfbP1qFJOZG091V4uSxdyE1g9q5) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.q2wSwCqLsUzmg0WpAg7yWjO24bZyq9/s6JlngGHGeRlypYGc/HZSISFAiSXocRjO) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.mUZ4Lgp9gY1oe76oDFjg6qVvelreg93bNyavA9MlX4kXdyXNJmhGWVypJ8AbfI8M) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.kN6yI4LGWHfoDWQnLDVX1gkhwOdBSz21ZA9hF3zxxy4PqG38UPcSRNtowSy2BsDu) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.tYvFHeDS2Np5AXcx5y9tOwUsMeBikHX8/nIQKaQRySGMfnkHNGRQQHehb+lIeqlK) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.XqcA01BFIun1CWt+MqfmCI5RN2yNnh8CAwEAAaNRME8wCwYDVR0PBAQDAgGGMA8G) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.A1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFHHckd6EnhFzKL8quMmtTXvOi9S4MBAG) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.CSsGAQQBgjcVAQQDAgEAMA0GCSqGSIb3DQEBCwUAA4ICAQAM9i8GzvDNoBnn5Tya) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.8NPXlnI0wMH3fqBBi8vf/RZ6wD0jLars8Yo2GsbPYZh5984erxFbQGRV8Rmo0o1F) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.CkMapdaBHXbYpI95MHuv+wTHimgr82XwtVTEFCdEgIiSdh1wh5iXeA7eL8krJ2XE) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.BvRyG1RfA9iQ+eRa/V6onBf6QJYp/ZRZMA20KBkoY+EU4XsrgRyAuEhOpCzMRCnC) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.js66ed798EctZTCYDKRfsbYquKbWXMLGKDskrfy1IwLD3tzwyia+G1bn7DXxc3Vx) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ko80P251vcZOvFFCrlciAjcui2dOoDxK+xYEVIxVcWEW8wdRK1AzCm0KGCVqqMN8) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Sxl+Z+fKbBEYywQK2b+z4rfPzNJoyUpDaYPMnxqIsN0VWmOZ0ELRKKjcret/c4ZF) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Th2qtljsCCzL66CU6Swl4G5dhv7EkLFB2fTK6agqIeARMteHzJpTYmuDwjy1p9/j) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Vqnro6o+ZH/IOvZwbkbqiK7oOzmy8yjuNS/EEQsdKUR7XFajRkk15y96xNV3nUrV) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.DZTO2hpJEKJiWTn3i0eNpyKocBfoDRbLqTeNTMcs0jboHRScDYJmYEkWmRfTpBA+) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.xAWEgvcR5pwgg7QpQur0KWZHXB0kLYKJrtuC/iHaoFiPS9dH5IDTFB2HvmOSEI3H) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.DGXX8WA8DdJ9NVCbQON2ti85WQ==) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----END CERTIFICATE-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef/trusted_certs/Mitek_MyOrganization_Secure_Certificate_Authority_G1.crt ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----BEGIN CERTIFICATE-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MIIICzCCBfOgAwIBAgITOQAAAAS+4iOnBpcWcwAAAAAABDANBgkqhkiG9w0BAQsF) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.ADBqMRUwEwYKCZImiZPyLGQBGRYFbG9jYWwxGjAYBgoJkiaJk/IsZAEZFgptaXRl) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.a2Nsb3VkMTUwMwYDVQQDEyxNaXRlayBDbG91ZE9wcyBSb290IENlcnRpZmljYXRl) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.IEF1dGhvcml0eSBHMTAeFw0xNjEwMDMxNjQzMjVaFw0yNjEwMDIyMDU0MzVaMGwx) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.FTATBgoJkiaJk/IsZAEZFgVsb2NhbDEaMBgGCgmSJomT8ixkARkWCm1pdGVrY2xv) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dWQxNzA1BgNVBAMTLk1pdGVrIENsb3VkT3BzIFNlY3VyZSBDZXJ0aWZpY2F0ZSBB) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dXRob3JpdHkgRzEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCh6+2r) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.evlG/Ke3ZM6kVw/Km5wbhigkDl39S/LeHqD1bMx8ZZsNzXd3RZhpLyFL1WJ4xeuh) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.QR+zmf5DSOH1svJtX43Vt6r+EfkChJykPx0bv6Xuezzxk4Df2J7WYjaOLUyAv6Is) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dXfzQU9C+OAwCFOp8t+1LSREPyQSyYpGbIEEhH2L4LdSVAUUMKxpX0xJukelbiQQ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.W/kzJcLqLCEDNi+Bqc2/nk55Bw2ZF5jRNhT/csdyi8Vv+qw2Q+OyOqod3fQP6i8b) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.jAGPo3KocXQgoeelrwOrvfGVdkXPvJfmWeNZnTnXUzj4/XTp51PZKq1iLpZRvFEL) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.3JP4DEDhiPbin677ReSsWeiFdD6I8oGnMY7gIDdiHUOZfsV5VwqB3Cbjw0z/XRFD) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.vOlkw6ravPtwtm1gpFfC3Bua/JuS/pFeBaSBAfXaFkb50zS7Ss0UbRgyVPtTiYBq) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.d3eK5BGAGcam3zIlNQ8UiL01OxcU9VHE2kbzERRyPTOKt8WAwLyKtHICleiGvbDw) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.2sGELyGoDXONLA5sZ+32kT/TQBIqbMkRfCqLf4F/ugb+cBIlqiAtY/nfpqUqMqVU) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.5SMP+6FrcSy4Ggi0gPxE71Mq/htCc5h4etIk6Q9exAGEcS5T7e/0yM+dK0X71Jer) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.G0jT+rCNC+E6kEOxkVvFnRy+LjaSCae7S3oXRwIDAQABo4ICpjCCAqIwEgYJKwYB) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.BAGCNxUBBAUCAwEAATAjBgkrBgEEAYI3FQIEFgQUdCd1j7SZrmZ78DhgnZd8bvWQ) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.2gAwHQYDVR0OBBYEFL7C7Uf768uHGzDC9pIBRzf1Zf9lMBkGCSsGAQQBgjcUAgQM) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.HgoAUwB1AGIAQwBBMAsGA1UdDwQEAwIBhjAPBgNVHRMBAf8EBTADAQH/MB8GA1Ud) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.IwQYMBaAFHHckd6EnhFzKL8quMmtTXvOi9S4MIH9BgNVHR8EgfUwgfIwge+ggeyg) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.gemGgeZsZGFwOi8vL0NOPU1pdGVrJTIwQ2xvdWRPcHMlMjBSb290JTIwQ2VydGlm) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.aWNhdGUlMjBBdXRob3JpdHklMjBHMSxDTj1DTE9VRC1DQS0wMSxDTj1DRFAsQ049) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.UHVibGljJTIwS2V5JTIwU2VydmljZXMsQ049U2VydmljZXMsQ049Q29uZmlndXJh) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dGlvbixEQz1taXRla2Nsb3VkLERDPWxvY2FsP2NlcnRpZmljYXRlUmV2b2NhdGlv) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.bkxpc3Q/YmFzZT9vYmplY3RDbGFzcz1jUkxEaXN0cmlidXRpb25Qb2ludDCB7QYI) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.KwYBBQUHAQEEgeAwgd0wgdoGCCsGAQUFBzAChoHNbGRhcDovLy9DTj1NaXRlayUy) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.MENsb3VkT3BzJTIwUm9vdCUyMENlcnRpZmljYXRlJTIwQXV0aG9yaXR5JTIwRzEs) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Q049QUlBLENOPVB1YmxpYyUyMEtleSUyMFNlcnZpY2VzLENOPVNlcnZpY2VzLENO) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.PUNvbmZpZ3VyYXRpb24sREM9bWl0ZWtjbG91ZCxEQz1sb2NhbD9jQUNlcnRpZmlj) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.YXRlP2Jhc2U/b2JqZWN0Q2xhc3M9Y2VydGlmaWNhdGlvbkF1dGhvcml0eTANBgkq) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.hkiG9w0BAQsFAAOCAgEAZuZA/oeYNSQEJI74PRtrcNRMP/622qgp8Oj5Xu39H3yI) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.OB9sflVQa1Gya2adOJ7SF77qtcS+pSyM4TuUnqafD9f3T/YsOMuN5kvOjr7ICXZR) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.2BSVJXbb74aPVuRT0tZ24qrjTlumGrilvXcFOnUSMBk3J9lbMM0Amdj1Rhcy4E1z) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.IGSgGYzdqzCypQcAU3IGCNTXgN7+P4LGg52rWVyprjlh0DszvJN3U5ULzERV8Ymu) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.DGop8y7Aj3dS6lRK1HnMzU+8tQFpBeVb4qHdoqU7bL9pdNTRs1ut+2SG0ggStK2i) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.61kNe941Lnj80JJLwYFN5sumC04apDXlSZzWb0C4VzkeR6Ct/Nb7Jn8EfU3gqnd+) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.dRXL79FzFbT8cugtc6fMp0eDExVjGIXkYWVPHMCg9rhnlBmjmYN0RvQe592CePuu) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.DvFw0vsrfokE0fKTaKL9PulhrunRSR+KYIlXL3cgfbAy3aYiJ5YExQrHsirgYSPd) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.Vztmn2QpT6wZW/vQwdPIwJFrhavFypA8qote4/obJtps3vW4eGDiz6hWDlKxZGLN) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.tXGM9/+p7RgGFUGZrvOLqqtiYwc3U6Cz/z6GoHdmJBasbgOGdrxI/TynDrIpfJtn) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.U62tGChgg7H/Qs5Z5hjl5GGHGrFFH4iEVjdR+Vk0HQx7H5DQAFzR7ktzeXRv+4k=) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.-----END CERTIFICATE-----) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef\client.rb ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.log_level        :info) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.log_location     STDOUT) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.chef_server_url  "https://chef.mydomain.local/organizations/MyOrganization") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.validation_client_name "chef-validator") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.file_cache_path   "c:/chef/cache") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.file_backup_path  "c:/chef/backup") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.cache_options     ^^^({:path =^^^> "c:/chef/cache/checksums", :skip_expires =^^^> true}^^^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.node_name "myNode") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.trusted_certs_dir "c:/chef/trusted_certs") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^> C:\chef\first-boot.json ^() && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.echo.{"mitk_windows_helper":{"hostname":"myNode"},"run_list":[]}) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.^)) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.@echo Starting chef to bootstrap the node...) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.SET "PATH=%PATH%;C:\ruby\bin;C:\opscode\chef\bin;C:\opscode\chef\embedded\bin") && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.chef-client -c c:/chef/client.rb -j c:/chef/first-boot.json -E Staging) && >> "%TEMP%\bootstrap-58702-1480608972.bat" (echo.)
DEBUG: [WinRM] opening remote shell on http://mynode.mydomain.local:5985/wsman
DEBUG: [WinRM] remote shell created with shell_id: AF80BCAA-B058-4A82-8BCC-7E50F67C267E
/opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/http/response_handler.rb:69:in `raise_if_wsman_fault': [WSMAN ERROR CODE: 2147942606]: <f:WSManFault Code='2147942606' Machine='mynode.mydomain.local' xmlns:f='http://schemas.microsoft.com/wbem/wsman/1/wsmanfault'><f:Message><f:ProviderFault path='%systemroot%\system32\winrscmd.dll' provider='Shell cmd plugin'>The filename or extension is too long. </f:ProviderFault></f:Message></f:WSManFault> (WinRM::WinRMWSManFault)
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/http/response_handler.rb:52:in `raise_if_error'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/http/response_handler.rb:36:in `parse_to_xml'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/http/transport.rb:186:in `send_request'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/shells/cmd.rb:44:in `send_command'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/shells/base.rb:125:in `with_command_shell'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/shells/base.rb:80:in `run'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/winrm_session.rb:69:in `block in relay_command'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/winrm-2.1.0/lib/winrm/connection.rb:43:in `shell'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/winrm_session.rb:67:in `relay_command'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/winrm_knife_base.rb:130:in `block in relay_winrm_command'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/winrm_knife_base.rb:128:in `each'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/winrm_knife_base.rb:128:in `relay_winrm_command'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/winrm_knife_base.rb:114:in `run_command'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap_windows_base.rb:334:in `block in bootstrap'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap_windows_base.rb:400:in `create_bootstrap_bat_command'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap_windows_base.rb:332:in `bootstrap'
    from /Users/MYUSER/.chefdk/gem/ruby/2.3.0/gems/knife-windows-1.7.1/lib/chef/knife/bootstrap_windows_winrm.rb:60:in `run'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/chef-12.15.19/lib/chef/knife.rb:429:in `block in run_with_pretty_exceptions'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/chef-12.15.19/lib/chef/local_mode.rb:44:in `with_server_connectivity'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/chef-12.15.19/lib/chef/knife.rb:428:in `run_with_pretty_exceptions'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/chef-12.15.19/lib/chef/knife.rb:219:in `run'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/chef-12.15.19/lib/chef/application/knife.rb:156:in `run'
    from /opt/chefdk/embedded/lib/ruby/gems/2.3.0/gems/chef-12.15.19/bin/knife:25:in `<top (required)>'
    from /usr/local/bin/knife:57:in `load'
    from /usr/local/bin/knife:57:in `<main>`

I did some research and i found this information that may be helpfull:

1- I found that there is a hardcoded limit in knife-windows on the amount of data to be transfer.This is limited to 5000. I had to change that get to the server during my debugging. This limit is located in knife-windows/lib/chef/knife/bootstrap_windows_base.rb between lines 383 and 401. i changed it on mine to be able to move forward 2- After i was not able to perform winrm i hit a limit with shell execution when cmd is called by knife over winrm. This is limit that exists in cmd and (apparently is hardcoded).

Is it possible to switch from cmd to Powerhsell as executioner for knife bootstrap (i know knife winrm i can specify the shell type) Any thoughts?

tas50 commented 5 years ago

Hey there. In Chef Infra Client 15 we completely rewrote the bootstrap functionality of Chef to use train engine. That rewrite fixed a large number of long standing issues and moves us to a much more robust connection method for bootstrapping. There is high likelihood that this issue has been resolved with that rewrite. I'm going to close this out at this point, but if you encounter the problem with Chef Infra Client 15 please open it up again.