A bash script to submit an AWS EMR job and poll until the cluster terminates
you can use emr wait instead of describe-cluster

aws emr wait cluster-running --cluster-id &lt;value&gt; --region &lt;value&gt;


http://docs.aws.amazon.com/cli/latest/reference/emr/wait/cluster-running.html