Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

Select Status

RSS

webpi (25) Versions 4.2.3

Installs/Configures the Microsoft Web Platform Installer (WebPI)

Policyfile
Berkshelf
Knife
cookbook 'webpi', '= 4.2.3', :supermarket
cookbook 'webpi', '= 4.2.3'
knife supermarket install webpi
knife supermarket download webpi
README
Dependencies
Changelog
Quality 17%

webpi Cookbook

Build status Cookbook Version

Microsoft Web Platform Installer (WebPI) automates the installation of Microsoft's entire Web Platform. This cookbook makes it easy to get WebpiCmdLine.exe the lightweight CLI version of WebPI onto a Windows node. It also exposes a resource for installing WebPI products idempotently.

Requirements

Platforms

  • Windows 7
  • Windows Server 2008 R2
  • Windows 8, 8.1
  • Windows Server 2012 (R1, R2)

Chef

  • Chef 12.6+

Cookbooks

  • windows 2.0+

Attributes

  • node['webpi']['home'] - location to install WebPI files to. Default is %SYSTEMDRIVE%\webpi
  • node['webpi']['url'] - Path to download webpi zip.
  • node['webpi']['xmlpath'] - Optional path to custom xml file.
  • node['webpi']['install_method'] - Method of installing webpi via msi or zip. Default is msi.
  • node['webpi']['msi'] - Location of msi file to use.
  • node['webpi']['msi_package_name'] - Windows package name, found in registry, for msi. Defaults to "Microsoft Web Platform Installer 4.5"

Resources

webpi_product

Actions

  • :install: install a product using WebpiCmdLine

Properties

  • product_id: name property. Specifies the ID of a product to install.
  • accept_eula: specifies that WebpiCmdline should auto-accept EULAs. Default is false.
  • returns: specifies the return value(s) expected for a successful installation. Can be a single integer or array of integers. Default is [0, 42]

Examples

Install IIS 7 Recommended Configuration (will install IIS 8 on Windows 2012 despite the name)

webpi_product 'IIS7' do
  accept_eula true
  action :install
end

Install Windows PowerShell 2.0

webpi_product 'PowerShell2' do
  accept_eula true
  action :install
end

Install Windows Azure Powershell 1.0 (will return a 3010 exit code to signify a successful installation that requires a reboot)

webpi_product 'WindowsAzurePowerShellGet' do
  accept_eula true
  action :install
  returns 3010
end

webpi_application

Actions

  • :install: install an application using WebpiCmdLine

Properties

  • app_id: name property. Specifies the ID of an application to install.
  • accept_eula: specifies that WebpiCmdline should auto-accept EULAs. Default is false.
  • suppress_reboot: specifies if we need to stop or suppress the reboot. Default is True.
  • iis_express: used only with applications that intergrate with IIS. Default value is False.
  • mysql_password: Used to give a mysql password for application which requires it.
  • sql_password: Used to give a sql password for application which requires it.
  • other_options: Any other options related to applications needed to be appended. Default value is empty string.
  • returns: specifies the return value(s) expected for a successful installation. Can be a single integer or array of integers. Default is [0, 42]

Examples

Installing WebMatrix while Accepting the EULA and also install app to IISExpress
Ex: >WebPICMD.exe /Install /Products:WebMatrix /AcceptEula /IISExpress

webpi_application 'WebMatrix' do
  accept_eula true
  iis_express true
  action  :install
end

Installing an application to MicrosoftAzure ServiceFabric CoreSDK
Ex: >WebPICMD.exe /Install /Applications:MicrosoftAzure-ServiceFabric-CoreSDK /AcceptEula

webpi_application 'MicrosoftAzure-ServiceFabric-CoreSDK' do
  accept_eula true
  action :install
end
password = data_bag_item('secrets','mysqlpassword')['password'] # Should be a encrypted data bag
webpi_application 'AcquiaDrupal' do
  accept_eula    true
  mysql_password password # To be set from encrypted databag
  action         :install
end

Usage

default

Downloads and unzips WebpiCmdLine.exe to the location specified by node['webpi']['home']. WebpiCmdLine.exe is used required by the webpi_product LWRP for taking all actions.

License & Authors

Author: Cookbook Engineering Team (cookbooks@chef.io)

Copyright: 2011-2019, Chef Software, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

webpi Cookbook CHANGELOG

This file is used to list changes made in each version of the webpi cookbook.

