Skip to content

aws import: an unquoted Version: 2012-10-17 becomes {} #5076

Closed

Description

@lex00

Found with chant 0.124.95 while reading a clone of kubernetes/k8s.io at commit 2b3d9153 offline, for #5067.

chant import of a CloudFormation template turns an unquoted Version: 2012-10-17 in a policy document into an empty object. The build then writes "Version": {}.

Files: infra/aws/cloudformation/iam/cdn.packages.k8s.io/cloudformation.yaml lines 73, 97, 121, 178, 223, and infra/aws/cloudformation/iam/eks-e2e-boskos/eks-e2e-boskos-001/eks-e2e-boskos-001.yaml line 25. Six IAM policy documents in two templates. The quoted form '2012-10-17' imports correctly.

Likely cause: the YAML parser reads the bare value as a date, and the generator writes a Date as {}. I verified the symptom and inferred the cause.

An IAM policy with "Version": {} is rejected by CloudFormation, so the imported template no longer deploys.

Wanted: bare dates in a CloudFormation template import as the string they were written as, the way CloudFormation reads them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:awsbugepic:estate-read

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions