UPD: revamped code again
This commit is contained in:
parent
b47c62f944
commit
00260939fa
|
@ -22,7 +22,7 @@ def stop_instances(instances: list[str]) -> dict:
|
|||
def instance_status(instances: list[str]) -> str:
|
||||
time.sleep(10)
|
||||
ec2 = boto3.client('ec2', region_name=os.environ['AWS_REGION'])
|
||||
ec2Array = []
|
||||
ec2Array: list[dict] = []
|
||||
response = ec2.describe_instances(InstanceIds=instances)
|
||||
for r in response['Reservations']:
|
||||
for i in r['Instances']:
|
||||
|
|
Loading…
Reference in New Issue