diff --git a/packer/windows/conf/buildkite-agent/scripts/terminate-instance.ps1 b/packer/windows/conf/buildkite-agent/scripts/terminate-instance.ps1 index 3c72add38..10c9dc2f7 100755 --- a/packer/windows/conf/buildkite-agent/scripts/terminate-instance.ps1 +++ b/packer/windows/conf/buildkite-agent/scripts/terminate-instance.ps1 @@ -22,8 +22,7 @@ if ($lastexitcode -eq 0) { aws autoscaling set-instance-health ` --instance-id "$InstanceId" ` --region "$Region" ` - --health-status Unhealthy ` - --no-should-respect-grace-period + --health-status Unhealthy } else { Write-Output "terminate-instance: restarting agent..." nssm start buildkite-agent