Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "chore(deps): bump cloudposse/waf/aws from 0.3.0 to 0.4.0 in /terraform/modules/gost_website" #1634

Conversation

TylerHendrickson
Copy link
Member

Reverts #1613

See this comment on the above issue, and this bug report filed in the source repository for cloudposse/waf/aws.

@TylerHendrickson TylerHendrickson added bug Something isn't working dependencies Pull requests that update a dependency file Infra Issues related to the infrastructure underlying all the tools. terraform Pull requests that update Terraform code labels Jul 12, 2023
@TylerHendrickson TylerHendrickson requested a review from a team as a code owner July 12, 2023 17:24
@TylerHendrickson TylerHendrickson self-assigned this Jul 12, 2023
@TylerHendrickson TylerHendrickson temporarily deployed to staging July 12, 2023 17:25 — with GitHub Actions Inactive
@github-actions
Copy link

Report for project: terraform

Terraform Initialization ⚙️success

Terraform Validation 🤖success

Validation Output

Success! The configuration is valid.


Terraform Plan 📖success

Show Plan
Note: Objects have changed outside of Terraform

Terraform detected the following changes made outside of Terraform since the
last "terraform apply" which may have affected this plan:

  # module.api.aws_ecs_task_definition.default[0] has changed
  ~ resource "aws_ecs_task_definition" "default" {
        id                       = "gost-staging-api"
+       tags                     = {}
        # (13 unchanged attributes hidden)

+       volume {
+           name = "data"

+           efs_volume_configuration {
+               file_system_id          = "fs-08f95063c1cdbe191"
+               root_directory          = "/"
+               transit_encryption      = "ENABLED"
+               transit_encryption_port = 0

+               authorization_config {
+                   access_point_id = "fsap-03bc0296928aade4f"
                }
            }
        }
-       volume {
-           name = "data" -> null

-           efs_volume_configuration {
-               file_system_id     = "fs-08f95063c1cdbe191" -> null
-               root_directory     = "/" -> null
-               transit_encryption = "ENABLED" -> null

-               authorization_config {
-                   access_point_id = "fsap-03bc0296928aade4f" -> null
                }
            }
        }

        # (1 unchanged block hidden)
    }

  # module.api.aws_iam_role.execution[0] has changed
  ~ resource "aws_iam_role" "execution" {
        id                    = "gost-staging-api-ECSTaskExecution-20230217010414321500000009"
        name                  = "gost-staging-api-ECSTaskExecution-20230217010414321500000009"
      ~ role_last_used        = [
          ~ {
              ~ last_used_date = "2023-06-27T13:19:51Z" -> "2023-07-12T06:19:17Z"
                # (1 unchanged element hidden)
            },
        ]
        tags                  = {}
        # (11 unchanged attributes hidden)

        # (2 unchanged blocks hidden)
    }

  # module.api.aws_iam_role.task[0] has changed
  ~ resource "aws_iam_role" "task" {
        id                    = "gost-staging-api-ECSTask-2023021701041477300000000a"
        name                  = "gost-staging-api-ECSTask-2023021701041477300000000a"
      ~ role_last_used        = [
          ~ {
              ~ last_used_date = "2023-06-27T12:39:52Z" -> "2023-07-12T15:11:39Z"
                # (1 unchanged element hidden)
            },
        ]
        tags                  = {}
        # (11 unchanged attributes hidden)

        # (4 unchanged blocks hidden)
    }

  # module.api.module.grants_scraper.aws_iam_role.default[0] has changed
  ~ resource "aws_iam_role" "default" {
        id                    = "gost-staging-grants_scraper-2023021701041523320000000b"
        name                  = "gost-staging-grants_scraper-2023021701041523320000000b"
      ~ role_last_used        = [
          ~ {
              ~ last_used_date = "2023-06-27T06:14:24Z" -> "2023-07-12T06:14:24Z"
                # (1 unchanged element hidden)
            },
        ]
        tags                  = {}
        # (12 unchanged attributes hidden)

        # (1 unchanged block hidden)
    }


Unless you have made equivalent changes to your configuration, or ignored the
relevant attributes using ignore_changes, the following plan may include
actions to undo or respond to these changes.

