
Tableau Broke Latest CentOS AMI - verdverm
TL;DR Tableau created an AMI which conflicts with the method for obtaining the latest CentOS 7 AMI with Terraform. So much broken...<p>--- me ---<p>We have some terraform that creates EC2 from CentOS, and has been working for months. In the last 24 hours this has broken.<p>```
Error launching source instance: OptInRequired: In order to use this AWS Marketplace product you need to accept terms and subscribe. To do so please visit https:&#x2F;&#x2F;aws.amazon.com&#x2F;marketplace&#x2F;pp?sku=f7hh9b6i4gjxl02w2umkoyu5
        status code: 401, request id: 6626612d-a97b-483a-8ccb-9bf9cfbb41e8
```<p>What I have found is that the Centos AMI and Tableau from the marketplace have the same product code &#x2F; id.<p>CentOS AMI: ami-089ccd342f0be98ab<p>So what we are seeing is that when Terraform uses this AMI, we get the 401 above.<p>Please help<p>--- aws ---<p>After further internal research, I have found that the Tableau recently created a listing with very similar name as the CentOS AMI.<p>ami-02eac2c0129f6376b &lt;----This is from CentOS
CentOS Linux 7 x86_64 HVM EBS ENA 1901_01-b7ee8a69-ee97-4a49-9e68-afaee216db2e-ami-05713873c6794f575.4<p>ami-089ccd342f0be98ab &lt;----This is from Tableau
CentOS Linux 7 x86_64 HVM EBS ENA 1901_01-0722b432-8459-49b6-9b90-79b42624d25d-ami-05713873c6794f575.4<p>Would you please let me know if your terraform is configured to use AMI ID or AMI name?<p>--- me ---<p>We use the AMI &quot;name&quot; to get the latest version of the image. How is it that Tableau can create an image with the same name?<p>```<p>data &quot;aws_ami&quot; &quot;centos&quot; {
  owners      = [&quot;679593333241&quot;]
  most_recent = true<p><pre><code>  filter {
    name   = &quot;name&quot;
    values = [&quot;CentOS Linux 7 x86_64 HVM EBS *&quot;]
  }

  filter {
    name   = &quot;architecture&quot;
    values = [&quot;x86_64&quot;]
  }

  filter {
    name   = &quot;root-device-type&quot;
    values = [&quot;ebs&quot;]
  }</code></pre>
}<p>```
======
alvaroaleman
Add a filter for `product-code: ["aw0evgkw8e5c1q413zgy5pjce"]`

Ref: [https://wiki.centos.org/Cloud/AWS](https://wiki.centos.org/Cloud/AWS)

~~~
verdverm
Thanks, AWS said there is no resolution on their end. They mentioned the
product code too.

What you posted is TF though, yes?

