Created
December 22, 2017 15:04
-
-
Save kort3x/4a68d125b6ce209d3097b05c8594b6ad to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
New-UDRow { | |
New-UDColumn -Size 6 -Content { | |
$Repo = @( | |
@{Space = "free"; Count = (Invoke-RestMethod -headers @{Authorization = "Bearer <token> "} -method GET -uri "https://172.16.221.200:1281/v2/backupRepositories/2").freeSpace} | |
@{Space = "used"; Count = (Invoke-RestMethod -headers @{Authorization = "Bearer <token> "} -method GET -uri "https://172.16.221.200:1281/v2/backupRepositories/2").usedSpace} # dont know if this a valid request | |
) | |
New-UDChart -Title "SBKP1-VEEAM1 Repo Space" -Type Doughnut -Endpoint { | |
$Repo | New-UDChartDataset -DataProperty Count -Label "GB" -BackgroundColor "#42f44e" -HoverBackgroundColor "#42f44e" | |
} -Options @{cutoutPercentage = 0} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment