-
-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
disable_firewall is not idempotent on Windows #183
Comments
Hi there -- did the firewall service get stopped outside Chef? We do this to disable it:
And this to check to see if it's disabled (we look for
|
Disabling the firewall on Windows appears to not only turn it off but also stop and disable the Windows Firewall service. |
Hmm, I agree. I'll have to see why our current testing didn't catch this scenario. |
Microsoft recommends against disabling the Firewall service. This also causes Remote Desktop and WinRM sessions to be disconnected, and blocks new connections until a reboot occurs, which causes Test Kitchen runs to fail, making it tricky to test this scenario. As far as testing this goes, this could help, since it's an issue with idempotency and not, strictly speaking, with the cookbook functionality. Thanks for the extraordinarily quick replies! |
Cookbook version
2.6.2
Chef-client version
12.18.31
Platform Details
Windows Server 2012 R2 Datacenter in Microsoft Azure
Scenario:
Running disable_firewall more than once causes a chef failure
Steps to Reproduce:
include_recipe 'firewall::disable_firewall'
Run chef-client on the machine more than once.
Expected Result:
Firewall is disabled on the first run, no action is taken on the second run.
Actual Result:
The text was updated successfully, but these errors were encountered: