title: Getting Docker CLI automatically installed on server 2016/2019
body: <p>Does anyone know how to install docker including docker CLI in an automated way on windows servers??
  I have found the following code to enable containerization and install docker engine.</p>
  
  <pre class="lang-bsh prettyprint-override"><code>Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All
  Enable-WindowsOptionalFeature -Online -FeatureName Containers -All
  </code></pre>
  
  <p>reboot here</p>
  
  <pre class="lang-bsh prettyprint-override"><code>Install-Module -Name DockerMsftProvider -Force
  Install-Package -Name docker -ProviderName DockerMsftProvider -Force
  </code></pre>
  
  <p>I try to find docker cli under C:\Program files\Docker\Docker
  Everything else is there, CLI plugins, docker.exe, etc.. the packages are also installed successfully on ver 19</p>
  
  <p>I need the docker CLI as I want to automatically move to "windows containers" after the installation</p>