VMware VCENTER CONFIGURATION MANAGER 5.3 - SOFTWARE CONTENT REPOSITORY TOOL GUIDE Guia do Utilizador Página 229

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 254
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 228
Scripting | 229
PreExportScript.ps1
The PreExportScript is executed on the Core side prior to any export job.
Sample PreExportScript
# receiving parameter from export job
param([object]$ExportJobRequest)
# building path to Core's Common.Contracts.dll and loading this assembly
$regLM = [Microsoft.Win32.Registry]::LocalMachine
$regLM =
$regLM.OpenSubKey('SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Ap
pRecovery Core 5')
$regVal = $regLM.GetValue('InstallLocation')
$regVal = $regVal + 'CoreService\Common.Contracts.dll'
[System.Reflection.Assembly]::LoadFrom($regVal) | out-null
# Converting input parameter into specific object
$ExportJobRequestObject = $ExportJobRequest -as
[Replay.Core.Contracts.Export.ExportJobRequest]
# Working with input object. All echo's are logged
if($ExportJobRequestObject -eq $null) {
echo 'ExportJobRequestObject parameter is null'
}
else {
echo 'Location:' $ExportJobRequestObject.Location
echo 'Priority:' $ExportJobRequestObject.StorageConfiguration
}
Vista de página 228
1 2 ... 224 225 226 227 228 229 230 231 232 233 234 ... 253 254

Comentários a estes Manuais

Sem comentários