Edit my Bash scrip to execute AWS CLI aws ec2 modify-instance-attribute --instance-id o In parallel

Job ID: 32177998

Budget: $50 – $51 USD

i have around 5000 EC2 instance running in AWS and i want to resize all instances for cost optimization. i have already wrote a bash script that read instance ID and Future size from a CVS file and run some AWS CLI command.

due to my huge instance number, i want to edit my script to run the codes in parallel against the 5000 EC2 instance and save time.

i have attached my script as a .sh file
Related categories: Linux Amazon Web Services Bash Scripting Bash