4.2.3 - 2021-08-31

  • Standardise files with files in sous-chefs/repo-management

4.2.2 - 2021-06-01

  • resolved cookstyle error: recipes/install-msi.rb:29:21 warning: Lint/SendWithMixinArgument

4.2.1 (2017-05-30)

  • Use action_class instead of action_class.class_eval

4.2.0 (2017-04-05)

  • Convert the install LWRP to a custom resource
  • Added testing of the resource in appveyer

4.1.1 (2017-03-29)

  • Resolve incompatibility with windows 3.0 cookbook

4.1.0 (2017-03-20)

  • Test with Local Delivery instead of Rake
  • Require windows 2.0 or later

4.0.0 (2017-02-18)

  • Use package vs. windows_package resource which increases the requirement to Chef 12.6+

3.1.0 (2016-12-27)

  • add returns argument to webpi_product resource
  • Update the minimum chef requirement to 12.1 from 12.0

3.0.0 (2016-09-06)

  • Remove support for Chef 11

2.1.0 (2016-09-01)

  • Resolve rubocop warnings
  • Add use_inline_resources to the provider
  • Add chef_version metadata
  • Testing updates

v2.0.0 (2016-01-04)

  • Install WebPI 5.0 by default
  • Fix runs on Chef 11 systems

v1.2.9 (2015-12-30)

Improvement

  • Modernization of cookbook supporting travis ci, kitchen convergence testing, style checking and foodcritic rule compliance
  • Removed unnecessary includes of the default recipe in the windows cookbook to eliminate warnings

v1.2.8 (2014-02-14)

Bug

  • COOK-3832 - install-msi recipe should leverage chef cache

v1.2.6

  • [COOK-3372] - unzip webpi if webpi executable doesn't exist

v1.2.4

Improvement

  • COOK-3474 - Upgrade WebPI (4.5 no longer exists)

v1.2.2

Improvement

  • [COOK-2719]: update webpi documentation to show that Windows 2012
  • and Windows 8 are supported

v1.2.0

  • [COOK-2298] - webpi will not install anything due to logic bug
  • [COOK-1270] - webpi creates logs with timestamps in the name
  • cluttering c:\
  • [COOK-2438] - WebPI should use an attribute for MSI package name
  • [COOK-2452] - WebPI should check comma separated string of
  • components to determine which to install if any

v1.1.0

  • [COOK-1251] - Fix LWRP "NotImplementedError"
  • [COOK-1726, COOK-1760] - Upgrade to webpi version 4

v1.0.4

  • Created the ability to use the XML parameter for custom xml files.

v1.0.2

  • Ruby 1.9 compat fixes
  • don't unzip if files already exist

v1.0.0

  • initial release

Collaborator Number Metric
            

4.2.3 failed this metric

Failure: Cookbook has 1 collaborators. A cookbook must have at least 2 collaborators to pass this metric.

Contributing File Metric
            

4.2.3 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file

Cookstyle Metric
            

4.2.3 failed this metric

Chef/Deprecations/ResourceWithoutUnifiedTrue: Set `unified_mode true` in Chef Infra Client 15.3+ custom resources to ensure they work correctly in Chef Infra Client 18 (April 2022) when Unified Mode becomes the default. (https://docs.chef.io/workstation/cookstyle/chef_deprecations_resourcewithoutunifiedtrue): webpi/resources/application.rb: 1
Chef/Deprecations/ResourceWithoutUnifiedTrue: Set `unified_mode true` in Chef Infra Client 15.3+ custom resources to ensure they work correctly in Chef Infra Client 18 (April 2022) when Unified Mode becomes the default. (https://docs.chef.io/workstation/cookstyle/chef_deprecations_resourcewithoutunifiedtrue): webpi/resources/product.rb: 1
Chef/Modernize/WindowsZipfileUsage: Use the archive_file resource built into Chef Infra Client 15+ instead of the windows_zipfile from the Windows cookbook (https://docs.chef.io/workstation/cookstyle/chef_modernize_windowszipfileusage): webpi/recipes/install-zip.rb: 36

Run with Cookstyle Version 7.32.1 with cops Chef/Deprecations,Chef/Correctness,Chef/Sharing,Chef/RedundantCode,Chef/Modernize,Chef/Security,InSpec/Deprecations

No Binaries Metric
            

4.2.3 passed this metric

Testing File Metric
            

4.2.3 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file

Version Tag Metric
            

4.2.3 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number