chef / knife-windows

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

Use mixlib-install to download and install chef supporting bootstrap on Windows Nano Server #399

Closed mwrock closed 5 years ago

mwrock commented 7 years ago

This PR replaces the current download and install logic in the default knife-windows template with the install command from mixlib-install. There are two primary motivations here:

  1. Align download and install logic accross tooling ecosystem. This puts knife-windows on the same code path as test-kitchen and chef-provisioning.
  2. Enable the bootstrapping of Windows Nano Server nodes. Mixlib-Install supports nano

Currently this PR drops support for the :architecture knife config setting. Mixlib-Install will choose the architecture based on the architecture of the node. It would be straight forward to change mixlib-install to support this. However, 64bit has been out for nearly a year and I think its safe to remove that support.

This PR also drops support for --install-as-service introduced in 1.0.0. Mixlib-install does not support installing as a service. We could add it but we are currently encouraging customers to prefer a scheduled task over service and have removed the service recipie from the chef-client cookbook.

This also requires powershell 2.0 or greater be installed. This is satisfied by default on Windows 2008R2 and higher, but older versions will require the installation of WMF 2.0 or higher. I have added words to the readme to reflect this.

In light of the above two dropped feaures we may consider this a 2.0.

mwrock commented 7 years ago

This PR "works" in bootstrapping nano and non-nano nodes.

mwrock commented 7 years ago

image

wrightp commented 6 years ago

@mwrock I'm starting to looking into implementing mixlib-install in knife core. Hopefully they'll be enough work complete to make any changes to knife-windows for v1 support easy. My plan is to have windows bootstrap support for ps v2 work natively

tas50 commented 5 years ago

Closing this out since things have drifted so much and windows nano isn't what it once was.