File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -82,6 +82,7 @@ $script:sysprep_tag = 'C:\Windows\System32\Sysprep\Sysprep_succeeded.tag'
8282$script :setupscripts_dir_loc = " $env: WinDir \Setup\Scripts"
8383$script :setupcomplete_loc = " $script :setupscripts_dir_loc \SetupComplete.cmd"
8484$script :sysprep_output_file_loc = " C:\Windows\System32\Sysprep\Panther\setupact.log"
85+ $script :ggactl = " $gce_install_dir \agent\ggactl_plugin.exe"
8586
8687# Check if the help parameter was called.
8788if ($help ) {
@@ -233,7 +234,13 @@ try {
233234 }
234235
235236 Write-Log ' Stopping GCEAgent.'
236- Stop-Service - name GCEAgent
237+ Stop-Service - name GCEAgent - ErrorAction SilentlyContinue
238+ Write-Log ' Stopping GCEAgentManager.'
239+ Stop-Service - name GCEAgentManager - ErrorAction SilentlyContinue
240+ if (Test-Path $script :ggactl ) {
241+ Write-Log ' Stopping Guest Agent CorePlugin.'
242+ & $script :ggactl coreplugin stop
243+ }
237244
238245 Write-Log ' Setting startup commands.'
239246 Set-ItemProperty - Path HKLM:\SYSTEM\Setup - Name CmdLine - Value " `" $PSScriptRoot \windeploy.cmd`" "
You can’t perform that action at this time.
0 commit comments