万本电子书0元读

万本电子书0元读

顶部广告

Learning PowerShell DSC电子书

售       价:¥

22人正在读 | 0人评论 9.8

作       者:James Pogran

出  版  社:Packt Publishing

出版时间:2015-10-21

字       数:299.8万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:此类商品不支持退换货,不支持下载打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(1条)
  • 读书简介
  • 目录
  • 累计评论(1条)
Get started with the fundamentals of PowerShell DSC and utilize its power to automate deployment and configuration of your serversAbout This BookCreate flexible and maintainable deployments using DSC configuration *s that stand the test of timeExplore the in depth details of the core architecture, concepts, and practices used by PowerShell DSCA step-by-step guide that shows you how to start using and taking advantage of PowerShell DSC Who This Book Is For This book is intended for system administrators, developers, or engineers who are responsible for configuration management and automation and wish to learn PowerShell Desired State Configuration for efficient management, configuration and deployment of systems and applications.What You Will LearnUnderstand configuration management and why you need itCraft flexible, reusable, and maintainable configuration *s for thousands of serversCreate custom DSC resources to manage any application or server settingApply configuration data to deploy applications to different environmentsUtilize DSC push deployments to test your configuration *s and custom DSC resourcesInstall, configure and use DSC pull serversRun a Windows MSI packageDeploy a website In Detail Windows PowerShell is a task-based command-line shell and *ing language designed especially for system administration. PowerShell DSC is a new management platform that enables you to deploy and manage configuration data for software services and manage the environment in which these services run. This book begins with an overview of the basics of PowerShell DSC by covering the architecture and components of the Desired Sate Configuration. It will then familiarize you with the set of PowerShell language extensions and new PowerShell commands. It will help you understand and create DSC configurations with the help of practical examples, and to create DSC custom resources for your custom applications. Finally, you will learn to deploy a real world application using PowerShell DSC. By the end of the book, you will have better knowledge about the powerful Desired State Configuration platform, which helps you to achieve continuous delivery, and efficient management and easy deployment of data for systems.Style and approach This book is an in-depth guide to using PowerShell DSC, full of real-world experiences and best practices using PowerShell DSC. The topics are explained and build on one another other to provide a holistic learning experience. At the end, all the features learned will be used to create a real world application deployment using DSC.
目录展开

Learning PowerShell DSC

Table of Contents

Learning PowerShell DSC

Credits

About the Author

About the Reviewers

www.PacktPub.com

Support files, eBooks, discount offers, and more

Why subscribe?

Free access for Packt account holders

Instant updates on new Packt books

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Errata

Piracy

Questions

1. Introduction to PowerShell DSC

What is PowerShell DSC?

What is PowerShell?

On to PowerShell DSC

Why do we need Configuration Management?

What is DevOps?

DSC quick wins

A high level overview of DSC

The authoring phase

The staging phase

The execution phase

Why all the abstraction?

How does DSC help me?

The who

The what

The how

Idempotence

Isn't this Group Policy or SCCM?

DSC features

DSC requirements

DSC versions

PowerShell v4 DSC

v4 DSC language extensions

v4 DSC base resources

v4 DSC Cmdlets

The v4 DSC Pull Server

PowerShell v5 DSC

v5 DSC language extensions

v5 DSC base resources

v5 DSC Cmdlets

v5 improvements

The PowerShell ISE

Partial configurations and dependencies

Class-based DSC Resources

DSC built-in support for help

DSC run as credential support

DSC resource side-by-side installation

DSC resource script debugging

The separation of node and configuration IDs

DSC LCM MetaConfig updates

DSC LCM rich state information

DSC LCM RefreshMode values

DSC status from a central location

Summary

2. DSC Architecture

Overview

Push and pull modes

The push management model

The pull management model

The general workflow

Authoring

Syntax

Compilation

Staging

Execution

Push executions

Pull executions

The example workflow

Configuration data

Hardcoded data

Parameter-based data

Hashtable data

Local Configuration Manager

LCM settings

Configuration modes

ApplyOnly

ApplyAndMonitor

ApplyAndAutoCorrect

Refresh modes

The LCM configuration

An example LCM configuration

The DSC Pull Server

What is a DSC Pull Server?

What does the Pull Server do for us?

Automatic and continuous configuration

Repository

Reporting

Security

Setting up a DSC Pull Server

Pull Server settings

Installing the DSC server

Adding MOF files to a Pull Server

Adding DSC Resources to a Pull Server

Deployment considerations

General observations

LCM gotchas

Deployment mode differences

Summary

3. DSC Configuration Files

Defining a DSC configuration script file

Authoring DSC configuration files

DSC automatic variables

AllNodes

Node

ConfigurationData

DSC Resource import declarations

Import-DscResource

The DSC script file syntax

The Configuration keyword

The Node keyword

DSC Resource statements

The script file example

Defining a DSC configuration data file

Authoring DSC configuration data files

Configuration data syntax

The variable syntax

The data file syntax

Allowable DSC configuration content

Creating reusable DSC configurations

Nested DSC configurations

Nested DSC configuration syntax

Nested DSC configuration limitations

DSC composite resources

Why use DSC composite resources?

The DSC composite resource syntax

DSC composite resource folder structure

DSC composite resource drawbacks

Debugging and troubleshooting configuration script files

Using DSC event logs

Enabling verbose logging

What do DSC event logs contain?

Gathering events from a single DSC operation

Event Viewer

PowerShell

Using the xDscDiagnostics module to analyze DSC logs

Get-xDscOperation

Trace-xDscOperation

Resetting the DSC engine cache

Enabling the debug mode

Fixing a stuck DSC run

Summary

4. DSC Resources

What are DSC Resources?

Creating a custom PowerShell v4 DSC Resource

The folder structure of a v4 DSC Resource

The syntax of a v4 DSC Resource

The DSC Resource definition file

Naming

Versioning

Parameters

Qualifiers

The DSC PowerShell module file

Get-TargetResource

Test-TargetResource

Set-TargetResource

Authoring custom DSC Resources

Creating DSC Resources manually

Creating DSC Resources automatically

Creating a custom PowerShell v5 DSC Resource

PowerShell classes

Class-based DSC Resources

The folder structure of v5 DSC Resources

The syntax of v5 DSC Resources

Declaring the class

Schema

Methods

Get

Test

Set

The advantages of a class-based DSC Resource

The disadvantages of a class-based DSC Resource

What makes a good DSC Resource

Idempotent

Do one thing well

Reuse code, but don't go overboard

Contribute back!

Testing custom DSC Resources

Using xDscResourceDesigner

Pester

Microsoft recommendations

How do you find DSC Resources?

Microsoft DSC Resource Kits

Installing DSC Resource Kits

The Microsoft PowerShell DSC GitHub repository

Installing DSC Resources from GitHub

The Microsoft PowerShell Gallery

PackageManagement

Installing PackageManagement

Initializing PackageManagement

Discover DSC Resources in the PowerShell Gallery

Installing DSC Resources in the PowerShell Gallery

Custom hosting options

Local SMB/network share

NuGet IIS

Third-party NuGet servers

Summary

5. Pushing DSC Configurations

Tooling

Setting things up

Test environments

Locally pushing DSC configurations

Setting up the test environment locally

Compiling configurations for local target nodes

Executing configurations for local target nodes

Remotely pushing DSC configurations

Setting up the test environment remotely

Compiling configurations for remote target nodes

Executing configurations for remote target nodes

Things you must consider when pushing DSC configurations

Summary

6. Pulling DSC Configurations

Creating DSC Pull Servers

DSC Pull Server setup considerations

DSC Pull Server types

The Windows Management Framework version

Initial setup tasks

Installing required DSC Resources

SSL certificates

SMB share creation

Preparing DSC Resources for Pull Server distribution

Miscellaneous tasks

Creating a WMF 4 DSC Pull Server

Creating a WMF 5 DSC Pull Server

Validating a DSC Pull Server install

Testing using a web browser

Testing using the command line

Registering target nodes with a DSC Pull Server

Registering a WMF 4 target node

Registering a WMF 5 target node

Pulling DSC configurations with a DSC Pull Server

Pulling DSC configurations using ConfigurationIDs

Pulling DSC configurations using RegistrationKeys

DSC Pull Server and target node status

Checking the current LCM configuration status

Triggering a DSC configuration to run on a target node

Triggering a WMF 4 target node

Triggering a WMF 5 target node

Using DSC logging to check on the status

Reporting on the target node status

Reporting on the target node status with the DSC Pull Server

Summary

7. Example Scenarios

Real life DSC usage

Setting up a common installation base

Installing software

A configuration management refresher

Complicated deployments

Handling change

Summary

Index

累计评论(1条) 1个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部