Coder Social home page Coder Social logo

benhoiiand / powershell Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sous-chefs/powershell

0.0 1.0 0.0 334 KB

Development repository for Powershell Chef cookbook

Home Page: https://supermarket.chef.io/cookbooks/powershell

License: Apache License 2.0

Ruby 100.00%

powershell's Introduction

Powershell Cookbook

AppVeyor Build status Cookbook Version

Installs and configures PowerShell 2.0, 3.0, 4.0 or 5.0.

Requirements

Platforms

Not every version of Windows supports every version of Powershell. The following table illustrates Powershell support across the Windows family. Included means that the base installation of the operating system includes the indicated version of Powershell.

Windows Version PowerShell 2.0 PowerShell 3.0 PowerShell 4.0 PowerShell 5.0
Windows Server 2008 R2 Included Supported Supported Supported
Windows Server 2012 / Windows 8 Included Included Supported Supported
Windows Server 2012R2 / Windows 8.1 Included Not Available Included Supported

Chef

  • Chef 12.6+

Cookbooks

  • windows 3.0+

PowerShell also requires the appropriate version of the Microsoft .NET Framework to be installed, if the operating system does not ship with that version. The following community cookbooks are used to install the correct version of the .NET Framework:

  • ms_dotnet

Resources

powershell_module

Installs or uninstalls a Powershell module.

Actions

  • :install: install the powershell module
  • :uninstall: uninstall the powershell module

Attribute Parameters

  • name: name attribute. Name of the module to install or uninstall.
  • source: quoted string of Local directory path(Not zipfile) or URL for the zipped module folder.
  • package_name: quoted string of name of the module to install or uninstall.
  • destination: location where module should be installed

Examples

# Install module from local directory path
# change the package_name and source
powershell_module "PsUrl" do
  package_name "PsUrl"
  source "C:\\PsUrl"
end
# Install from URL of zipped module folder
powershell_module "posh-git" do
  package_name "posh-git"
  source "https://github.com/dahlbyk/posh-git/zipball/master"
end
# change the package_name
powershell_module "Uninstall PsUrl" do
  package_name "PsUrl"
  action :uninstall
end
# Install without using 'source' attribute
powershell_module "https://github.com/dahlbyk/posh-git/zipball/master" do
  package_name "posh-git"  
end

Usage

Note: The installation may require a restart of the node being configured before PowerShell can be used.

default

The default recipe contains no resources and will do nothing if included on a run_list.

powershell2

Include the powershell2 recipe in a run list, to ensure PowerShell 2.0 is installed. If the platform is not supported, a warning will be logged.

powershell3

Include the powershell3 recipe in a run list, to install PowerShell 3.0 is installed on applicable platforms. If the platform is not supported, a warning will be logged.

powershell4

Include the powershell4 recipe in a run list, to install PowerShell 4.0 is installed on applicable platforms. If the platform is not supported, a warning will be logged.

powershell5

Include the powershell5 recipe in a run list, to install PowerShell 5.0 is installed on applicable platforms. If the platform is not supported, a warning will be logged.

References

License & Authors

Copyright:: 2011-2016, 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.

powershell's People

Contributors

tas50 avatar smurawski avatar siddheshwar-more avatar tjnicholas avatar schisamo avatar prabhu-das avatar jaym avatar annih avatar stensonb avatar sethvargo avatar trevorghess avatar webframp avatar juliandunn avatar jasonmorgan avatar burnzy avatar nathenharvey avatar pmorton avatar it-praktyk avatar jugatsu avatar bheuvel avatar cwebberops avatar dpiessens avatar mhorbul avatar matthodge avatar ranjib avatar ryanjarv avatar skoczen avatar

Watchers

Ben Holland avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.