I am trying to launch spot instances from Spot Fleet:
aws ec2 request-spot-fleet --spot-fleet-request-config file://aws-spot6.json
below is json content
{
"SpotPrice": "0.06",
"TargetCapacity": 1,
"IamFleetRole": "arn:aws:iam::614786711942:role/aws-ec2-spot-fleet-tagging-role",
"LaunchSpecifications": [
{
"ImageId": "ami-0b86323be1672551f",
"KeyName": "amitpoc",
"SecurityGroups": [
{
"GroupId": "sg-0069a6368b0260ca9"
}
],
"InstanceType": "t2.large",
"SubnetId": "subnet-03c112988598e6e7c",
"TagSpecifications": [
{
"ResourceType": "instance",
"Tags": [
{
"Key": "Type",
"Value": "poc"
}
]
}
]
}
],
"Type": "maintain"
}
This is happening properly.
Now I want to find all the spot instances which were launched, with their private & public IP in a file. This needs to happen in Windows through PowerShell.