Question: When does pulumi add tags and default ta...
# aws
o
Question: When does pulumi add tags and default tags to the api requests? On resource creation / modification or only in a seperate putTags operation?
m
I don't believe it is specified or consistent for all resource types. For many resources I suspect tags are sent as part of the initial resource creation API, but others may need multiple requests to set the tags. For example in the bridged AWS provider, s3 buckets set their tags using a separate request during the s3 bucket creation.
o
That would be sad, that way I can not restrict operations to those with the correct tags
Copy code
{
  "Statement": [
    {
      "Action": [
        "s3:*",
        "lambda:*",
        "cloudfront:*",
        "cloudfront-keyvaluestore:*"
      ],
      "Condition": {
        "StringEquals": {
          "aws:RequestTag/customer": "Arsventa GmbH",
          "aws:RequestTag/environment": [
            "live",
            "stage"
          ],
          "aws:RequestTag/product": "MetropolGuru",
          "aws:RequestTag/project": "metropol-guru"
        }
      },
      "Effect": "Allow",
      "Resource": "*"
    }
  ],
  "Version": "2012-10-17"
}