Skip to content

Instantly share code, notes, and snippets.

View oprinmarius's full-sized avatar

Oprin Marius oprinmarius

View GitHub Profile

Keybase proof

I hereby claim:

  • I am oprinmarius on github.
  • I am oprinmarius (https://keybase.io/oprinmarius) on keybase.
  • I have a public key ASC2tKEZONvIbFG0R8E5qM7WPirEU7ryokf7DW0-bfuloAo

To claim this, I am signing this object:

@oprinmarius
oprinmarius / Migrate-AzureVM.ps1
Created August 6, 2019 10:42 — forked from scott-kloud/Migrate-AzureVM.ps1
Migrates a Azure Virtual Machine to another subscription or data centre
<#
.SYNOPSIS
Migrates a Azure Virtual Machine to another subscription or data centre
.DESCRIPTION
Shutsdown the source VM
Exports the VM config to a temporary file
Loops through all Azure disks attached to the source VM
Schedules an async copy of the underlying VHD to the destination storage account
- optionally overwrites existing VHD in destination if it exists