title: AWS CLI: listener ARN "must be in ARN format" error
body: <p>I'm using a local exec provisioner in terraform to run aws cli commands that get around terraform's lack of support for certain aws features. The command in question is to create a <code>listener-rule</code> for Application Load Balancer. Here's the call in question (numbers fuzzed):</p>
  
  <pre><code>aws elbv2 create-rule 
  --listener-arn arn:aws:elasticloadbalancing:us-west-1:394416156998:listener/app/lb-name/22e3a19c3c684f8b/17032dfaae523461 
  --priority 2 
  --conditions Field=http-request-method,Values='GET' 
  --actions Type=forward,TargetGroupArn=arn:aws:elasticloadbalancing:us-west-1:394416159845:targetgroup/target-group-name/2ff8e99a44a24219
  </code></pre>
  
  <p>This yields the error: </p>
  
  <pre><code>(ValidationError) when calling the CreateRule operation: 'arn:aws:elasticloadbalancing:us-west-1:394416155421:listener/app/alb-name/92e1a32c3c684f2b/64032dfaae753032' must be in ARN format
  </code></pre>
  
  <p>However, if you examine the <a href="https://docs.aws.amazon.com/cli/latest/reference/elbv2/create-rule.html" rel="nofollow noreferrer">example in amazon's own documentation</a>, they use exactly the same ARN format, unless I'm missing the obvious.</p>
  
  <p>Here's my terraform code:</p>
  
  <pre><code>resource "null_resource" "rule-maker" {
    provisioner "local-exec" {
      command = "aws elbv2 create-rule --listener-arn ${data.aws_arn.listener-arn.arn} --priority 2 --conditions Field=http-request-method,Values='GET' --actions Type=forward,TargetGroupArn=${aws_alb_target_group.name.arn}"
    }
  }
  </code></pre>