Last active
August 17, 2021 14:44
-
-
Save Pome-ro/ee9d4509a53167c24fdc79c4f5a0d66d 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
<# | |
The CSV should have a list of serialnumbers | |
#> | |
$CSV = "~\Desktop\devices.csv" | |
$Devices = Import-Csv $CSV | |
$OU = "" | |
foreach ($SerialNumber in $Devices) { | |
Write-Host "Modifying " $Item "to $OU" -ForegroundColor Green | |
$Query = "query:id:" + $SerialNumber | |
## Update Device OU | |
#C:\gam\gam.exe update cros $Query ou $OU | |
## Disable Device | |
#C:\gam\gam.exe gam update cros $Query action disable | |
## Deprovision Device | |
#C:\gam\gam.exe gam update cros $Query action deprovision_retiring_device acknowledge_device_touch_requirement | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment