What you will learn in Practical Automation with PowerShell: Effective scripting from the console to the cloud
Effective scripting from the console to the cloud
Chapter by chapter
Concepts explained in this book
- automationAutomation is the execution of tasks by software with reduced manual intervention, especially for repeatable operational work.
- PowerShellWindows PowerShell is the Windows-only implementation of Microsoft's PowerShell command shell and scripting language, with version 5.1 as its final major release.
- mockingA mock is a test double that simulates a dependency or interaction so that code can be tested under controlled conditions.
- shell scriptA script is a text-based program that contains instructions for an interpreter to execute.
- Azure Automation Hybrid Runbook WorkerA hybrid runbook worker is a machine or agent-enabled execution target that runs Azure Automation jobs outside the Azure-hosted environment.
- remotingSSH remoting is a PowerShell capability for executing commands and scripts on remote computers through SSH.
- SecretManagementSecretManagement is a PowerShell module framework that provides a common interface for storing and retrieving secrets through registered vault extensions.
- secret vaultA secret vault is a protected repository for storing and retrieving sensitive values such as credentials, passwords, and API keys.
- triggerAn automation trigger is an event, condition, or invocation that initiates an automated process or workflow.
- action scriptAn action script is a script that performs the substantive operation initiated by a watcher or other automation component.
- pesterPester is a PowerShell testing framework for writing and running repeatable tests, including tests with mocked command behavior.
- password authenticationA password is a secret character sequence used to authenticate an identity or authorize access to systems.
- building blockA building block is a reusable component or capability that can contribute to an automation across multiple development stages.
- output streamAn output stream is the PowerShell pipeline channel that carries success-output objects from commands and functions.
- Test-PathTest-Path is a PowerShell cmdlet that tests whether a path exists and returns a Boolean result.
- runbookA runbook is an executable automation definition containing a script or workflow for performing operational tasks.
- phased delivery strategyA phased approach is a technique for developing an automation through successive stages that provide incremental improvements and benefits.
- regular expressionA regular expression is a notation for describing sets of strings and matching text against those descriptions.
- unit testA unit test is a software test that verifies the behavior of a small, isolated unit of code.
- Invoke-WebRequestInvoke-WebRequest is a PowerShell cmdlet that sends HTTP and HTTPS requests and processes web responses.
- hashtableA hashtable is a key-value collection that associates unique keys with values.
- module manifestA module manifest is a PowerShell data file that describes a module and specifies its metadata and exported or required components.
- maintainabilityAutomation maintainability is the ease with which an automated system can be understood, modified, and kept operational as requirements change.
- KeePassKeePass is a password manager that stores protected credentials and secrets in encrypted database files.
- Active SetupActive Setup is a Windows installation technique that performs per-user configuration after software is installed in a system context.
- terminating errorA terminating error is an execution error that stops the current PowerShell operation or script unless it is handled.
- scrapingWeb scraping is the automated extraction of data from web pages by retrieving and parsing their content.
- SecureStringSecureString is a .NET type intended to hold sensitive text in memory with restricted access and runtime-dependent protection behavior.
- answer fileAn unattended answer file is a configuration file containing responses that automate an operating-system installation without user interaction.
- Start-ProcessStart-Process is a PowerShell cmdlet that starts a process and can optionally wait for it to finish.
- Invoke-DbaQueryInvoke-DbaQuery is a dbatools PowerShell cmdlet that executes a query against a SQL database and returns the results as PowerShell objects.
- sensitive informationSensitive data is information whose unauthorized disclosure, alteration, or loss could cause harm or compromise security.
- script moduleA script module is a PowerShell module implemented with PowerShell code that packages functions, classes, variables, and supporting resources.
- scheduled taskA scheduled task is a configured operating-system task that runs a program or script according to specified triggers and execution settings.
- throwA throw statement generates an exception or terminating error that interrupts normal PowerShell execution.
- gitGit is a distributed version control system for tracking changes to files and coordinating work across repositories.
- Azure Automation accountAn Azure Automation account is an Azure resource that provides a managed boundary for storing and executing Automation assets such as runbooks, identities, and configuration.
- integration testIntegration testing verifies that multiple software components or systems function correctly together.
- control scriptA control script is a coordinating script that establishes remote connections, invokes commands, and collects returned information across multiple computers.
- CmdletBinding attributeThe CmdletBinding attribute enables advanced PowerShell function behavior, including common parameters such as verbose output and error handling.
- param blockA parameter block is the section of a PowerShell function or script that declares its input parameters and their metadata.
- actionAn automation action is an individual operation or step performed during an automated process to achieve its goal.
- -ErrorActionErrorAction is a PowerShell common parameter that specifies how a command responds to non-terminating errors.
- lookup fieldA lookup value is a SharePoint field value that references an item in another list.
- psm1 fileA PSM1 file is a PowerShell module script file that implements or loads a module's functions and supporting code.
- ConvertFrom-HtmlConvertFrom-Html is a command that converts HTML input into structured PowerShell objects, including HTML node data.
- XPathAn XPath query is an expression defined by the XPath language for selecting nodes in an XML or HTML document tree.
- PSModulePath environment variablePSModulePath is the PowerShell environment variable containing folders in which PowerShell searches for modules.
- automation goalAn intended outcome or set of outcomes that an automation process is designed to achieve.
- pipelineA PowerShell pipeline passes output objects from one command as input to subsequent commands or functions.
- secretA secret is confidential sensitive data, such as a credential, password, connection value, or API key, that requires protected storage and controlled access.
- Get-ItemGet-Item is a PowerShell cmdlet that retrieves an item, such as a file, directory, or registry item, from a specified path.
- Azure AutomationAzure Automation is Microsoft's cloud service for automating recurring operational tasks across Azure and other environments.
- Where-ObjectWhere-Object is a PowerShell cmdlet that filters objects in a pipeline according to a specified condition.
- -WhatIfThe PowerShell WhatIf parameter reports the operations a command would perform without actually performing them.
- GitHubGitHub is a web platform for hosting, collaborating on, and distributing software source code through version-controlled repositories.
- try-catch statementA try/catch construct runs protected code and handles exceptions in a catch block.
- parameter validationParameter validation is a language-supported mechanism for restricting and checking values supplied to script parameters.
- cmdlet-based filteringCmdlet-based filtering is the technique of restricting command results through a cmdlet's filtering parameters before output is produced.
- recursionRecursion is the repeated traversal or invocation of nested structures through a self-referential operation.
- comment-based helpComment-based help is PowerShell documentation embedded in specially formatted comments associated with a script or function.
- OutputType attributeThe OutputType attribute declares the .NET types of objects that a PowerShell function or script is expected to output.
- parameter filterA parameter filter is a mock-selection condition that matches calls according to the parameters supplied to a command.
- managed identityA managed identity is an Azure-managed identity that lets applications authenticate to supported resources without directly managing secrets.
- return on investmentReturn on investment is a measure comparing the benefit gained from an investment with its cost.
- Azure Virtual Machine Run CommandAzure Virtual Machine Run Command is an Azure capability that executes commands on an Azure virtual machine through the Azure service.
- hypervisor-based remotingHypervisor-based remoting is remote command execution that uses a hypervisor or virtualization-management intermediary instead of direct network communication with the guest machine.
- Windows ISO fileAn ISO image is a file that contains a sector-by-sector representation of the contents and structure of an optical disc or bootable installation medium.
- JenkinsJenkins is an open-source automation server that orchestrates software delivery and other automated jobs.
- New-PSSessionNew-PSSession is a PowerShell cmdlet that creates a persistent PowerShell session on a local or remote computer.
- mandatory parameterA mandatory parameter is an input that must be supplied by the person or script initiating an automation.
- wrapper scriptA wrapper script is a script that surrounds another script or command with setup, monitoring, logging, or cleanup logic.
- script blockA script block is a PowerShell expression that groups commands and can be passed, stored, or invoked as a unit.
- Log AnalyticsLog Analytics is an Azure monitoring and data collection service that stores, searches, and analyzes diagnostic and metric data.
- environment variableAn environment variable is a named value supplied by an operating-system or process environment to applications and scripts.
- SecretStoreSecretStore is a PowerShell extension vault that stores secrets locally and associates them with a user and machine.
- authenticationAuthentication is the process of verifying an identity before granting access to a system or service.
- registry keyA registry key is a named hierarchical container in the Windows Registry that stores configuration values and subordinate keys.
- branchA branch is a named line of development in a version-control repository containing its own sequence of changes.
- configurationConfiguration data is static input that supplies values and parameters to a script without containing executable commands.
- API keyAn API key is a secret token used by an application or script to identify or authorize access to an application programming interface.
- agent-based remotingAgent-based remoting is remote script execution in which a locally installed software agent runs the script on the target device.
- key-based authenticationKey-based authentication is an authentication method that proves identity using cryptographic key material instead of a password.
- storage accountAn Azure storage account is an Azure resource that provides a unique namespace and access boundary for Azure Storage services and data objects.
- New-ItemNew-Item is a PowerShell cmdlet that creates a new item such as a file, directory, or other provider-managed resource.
- principle of least privilegeThe principle of least privilege is a security practice of granting an identity or process only the permissions required for its intended operations.
- dbatoolsdbatools is a community-maintained PowerShell module that provides automation commands for SQL Server administration and migration.
- SharePoint formA SharePoint form is a web form automatically provided for adding and editing items in a SharePoint list.
- Export-ScheduledTaskExport-ScheduledTask is a PowerShell cmdlet that exports a Task Scheduler task as XML.
- New-ScheduledTaskActionNew-ScheduledTaskAction is a PowerShell cmdlet that creates an action specifying the executable and arguments for a scheduled task.
- New-ScheduledTaskTriggerNew-ScheduledTaskTrigger is a PowerShell cmdlet that creates a trigger describing when a scheduled task runs.
- Register-ScheduledTaskRegister-ScheduledTask is a PowerShell cmdlet that creates or registers a task with Windows Task Scheduler.
- zip archiveAn archive file is a file that stores retained data separately from its active working location.
- end-user deviceAn end-user device is a computer primarily used directly by an individual rather than as a server.
- PSCredentialA credential object is a structured PowerShell value that packages an identity and its password or other secret for authentication.
- fixed parameterA fixed parameter is an input with a predetermined value that cannot be changed by the automation initiator.
- logical parameterA logical parameter is an input whose value is determined by decision logic and a fallback when the value cannot be determined.
- virtual switchA virtual switch is software-based network switching infrastructure that connects virtual machines to one another or to physical networks.
- system contextA system context is an operating-system execution context associated with a system-managed identity rather than an interactive user.
- Stop-ProcessStop-Process is a PowerShell cmdlet that stops one or more running processes.
- wrapperA wrapper function is a function that provides a simplified or specialized interface around other operations or functions.
- repositoryA GitHub repository is a version-controlled project storage space hosted on GitHub.
- Word object modelA Word COM object is a Component Object Model automation object that exposes Microsoft Word documents and application operations.
- ConvertTo-SecureStringConvertTo-SecureString is a PowerShell cmdlet that converts text into a SecureString, optionally using a supplied encryption key.
- injection attackAn injection attack is an attack in which untrusted input is interpreted as executable code or commands.
- $PSBoundParameters$PSBoundParameters is an automatic PowerShell variable containing the parameters explicitly supplied to the current function and their values.
- SQL parameterAn SQL parameter is a separately supplied value associated with a named placeholder in a SQL statement.
- SQL variableAn SQL variable is a named placeholder in a SQL statement whose value is supplied separately from the statement text.
- where clauseA where clause is the SQL query clause that restricts returned rows according to conditions on column values.
- SQL health checkA SQL health check is an automated scripted procedure that assesses the configuration or operational health of a SQL database environment and can notify when an undesired state is detected.
- persistent connectionA persistent connection is a remote connection established before command execution and maintained until it is explicitly closed.
- PowerShell DirectPowerShell Direct is a Hyper-V capability for executing PowerShell commands in a virtual machine through its host without requiring network connectivity to the guest.
- Add-VMDvdDriveAdd-VMDvdDrive is a Hyper-V PowerShell cmdlet that adds a virtual DVD drive to a virtual machine.
- New-VMNew-VM is a Hyper-V PowerShell cmdlet that creates a virtual machine with specified configuration and storage settings.
- resumabilityResumable automation is an automation design in which execution can restart after a failure and continue without repeating completed work or causing adverse effects.
- ValidateScript attributeThe ValidateScript attribute validates a PowerShell parameter by evaluating a script block against its supplied value.
- SharePoint listA SharePoint list is a structured collection of records stored in SharePoint, with fields that hold item data and status information.
- write-errorWrite-Error is a PowerShell cmdlet that writes a non-terminating error to the error stream.
- Get-PnpListItemGet-PnpListItem is a PnP PowerShell cmdlet that retrieves items from a SharePoint list.
- helper functionA helper function is a supporting function called by other functions to perform a reusable internal operation.
- public functionA public function is a module function intended to be available for direct use by module users.
- RequiredModulesRequiredModules is a module-manifest field that specifies modules required by a PowerShell module.
- verb-noun naming formatThe Verb-Noun naming pattern names PowerShell commands with an approved action verb followed by a singular noun.
- Invoke-RestMethodInvoke-RestMethod is a PowerShell cmdlet that sends HTTP or HTTPS requests and converts response content into usable PowerShell objects.
- COM objectA COM object is a software component that exposes interfaces through Microsoft's Component Object Model for interprocess or cross-application interaction.
- administratorAn administrator privilege is an elevated authorization that permits administrative operations beyond those available to a standard user.
- data typeA data type classifies the representation and permitted values of data, such as an integer, string, or binary value.
- default valueA default value is a predefined value supplied when an input is not provided or cannot be determined.
- ConvertFrom-StringDataConvertFrom-StringData is a PowerShell cmdlet that converts key-value text into a hashtable.
- Get-VariableGet-Variable is a PowerShell cmdlet that retrieves variables and their values from a session.
- Select-StringSelect-String is a PowerShell cmdlet that searches text for matching strings or regular expression patterns.
- Azure PowerShellThe Az PowerShell module is the modular Azure PowerShell package for managing Azure resources and services.
- universally unique identifierA universally unique identifier (UUID), also commonly called a GUID, is a 128-bit identifier designed to distinguish entities with an extremely low probability of collision.
- Remove-ItemRemove-Item is a PowerShell cmdlet that deletes files, directories, and other provider items.
- ZipFileSystem.IO.Compression.ZipFile is a .NET class that provides operations for reading and creating ZIP archives.
- Should -InvokeShould -Invoke is a test assertion command that verifies how many times a mocked command or function was called.
- general userA standard user is an account operating with ordinary permissions rather than elevated administrative rights.
- GitHub gistGitHub Gist is a GitHub service for creating, publishing, and sharing small code snippets or files with version history and access controls.
- reusable building blockA reusable building block is a modular automation component that can be incorporated into multiple processes.
- data structureA data structure is an organized representation of data and associated relationships for storing and processing information.
- runbook editorA runbook editor is an authoring interface for creating and modifying automation runbooks, often with coding assistance and access to automation assets.
- JSONJSON is a text-based data interchange format that represents structured values using objects, arrays, strings, numbers, Boolean values, and null.
- Windows Assessment and Deployment KitThe Windows Assessment and Deployment Kit is Microsoft's collection of tools for assessing and deploying Windows operating systems.
- Azure resource groupA resource group is an Azure management container for related resources that share a lifecycle and administrative scope.
- jobA job is an asynchronous PowerShell operation that runs work independently of the interactive command flow.
- PSObject propertyPSObject.Properties is the PowerShell collection that exposes an object's adapted and extended properties.
- Invoke-CommandAsInvoke-CommandAs is a PowerShell module that runs commands or script blocks under specified Windows security contexts, including the system account.
- Task SchedulerTask Scheduler is the Windows service and management facility for scheduling and running programs or scripts.
- YAMLYAML is a human-readable data-serialization language that represents structured data using indentation-based syntax.
- virtual machine provisioningThe process of creating and preparing a virtual machine and its associated resources.
- enumAn enumeration is a set of named constants, typically associated with underlying integral values.
- structured dataStructured data is information organized according to an explicit schema or representation with identifiable fields and relationships.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.
