Powershell Scripts


PowerShell working with Azure Resource Manager RM – Step By Step Changing RM Subscriptions

There are two different types resource modes in Azure. One is the Service Manager (classic) and the other is the new Resource Manager. Resource Manager is the new model and much, much better for a bunch of reasons. Those reasons are beyond the scope of this post but the way to connect to the Resource Manager is different in PowerShell that the Service Manager. For that reason, I wanted to outline how to connect to Azure Resource Manager in PowerShell.


Create Computer Certificate for Azure Authentication using PowerShell


Change or Set ExecutionPolicy to Enable PowerShell Scripts to Run


Azure Accounts with PowerShell


Azure Subscriptions with PowerShell

Shows how to work with changing default & Current accounts, and subscriptions in Azure using PowerShell.


LogIt PowerShell Script to Log to Screen and Text File


Working with Files & Paths using PowerShell System.IO and Get-Location


GUI popup Set-Location via File popup dialog using .BrowseForFolder


GUI popup FileOpenDialog to collect Filename and Path


GUI popup FileSaveDialog to collect Filename and Path using PowerShell

Demonstrate how to Open a GUI File Save Dialog box to collect a filename and path using PowerShell. How to collect filename and path for a save as operation using GUI popup Dialog in PowerShell.


Collect a Yes or No Response from User using PowerShell; Fully evaluate response.

Demonstrate how to ask the user a question with a Yes or No Answer using PowerShell. Collect a Yes or No Response from the user using PowerShell.


Working with Compressed Archive .ZIP Files Using PowerShell

Demonstrate how to create a compressed .ZIP file and add files to it using PowerShell. Demonstrate multiple methods to extract files from a .zip. Delete, Create, and add files to a zip file and extract files from a .ZIP.


Downloading Files from Public URL Using PowerShell

Demonstrate how to download files from an Online URL using PowerShell. Demonstrates downloading files from an Azure Storage container but same process works for any valid online URL.


Create ContosoDemo Web App on Clean Windows Server using PowerShell


Create ConsosoDemo SQL Server from Clean Windows Server with SQL installed


Install and Deploy Active Directory on a Clean Windows Server using PowerShell


GUI Popup Custom Form with EditBox, ListBox, ComboBox and more Using PowerShell

Demonstrate how create and work with GUI Forms using PowerShell. Shows how to create log Forms, add labels, text boxes, panels, comboboxes, PickLists, and more. Shows how to populate all fields including picklists and combobox lists and work with properties. Shows how to populate and work with array objects. Uses Azure commands to populate list data. Shows how to work with the results from the dialog and the changes made to the form objects.


Create Azure Service Using PowerShell


Execute Custom Script Using Azure Set-AzureVMCustomScriptExtension PowerShell


Create Azure Storage Account Using PowerShell


Working with Azure Storage Accounts with PowerShell


Upload to Azure Storage Entire Directory of files Using PowerShell


Create Azure Network file and Network with PowerShell


Create Azure Virtual Machine VM using PowerShell


Add Data Disk to Existing Azure VM using PowerShell


Create a Wait State Loop using PowerShell, uses Azure VM.PowerState


Build 3 Machine Lab in Microsoft Azure using PowerShell

3 Virtual Machines:

DC01 – Post configuration to deploy AD and use Static IP address

WFE01 – No configuration done YET, Website files are downloaded to SQL Server F:

SQL01 – SQL Configured with additional users, Adventure works Database (Test),

Firewall open, SQL security and defaults configured, Drives and folders

configured.

Executes Configuration Scripts on servers (which were downloaded from IT-Camp Master site), Opens Azure Cleanup Script using Notepad.exe. Entire environment is built in less than 10 mins script runtime complete configuration is another 10-15 mins for post configuration scripts to run (background).