diff --git a/images/win/post-generation/SshHostKeys.ps1 b/images/win/post-generation/SshHostKeys.ps1 deleted file mode 100644 index 114a98d6a..000000000 --- a/images/win/post-generation/SshHostKeys.ps1 +++ /dev/null @@ -1,4 +0,0 @@ -# Add well-known SSH host keys to ssh_known_hosts - -ssh-keyscan -t rsa github.com >> "C:\Program Files\Git\etc\ssh\ssh_known_hosts" -ssh-keyscan -t rsa ssh.dev.azure.com >> "C:\Program Files\Git\etc\ssh\ssh_known_hosts" \ No newline at end of file diff --git a/images/win/scripts/Installers/Install-Git.ps1 b/images/win/scripts/Installers/Install-Git.ps1 index 2a5ea9259..16b7ac15e 100644 --- a/images/win/scripts/Installers/Install-Git.ps1 +++ b/images/win/scripts/Installers/Install-Git.ps1 @@ -40,5 +40,10 @@ Choco-Install -PackageName hub Add-MachinePathItem "C:\Program Files\Git\bin" +# Add well-known SSH host keys to ssh_known_hosts + +ssh-keyscan -t rsa github.com >> "C:\Program Files\Git\etc\ssh\ssh_known_hosts" +ssh-keyscan -t rsa ssh.dev.azure.com >> "C:\Program Files\Git\etc\ssh\ssh_known_hosts" + Invoke-PesterTests -TestFile "Git" -TestName "Git" Invoke-PesterTests -TestFile "CLI.Tools" -TestName "Hub CLI"