We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b2f7152 commit bb46665Copy full SHA for bb46665
packer/windows/conf/bin/bk-install-elastic-stack.ps1
@@ -9,8 +9,10 @@ function on_error {
9
$errorLine=$_.InvocationInfo.ScriptLineNumber
10
$errorMessage=$_.Exception
11
12
+ $instance_id=(Invoke-WebRequest -UseBasicParsing http://169.254.169.254/latest/meta-data/instance-id).content
13
+
14
aws autoscaling set-instance-health `
- --instance-id "(Invoke-WebRequest -UseBasicParsing http://169.254.169.254/latest/meta-data/instance-id).content" `
15
+ --instance-id "$instance_id" `
16
--health-status Unhealthy
17
18
cfn-signal `
0 commit comments