[chef] Idempotent IIS


Chronological Thread 
  • From: Kenneth Barry < >
  • To:
  • Subject: [chef] Idempotent IIS
  • Date: Fri, 21 Feb 2014 11:31:15 -0800

My initial testing demonstrates that the IIS Cookbook is not fully idempotent (See below for an example)

Code

176        iis_config "-section:system.webServer/httpCompression /+\"dynamicTypes.[mimeType='application/json; charset=utf-8',enabled='True']\" /commit:apphost" do
177         action :config
178        end

Results from first run
....
[2014-02-20T17:28:57-05:00] INFO: IIS Config command run
[2014-02-20T17:28:57-05:00] INFO: Processing iis_config[-section:system.webServer/httpCompression /+"dynamicTypes.[mimeType='application/json; charset=utf-8',enabled='True']" /commit:apphost] action config (webserver::iisbase line 176)
[2014-02-20T17:28:57-05:00] INFO: IIS Config command run
....

Results from second run

....
[2014-02-20T17:29:40-05:00] INFO: Processing iis_config[-section:system.
webServer/httpCompression /
+"dynamicTypes.[mimeType='application/json; charset=utf-8',enabled='True']" /commit:apphost] action
 config (webserver::iisbase line 176)

================================================================================
Error executing action `config` on resource 'iis_config[-section:system.webServer/httpCompression /
+"dynamicTypes.[mimeType='application/json; charset=utf-8',enabled='True']" /commit:apphost]'
================================================================================

Question:
How are (those of you who are working in Windows/IIS), ensuring Idempotent Recipes for configuring IIS?




Archive powered by MHonArc 2.6.16.

§