Skip to content

Instantly share code, notes, and snippets.

# CopyManagedDisk.ps1
# Morgan Simonsen
# morgansimonsen.com
#
# Copies an Azure managed disk from one Azure region to another via a storage account
[CmdletBinding()]
Param(
[Parameter(Mandatory=$True,Position=1,
HelpMessage="Source resource group where the managed disk(s) to copy is.")]
<#
.SYNOPSIS
PowerShell script to add segment to IIS Request Filtering Hidden Segments
.DESCRIPTION
Specify the config element, website and the segment to add to the list of Hidden Segments
.PARAMETER ConfigFile
The IIS config element to apply the hidden segment to
ApplicationHost: system32\inetsrv\config\applicationhost.config global section
ApplicationHost: system32\inetsrv\config\applicationhost.config using the 'location' tag to target the website
WebConfig: the web.config file in the root of the website directory

Keybase proof

I hereby claim:

  • I am morgansimonsen on github.
  • I am morgansimonsen (https://keybase.io/morgansimonsen) on keybase.
  • I have a public key ASCUOxntc2MXmp9MpWApjP4iTX5KSLJv-OnlBdnRVleHvAo

To claim this, I am signing this object: