Skip to content

Instantly share code, notes, and snippets.

View aggiebck's full-sized avatar

Caleb Beckett aggiebck

  • Texas A&M University
  • College Station, TX
View GitHub Profile
New-UDPage -Name "Server VM Disk Monitor" -Content{
New-UDRow {
New-UDColumn -Size 12 -AutoRefresh -RefreshInterval 5 -Endpoint {
New-UDLayout -Columns 3 -Content {
#Add Any VM Folders you don't want to Include in your VM results below.
$ExcludeFolders = @("")
$VMs = Get-Folder -Server $Session:VCSession "VM_Folder" | Get-Folder -NoRecursion | Where-Object {$ExcludeFolders -notcontains $_.Name } | Get-VM | Where-Object {$_.PowerState -eq "PoweredOn" } | Sort
Foreach($VM in $VMs){
$vmInfo = Get-VM -Server $Session:VCSession -Name $vm
$vmView = $vmInfo | Get-View
# CSS Color scheme for Dashboard's
$Colors = @{
BackgroundColor = "#252525"
FontColor = "#FFFFFF"
}
$AlternateColors = @{
BackgroundColor = "#5C5C5C"
FontColor = "#FFFFFF"
}
@aggiebck
aggiebck / Add-Note.ps1
Created June 24, 2019 16:05
SDP - Powershell API Requests Repo
## This Function will add Notes to a Specific Request when passed the WorkOrderID and a String Note.
function Add-SDNote{
# Add CmdletBinding adds common parameters like -verbose and -debug
[CmdletBinding()]
# Define parameters passed with the function call
param(
[Parameter(Mandatory=$True)]
[string]$requestid,