─────────────────────────────────────────────────────────────────────────────

Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
  ~ update in-place
+/- create replacement and then destroy
 <= read (data resources)

Terraform will perform the following actions:

  # module.api.aws_ecs_service.default[0] will be updated in-place
  ~ resource "aws_ecs_service" "default" {
        id                                 = "arn:aws:ecs:us-west-2:357150818708:service/gost-staging/gost-staging-api"
        name                               = "gost-staging-api"
        tags                               = {}
      ~ task_definition                    = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-api:14" -> (known after apply)
        # (15 unchanged attributes hidden)

        # (4 unchanged blocks hidden)
    }

  # module.api.aws_ecs_task_definition.default[0] must be replaced
+/- resource "aws_ecs_task_definition" "default" {
      ~ arn                      = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-api:14" -> (known after apply)
      ~ arn_without_revision     = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-api" -> (known after apply)
      ~ container_definitions    = jsonencode(
          ~ [ # forces replacement
              ~ {
                  ~ dockerLabels           = {
                      ~ "com.datadoghq.tags.version" = "9d430062fcd8202322a1c95dce7a25544d206857" -> "a3d296a7587b578f5a28da5fa6d0a9de22529378"
                        # (2 unchanged elements hidden)
                    }
                  ~ environment            = [
                        # (4 unchanged elements hidden)
                        {
                            name  = "DD_SERVICE"
                            value = "gost"
                        },
                      ~ {
                            name  = "DD_VERSION"
                          ~ value = "9d430062fcd8202322a1c95dce7a25544d206857" -> "a3d296a7587b578f5a28da5fa6d0a9de22529378"
                        },
                        {
                            name  = "ENABLE_GRANTS_DIGEST"
                            value = "false"
                        },
                        # (8 unchanged elements hidden)
                    ]
                    name                   = "api"
-                   volumesFrom            = [] -> null
                    # (9 unchanged elements hidden)
                } # forces replacement,
              ~ {
                  ~ dockerLabels           = {
                      ~ "com.datadoghq.tags.version" = "9d430062fcd8202322a1c95dce7a25544d206857" -> "a3d296a7587b578f5a28da5fa6d0a9de22529378"
                        # (2 unchanged elements hidden)
                    }
                  ~ environment            = [
                        # (2 unchanged elements hidden)
                        {
                            name  = "DD_SERVICE"
                            value = "gost"
                        },
                      ~ {
                            name  = "DD_VERSION"
                          ~ value = "9d430062fcd8202322a1c95dce7a25544d206857" -> "a3d296a7587b578f5a28da5fa6d0a9de22529378"
                        },
                        {
                            name  = "ECS_FARGATE"
                            value = "true"
                        },
                    ]
-                   mountPoints            = [] -> null
                    name                   = "datadog"
-                   portMappings           = [] -> null
-                   volumesFrom            = [] -> null
                    # (6 unchanged elements hidden)
                } # forces replacement,
            ]
        )
      ~ id                       = "gost-staging-api" -> (known after apply)
      ~ revision                 = 14 -> (known after apply)
-       tags                     = {} -> null
        # (9 unchanged attributes hidden)

-       volume {
-           name = "data" -> null

-           efs_volume_configuration {
-               file_system_id          = "fs-08f95063c1cdbe191" -> null
-               root_directory          = "/" -> null
-               transit_encryption      = "ENABLED" -> null
-               transit_encryption_port = 0 -> null

-               authorization_config {
-                   access_point_id = "fsap-03bc0296928aade4f" -> null
                }
            }
        }
+       volume {
+           name = "data"

+           efs_volume_configuration {
+               file_system_id     = "fs-08f95063c1cdbe191"
+               root_directory     = "/"
+               transit_encryption = "ENABLED"

+               authorization_config {
+                   access_point_id = "fsap-03bc0296928aade4f"
                }
            }
        }

        # (1 unchanged block hidden)
    }

  # module.api.module.grants_scraper.data.aws_iam_policy_document.permissions[0] will be read during apply
  # (config refers to values not yet known)
 <= data "aws_iam_policy_document" "permissions" {
+       id   = (known after apply)
+       json = (known after apply)

+       statement {
+           actions   = [
+               "ecs:RunTask",
            ]
+           effect    = "Allow"
+           resources = [
+               (known after apply),
            ]
+           sid       = "AllowRunTask"

+           condition {
+               test     = "ArnLike"
+               values   = [
+                   "arn:aws:ecs:us-west-2:357150818708:cluster/gost-staging",
                ]
+               variable = "ecs:cluster"
            }
        }
+       statement {
+           actions   = [
+               "iam:PassRole",
            ]
+           effect    = "Allow"
+           resources = [
+               "arn:aws:iam::357150818708:role/gost-staging-api-ECSTask-2023021701041477300000000a",
+               "arn:aws:iam::357150818708:role/gost-staging-api-ECSTaskExecution-20230217010414321500000009",
            ]
+           sid       = "AllowSchedulerPassRoleToExecutionRole"
        }
    }

  # module.api.module.grants_scraper.aws_iam_role_policy.default[0] will be updated in-place
  ~ resource "aws_iam_role_policy" "default" {
        id     = "gost-staging-grants_scraper-2023021701041523320000000b:terraform-20230217010528091000000012"
        name   = "terraform-20230217010528091000000012"
      ~ policy = jsonencode(
            {
-               Statement = [
-                   {
-                       Action    = "ecs:RunTask"
-                       Condition = {
-                           ArnLike = {
-                               "ecs:cluster" = "arn:aws:ecs:us-west-2:357150818708:cluster/gost-staging"
                            }
                        }
-                       Effect    = "Allow"
-                       Resource  = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-api:*"
-                       Sid       = "AllowRunTask"
                    },
-                   {
-                       Action   = "iam:PassRole"
-                       Effect   = "Allow"
-                       Resource = [
-                           "arn:aws:iam::357150818708:role/gost-staging-api-ECSTaskExecution-20230217010414321500000009",
-                           "arn:aws:iam::357150818708:role/gost-staging-api-ECSTask-2023021701041477300000000a",
                        ]
-                       Sid      = "AllowSchedulerPassRoleToExecutionRole"
                    },
                ]
-               Version   = "2012-10-17"
            }
        ) -> (known after apply)
        # (1 unchanged attribute hidden)
    }

  # module.api.module.grants_scraper.aws_scheduler_schedule.default[0] will be updated in-place
  ~ resource "aws_scheduler_schedule" "default" {
        id                           = "default/gost-staging-grants_scraper-20230217010528095600000013"
        name                         = "gost-staging-grants_scraper-20230217010528095600000013"
        # (10 unchanged attributes hidden)

      ~ target {
            # (3 unchanged attributes hidden)

          ~ ecs_parameters {
                tags                    = {}
              ~ task_definition_arn     = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-api:14" -> (known after apply)
                # (8 unchanged attributes hidden)

                # (1 unchanged block hidden)
            }

            # (1 unchanged block hidden)
        }

        # (1 unchanged block hidden)
    }

Plan: 1 to add, 3 to change, 1 to destroy.

Pusher: @TylerHendrickson, Action: pull_request, Workflow: Terraform CI

@TylerHendrickson TylerHendrickson enabled auto-merge (squash) July 12, 2023 17:27
@codeclimate
Copy link

codeclimate bot commented Jul 12, 2023

Code Climate has analyzed commit f3c3d02 and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 54.0%.

View more on Code Climate.

@TylerHendrickson TylerHendrickson requested a review from as1729 July 12, 2023 17:28
@TylerHendrickson TylerHendrickson mentioned this pull request Jul 12, 2023
7 tasks
@TylerHendrickson TylerHendrickson merged commit 3961a20 into _staging Jul 12, 2023
@TylerHendrickson TylerHendrickson deleted the revert-1613-dependabot/terraform/terraform/modules/gost_website/cloudposse/waf/aws-0.4.0 branch July 12, 2023 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working dependencies Pull requests that update a dependency file Infra Issues related to the infrastructure underlying all the tools. terraform Pull requests that update Terraform code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants