rgl / windows-vagrant

Windows 11/2022/2025 Base Vagrant Box (https://app.vagrantup.com/rgl)
MIT License
362 stars 95 forks source link

How to downgrade PowerShell in Windows 2012? #10

Closed metametadata closed 4 years ago

metametadata commented 4 years ago

Hello! Is it possible to downgrade PowerShell (current version is 5.1, expected version is 4.0) in rgl/windows-server-2012-r2-standard-amd64 box?

I've tried wusa.exe /uninstall /KB:3191564 but it fails. So far it seems that the only option for me is to repack the box without running provision-powershell.ps1.

rgl commented 4 years ago

Sorry, but I have no idea how; nor why you would want to do that.

Removing that provision step should do the trick in stopping it from being installed, like you found out :-)

But I have no intention of supporting that. Even windows 2012 is now too old, and I will remove it from this repository once I can.

metametadata commented 4 years ago

I see, thanks.

why you would want to do that

I have a project which must support old machines running Windows 2012 with PowerShell 4. I use Vagrant to run automated test suite which proves such compatibility.

I will remove it from this repository once I can.

This would be a loss. Maybe consider making it archived instead?

rgl commented 4 years ago

This repository wont go away. Its just the master branch that will eventually be modified to be without windows 2012 r2.