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

remove resources #1

Merged
merged 1 commit into from
Jul 21, 2023
Merged

remove resources #1

merged 1 commit into from
Jul 21, 2023

Conversation

Chriscbr
Copy link
Contributor

No description provided.

@github-actions
Copy link

Terraform Plan

Show Plan
aws_api_gateway_stage.cloudApi_api_stage_BBB283E4: Refreshing state... [id=ags-q1n5thtrf1-prod]
aws_lambda_permission.cloudApi_api_permission-GET-60cabf0c_3E7E8C53: Refreshing state... [id=AllowExecutionFromAPIGateway-GET-60cabf0c]
aws_s3_object.testputandgetaniteminthetable_Handler_S3Object_99B690DF: Refreshing state... [id=asset.c8b2075c0e934e8562a3cca6418a82a68ca746a3e2.5cd5d161ab6b75ff8f847fe7657b7ab4.zip]
aws_iam_role_policy.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicy_05D8CBC6: Refreshing state... [id=terraform-20230713231627411800000003:terraform-2023071323163389640000000d]
aws_iam_role.testscanitemsinthetable_Handler_IamRole_23FE1123: Refreshing state... [id=terraform-20230713231627409900000002]
aws_lambda_function.cloudApi_cloudApi-OnRequest-41f14472_B4385311: Refreshing state... [id=cloud-Api-OnRequest-41f14472-c81170c6]
aws_lambda_function.testputandgetaniteminthetable_Handler_8825EF34: Refreshing state... [id=Handler-c8b2075c]
aws_iam_role_policy.testputandgetaniteminthetable_Handler_IamRolePolicy_456ED6F1: Refreshing state... [id=terraform-20230713231627409000000001:terraform-2023071323163388130000000b]
aws_iam_role_policy_attachment.testputandgetaniteminthetable_Handler_IamRolePolicyAttachment_0EF121C6: Refreshing state... [id=terraform-20230713231627409000000001-20230713231627731000000008]
aws_api_gateway_rest_api.cloudApi_api_2B334D75: Refreshing state... [id=q1n5thtrf1]
aws_iam_role_policy_attachment.cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicyAttachment_73CC9260: Refreshing state... [id=terraform-20230713231627414600000005-20230713231627728200000007]
aws_lambda_function.testscanitemsinthetable_Handler_603CBAFD: Refreshing state... [id=Handler-c8c4065c]
aws_iam_role.cloudApi_cloudApi-OnRequest-41f14472_IamRole_60C118A3: Refreshing state... [id=terraform-20230713231627414600000005]
aws_iam_role_policy_attachment.testscanitemsinthetable_Handler_IamRolePolicyAttachment_F7F266A5: Refreshing state... [id=terraform-20230713231627409900000002-20230713231627718900000006]
aws_iam_role_policy.testscanitemsinthetable_Handler_IamRolePolicy_D7855AC0: Refreshing state... [id=terraform-20230713231627409900000002:terraform-2023071323163389530000000c]
aws_lambda_permission.cloudApi_api_permission-POST-cb38ebcb_8FB5CBF5: Refreshing state... [id=AllowExecutionFromAPIGateway-POST-cb38ebcb]
aws_lambda_function.cloudApi_cloudApi-OnRequest-8d2e75ec_6AC8279C: Refreshing state... [id=cloud-Api-OnRequest-8d2e75ec-c88d95b6]
aws_s3_object.testscanitemsinthetable_Handler_S3Object_101BF1FD: Refreshing state... [id=asset.c8c4065c0f44ecbaea60f96af9085e0e9e53ef183a.3a9c55b9613434b93430b6dd14c35891.zip]
aws_s3_object.cloudApi_cloudApi-OnRequest-41f14472_S3Object_2D3CDD60: Refreshing state... [id=asset.c81170c6eea85213cd98217b95378895ec0689d1c6.4762c7248564c35e1d71bf2a502552c2.zip]
aws_s3_bucket.Code: Refreshing state... [id=code-c84a50b1-20230713231627414400000004]
aws_iam_role.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRole_88F60E9F: Refreshing state... [id=terraform-20230713231627411800000003]
aws_iam_role.testputandgetaniteminthetable_Handler_IamRole_B80DF992: Refreshing state... [id=terraform-20230713231627409000000001]
aws_api_gateway_deployment.cloudApi_api_deployment_545514BF: Refreshing state... [id=szj47i]
aws_dynamodb_table.DynamoDBTable_tfawsdynamodbTableDynamodbTable_50EA3DF8: Refreshing state... [id=Table-785679de]
aws_iam_role_policy.cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicy_2728B668: Refreshing state... [id=terraform-20230713231627414600000005:terraform-2023071323163387720000000a]
aws_iam_role_policy_attachment.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicyAttachment_00E26B16: Refreshing state... [id=terraform-20230713231627411800000003-20230713231627734200000009]
aws_s3_object.cloudApi_cloudApi-OnRequest-8d2e75ec_S3Object_431AEB37: Refreshing state... [id=asset.c88d95b6bc18cd30c63db5b8cb1a92698c78a2d31c.8166d73cc8c8bec3ac71f0ac3cfe49fe.zip]

Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
  - destroy

Terraform will perform the following actions:

  # aws_api_gateway_deployment.cloudApi_api_deployment_545514BF will be destroyed
  # (because aws_api_gateway_deployment.cloudApi_api_deployment_545514BF is not in configuration)
  - resource "aws_api_gateway_deployment" "cloudApi_api_deployment_545514BF" {
      - created_date  = "2023-07-13T23:16:44Z" -> null
      - execution_arn = "arn:aws:execute-api:us-east-1:223316951128:q1n5thtrf1/" -> null
      - id            = "szj47i" -> null
      - invoke_url    = "https://q1n5thtrf1.execute-api.us-east-1.amazonaws.com/" -> null
      - rest_api_id   = "q1n5thtrf1" -> null
      - triggers      = {
          - "redeployment" = "de968ced67eaf18d2eb02189a3eb6afc36d2a4fe"
        } -> null
    }

  # aws_api_gateway_rest_api.cloudApi_api_2B334D75 will be destroyed
  # (because aws_api_gateway_rest_api.cloudApi_api_2B334D75 is not in configuration)
  - resource "aws_api_gateway_rest_api" "cloudApi_api_2B334D75" {
      - api_key_source               = "HEADER" -> null
      - arn                          = "arn:aws:apigateway:us-east-1::/restapis/q1n5thtrf1" -> null
      - binary_media_types           = [] -> null
      - body                         = jsonencode(
            {
              - openapi = "3.0.3"
              - paths   = {
                  - "/items" = {
                      - get = {
                          - operationId                     = "get-items"
                          - parameters                      = []
                          - responses                       = {
                              - "200" = {
                                  - content     = {}
                                  - description = "200 response"
                                }
                            }
                          - x-amazon-apigateway-integration = {
                              - contentHandling     = "CONVERT_TO_TEXT"
                              - httpMethod          = "POST"
                              - passthroughBehavior = "when_no_match"
                              - responses           = {
                                  - default = {
                                      - statusCode = "200"
                                    }
                                }
                              - type                = "aws_proxy"
                              - uri                 = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-8d2e75ec-c88d95b6/invocations"
                            }
                        }
                    }
                  - "/vote"  = {
                      - post = {
                          - operationId                     = "post-vote"
                          - parameters                      = []
                          - responses                       = {
                              - "200" = {
                                  - content     = {}
                                  - description = "200 response"
                                }
                            }
                          - x-amazon-apigateway-integration = {
                              - contentHandling     = "CONVERT_TO_TEXT"
                              - httpMethod          = "POST"
                              - passthroughBehavior = "when_no_match"
                              - responses           = {
                                  - default = {
                                      - statusCode = "200"
                                    }
                                }
                              - type                = "aws_proxy"
                              - uri                 = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-41f14472-c81170c6/invocations"
                            }
                        }
                    }
                }
            }
        ) -> null
      - created_date                 = "2023-07-13T23:16:44Z" -> null
      - disable_execute_api_endpoint = false -> null
      - execution_arn                = "arn:aws:execute-api:us-east-1:223316951128:q1n5thtrf1" -> null
      - id                           = "q1n5thtrf1" -> null
      - minimum_compression_size     = -1 -> null
      - name                         = "api-c895068c" -> null
      - root_resource_id             = "yf9ij406y6" -> null
      - tags                         = {} -> null
      - tags_all                     = {} -> null

      - endpoint_configuration {
          - types            = [
              - "EDGE",
            ] -> null
          - vpc_endpoint_ids = [] -> null
        }
    }

  # aws_api_gateway_stage.cloudApi_api_stage_BBB283E4 will be destroyed
  # (because aws_api_gateway_stage.cloudApi_api_stage_BBB283E4 is not in configuration)
  - resource "aws_api_gateway_stage" "cloudApi_api_stage_BBB283E4" {
      - arn                   = "arn:aws:apigateway:us-east-1::/restapis/q1n5thtrf1/stages/prod" -> null
      - cache_cluster_enabled = false -> null
      - deployment_id         = "szj47i" -> null
      - execution_arn         = "arn:aws:execute-api:us-east-1:223316951128:q1n5thtrf1/prod" -> null
      - id                    = "ags-q1n5thtrf1-prod" -> null
      - invoke_url            = "https://q1n5thtrf1.execute-api.us-east-1.amazonaws.com/prod" -> null
      - rest_api_id           = "q1n5thtrf1" -> null
      - stage_name            = "prod" -> null
      - tags                  = {} -> null
      - tags_all              = {} -> null
      - variables             = {} -> null
      - xray_tracing_enabled  = false -> null
    }

  # aws_dynamodb_table.DynamoDBTable_tfawsdynamodbTableDynamodbTable_50EA3DF8 will be destroyed
  # (because aws_dynamodb_table.DynamoDBTable_tfawsdynamodbTableDynamodbTable_50EA3DF8 is not in configuration)
  - resource "aws_dynamodb_table" "DynamoDBTable_tfawsdynamodbTableDynamodbTable_50EA3DF8" {
      - arn                         = "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de" -> null
      - billing_mode                = "PAY_PER_REQUEST" -> null
      - deletion_protection_enabled = false -> null
      - hash_key                    = "Name" -> null
      - id                          = "Table-785679de" -> null
      - name                        = "Table-785679de" -> null
      - read_capacity               = 0 -> null
      - stream_enabled              = false -> null
      - table_class                 = "STANDARD" -> null
      - tags                        = {} -> null
      - tags_all                    = {} -> null
      - write_capacity              = 0 -> null

      - attribute {
          - name = "Name" -> null
          - type = "S" -> null
        }

      - point_in_time_recovery {
          - enabled = false -> null
        }

      - ttl {
          - enabled = false -> null
        }
    }

  # aws_iam_role.cloudApi_cloudApi-OnRequest-41f14472_IamRole_60C118A3 will be destroyed
  # (because aws_iam_role.cloudApi_cloudApi-OnRequest-41f14472_IamRole_60C118A3 is not in configuration)
  - resource "aws_iam_role" "cloudApi_cloudApi-OnRequest-41f14472_IamRole_60C118A3" {
      - arn                   = "arn:aws:iam::223316951128:role/terraform-20230713231627414600000005" -> null
      - assume_role_policy    = jsonencode(
            {
              - Statement = [
                  - {
                      - Action    = "sts:AssumeRole"
                      - Effect    = "Allow"
                      - Principal = {
                          - Service = "lambda.amazonaws.com"
                        }
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - create_date           = "2023-07-13T23:16:27Z" -> null
      - force_detach_policies = false -> null
      - id                    = "terraform-20230713231627414600000005" -> null
      - managed_policy_arns   = [
          - "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole",
        ] -> null
      - max_session_duration  = 3600 -> null
      - name                  = "terraform-20230713231627414600000005" -> null
      - name_prefix           = "terraform-" -> null
      - path                  = "/" -> null
      - role_last_used        = [
          - {
              - last_used_date = ""
              - region         = ""
            },
        ] -> null
      - tags                  = {} -> null
      - tags_all              = {} -> null
      - unique_id             = "AROATH7V2IBMBBM4GMKY6" -> null

      - inline_policy {
          - name   = "terraform-2023071323163387720000000a" -> null
          - policy = jsonencode(
                {
                  - Statement = [
                      - {
                          - Action   = [
                              - "dynamodb:PutItem",
                            ]
                          - Effect   = "Allow"
                          - Resource = [
                              - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                            ]
                        },
                    ]
                  - Version   = "2012-10-17"
                }
            ) -> null
        }
    }

  # aws_iam_role.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRole_88F60E9F will be destroyed
  # (because aws_iam_role.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRole_88F60E9F is not in configuration)
  - resource "aws_iam_role" "cloudApi_cloudApi-OnRequest-8d2e75ec_IamRole_88F60E9F" {
      - arn                   = "arn:aws:iam::223316951128:role/terraform-20230713231627411800000003" -> null
      - assume_role_policy    = jsonencode(
            {
              - Statement = [
                  - {
                      - Action    = "sts:AssumeRole"
                      - Effect    = "Allow"
                      - Principal = {
                          - Service = "lambda.amazonaws.com"
                        }
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - create_date           = "2023-07-13T23:16:27Z" -> null
      - force_detach_policies = false -> null
      - id                    = "terraform-20230713231627411800000003" -> null
      - managed_policy_arns   = [
          - "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole",
        ] -> null
      - max_session_duration  = 3600 -> null
      - name                  = "terraform-20230713231627411800000003" -> null
      - name_prefix           = "terraform-" -> null
      - path                  = "/" -> null
      - role_last_used        = [
          - {
              - last_used_date = ""
              - region         = ""
            },
        ] -> null
      - tags                  = {} -> null
      - tags_all              = {} -> null
      - unique_id             = "AROATH7V2IBMBSIEMY6HK" -> null

      - inline_policy {
          - name   = "terraform-2023071323163389640000000d" -> null
          - policy = jsonencode(
                {
                  - Statement = [
                      - {
                          - Action   = [
                              - "dynamodb:Scan",
                            ]
                          - Effect   = "Allow"
                          - Resource = [
                              - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                            ]
                        },
                    ]
                  - Version   = "2012-10-17"
                }
            ) -> null
        }
    }

  # aws_iam_role.testputandgetaniteminthetable_Handler_IamRole_B80DF992 will be destroyed
  # (because aws_iam_role.testputandgetaniteminthetable_Handler_IamRole_B80DF992 is not in configuration)
  - resource "aws_iam_role" "testputandgetaniteminthetable_Handler_IamRole_B80DF992" {
      - arn                   = "arn:aws:iam::223316951128:role/terraform-20230713231627409000000001" -> null
      - assume_role_policy    = jsonencode(
            {
              - Statement = [
                  - {
                      - Action    = "sts:AssumeRole"
                      - Effect    = "Allow"
                      - Principal = {
                          - Service = "lambda.amazonaws.com"
                        }
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - create_date           = "2023-07-13T23:16:27Z" -> null
      - force_detach_policies = false -> null
      - id                    = "terraform-20230713231627409000000001" -> null
      - managed_policy_arns   = [
          - "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole",
        ] -> null
      - max_session_duration  = 3600 -> null
      - name                  = "terraform-20230713231627409000000001" -> null
      - name_prefix           = "terraform-" -> null
      - path                  = "/" -> null
      - role_last_used        = [
          - {
              - last_used_date = ""
              - region         = ""
            },
        ] -> null
      - tags                  = {} -> null
      - tags_all              = {} -> null
      - unique_id             = "AROATH7V2IBMOPDNO5VPV" -> null

      - inline_policy {
          - name   = "terraform-2023071323163388130000000b" -> null
          - policy = jsonencode(
                {
                  - Statement = [
                      - {
                          - Action   = [
                              - "dynamodb:PutItem",
                            ]
                          - Effect   = "Allow"
                          - Resource = [
                              - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                            ]
                        },
                      - {
                          - Action   = [
                              - "dynamodb:GetItem",
                            ]
                          - Effect   = "Allow"
                          - Resource = [
                              - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                            ]
                        },
                    ]
                  - Version   = "2012-10-17"
                }
            ) -> null
        }
    }

  # aws_iam_role.testscanitemsinthetable_Handler_IamRole_23FE1123 will be destroyed
  # (because aws_iam_role.testscanitemsinthetable_Handler_IamRole_23FE1123 is not in configuration)
  - resource "aws_iam_role" "testscanitemsinthetable_Handler_IamRole_23FE1123" {
      - arn                   = "arn:aws:iam::223316951128:role/terraform-20230713231627409900000002" -> null
      - assume_role_policy    = jsonencode(
            {
              - Statement = [
                  - {
                      - Action    = "sts:AssumeRole"
                      - Effect    = "Allow"
                      - Principal = {
                          - Service = "lambda.amazonaws.com"
                        }
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - create_date           = "2023-07-13T23:16:27Z" -> null
      - force_detach_policies = false -> null
      - id                    = "terraform-20230713231627409900000002" -> null
      - managed_policy_arns   = [
          - "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole",
        ] -> null
      - max_session_duration  = 3600 -> null
      - name                  = "terraform-20230713231627409900000002" -> null
      - name_prefix           = "terraform-" -> null
      - path                  = "/" -> null
      - role_last_used        = [
          - {
              - last_used_date = ""
              - region         = ""
            },
        ] -> null
      - tags                  = {} -> null
      - tags_all              = {} -> null
      - unique_id             = "AROATH7V2IBMEIBFUGV4F" -> null

      - inline_policy {
          - name   = "terraform-2023071323163389530000000c" -> null
          - policy = jsonencode(
                {
                  - Statement = [
                      - {
                          - Action   = [
                              - "dynamodb:PutItem",
                            ]
                          - Effect   = "Allow"
                          - Resource = [
                              - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                            ]
                        },
                      - {
                          - Action   = [
                              - "dynamodb:Scan",
                            ]
                          - Effect   = "Allow"
                          - Resource = [
                              - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                            ]
                        },
                    ]
                  - Version   = "2012-10-17"
                }
            ) -> null
        }
    }

  # aws_iam_role_policy.cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicy_2728B668 will be destroyed
  # (because aws_iam_role_policy.cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicy_2728B668 is not in configuration)
  - resource "aws_iam_role_policy" "cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicy_2728B668" {
      - id     = "terraform-20230713231627414600000005:terraform-2023071323163387720000000a" -> null
      - name   = "terraform-2023071323163387720000000a" -> null
      - policy = jsonencode(
            {
              - Statement = [
                  - {
                      - Action   = [
                          - "dynamodb:PutItem",
                        ]
                      - Effect   = "Allow"
                      - Resource = [
                          - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                        ]
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - role   = "terraform-20230713231627414600000005" -> null
    }

  # aws_iam_role_policy.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicy_05D8CBC6 will be destroyed
  # (because aws_iam_role_policy.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicy_05D8CBC6 is not in configuration)
  - resource "aws_iam_role_policy" "cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicy_05D8CBC6" {
      - id     = "terraform-20230713231627411800000003:terraform-2023071323163389640000000d" -> null
      - name   = "terraform-2023071323163389640000000d" -> null
      - policy = jsonencode(
            {
              - Statement = [
                  - {
                      - Action   = [
                          - "dynamodb:Scan",
                        ]
                      - Effect   = "Allow"
                      - Resource = [
                          - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                        ]
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - role   = "terraform-20230713231627411800000003" -> null
    }

  # aws_iam_role_policy.testputandgetaniteminthetable_Handler_IamRolePolicy_456ED6F1 will be destroyed
  # (because aws_iam_role_policy.testputandgetaniteminthetable_Handler_IamRolePolicy_456ED6F1 is not in configuration)
  - resource "aws_iam_role_policy" "testputandgetaniteminthetable_Handler_IamRolePolicy_456ED6F1" {
      - id     = "terraform-20230713231627409000000001:terraform-2023071323163388130000000b" -> null
      - name   = "terraform-2023071323163388130000000b" -> null
      - policy = jsonencode(
            {
              - Statement = [
                  - {
                      - Action   = [
                          - "dynamodb:PutItem",
                        ]
                      - Effect   = "Allow"
                      - Resource = [
                          - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                        ]
                    },
                  - {
                      - Action   = [
                          - "dynamodb:GetItem",
                        ]
                      - Effect   = "Allow"
                      - Resource = [
                          - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                        ]
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - role   = "terraform-20230713231627409000000001" -> null
    }

  # aws_iam_role_policy.testscanitemsinthetable_Handler_IamRolePolicy_D7855AC0 will be destroyed
  # (because aws_iam_role_policy.testscanitemsinthetable_Handler_IamRolePolicy_D7855AC0 is not in configuration)
  - resource "aws_iam_role_policy" "testscanitemsinthetable_Handler_IamRolePolicy_D7855AC0" {
      - id     = "terraform-20230713231627409900000002:terraform-2023071323163389530000000c" -> null
      - name   = "terraform-2023071323163389530000000c" -> null
      - policy = jsonencode(
            {
              - Statement = [
                  - {
                      - Action   = [
                          - "dynamodb:PutItem",
                        ]
                      - Effect   = "Allow"
                      - Resource = [
                          - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                        ]
                    },
                  - {
                      - Action   = [
                          - "dynamodb:Scan",
                        ]
                      - Effect   = "Allow"
                      - Resource = [
                          - "arn:aws:dynamodb:us-east-1:223316951128:table/Table-785679de",
                        ]
                    },
                ]
              - Version   = "2012-10-17"
            }
        ) -> null
      - role   = "terraform-20230713231627409900000002" -> null
    }

  # aws_iam_role_policy_attachment.cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicyAttachment_73CC9260 will be destroyed
  # (because aws_iam_role_policy_attachment.cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicyAttachment_73CC9260 is not in configuration)
  - resource "aws_iam_role_policy_attachment" "cloudApi_cloudApi-OnRequest-41f14472_IamRolePolicyAttachment_73CC9260" {
      - id         = "terraform-20230713231627414600000005-20230713231627728200000007" -> null
      - policy_arn = "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" -> null
      - role       = "terraform-20230713231627414600000005" -> null
    }

  # aws_iam_role_policy_attachment.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicyAttachment_00E26B16 will be destroyed
  # (because aws_iam_role_policy_attachment.cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicyAttachment_00E26B16 is not in configuration)
  - resource "aws_iam_role_policy_attachment" "cloudApi_cloudApi-OnRequest-8d2e75ec_IamRolePolicyAttachment_00E26B16" {
      - id         = "terraform-20230713231627411800000003-20230713231627734200000009" -> null
      - policy_arn = "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" -> null
      - role       = "terraform-20230713231627411800000003" -> null
    }

  # aws_iam_role_policy_attachment.testputandgetaniteminthetable_Handler_IamRolePolicyAttachment_0EF121C6 will be destroyed
  # (because aws_iam_role_policy_attachment.testputandgetaniteminthetable_Handler_IamRolePolicyAttachment_0EF121C6 is not in configuration)
  - resource "aws_iam_role_policy_attachment" "testputandgetaniteminthetable_Handler_IamRolePolicyAttachment_0EF121C6" {
      - id         = "terraform-20230713231627409000000001-20230713231627731000000008" -> null
      - policy_arn = "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" -> null
      - role       = "terraform-20230713231627409000000001" -> null
    }

  # aws_iam_role_policy_attachment.testscanitemsinthetable_Handler_IamRolePolicyAttachment_F7F266A5 will be destroyed
  # (because aws_iam_role_policy_attachment.testscanitemsinthetable_Handler_IamRolePolicyAttachment_F7F266A5 is not in configuration)
  - resource "aws_iam_role_policy_attachment" "testscanitemsinthetable_Handler_IamRolePolicyAttachment_F7F266A5" {
      - id         = "terraform-20230713231627409900000002-20230713231627718900000006" -> null
      - policy_arn = "arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole" -> null
      - role       = "terraform-20230713231627409900000002" -> null
    }

  # aws_lambda_function.cloudApi_cloudApi-OnRequest-41f14472_B4385311 will be destroyed
  # (because aws_lambda_function.cloudApi_cloudApi-OnRequest-41f14472_B4385311 is not in configuration)
  - resource "aws_lambda_function" "cloudApi_cloudApi-OnRequest-41f14472_B4385311" {
      - architectures                  = [
          - "x86_64",
        ] -> null
      - arn                            = "arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-41f14472-c81170c6" -> null
      - function_name                  = "cloud-Api-OnRequest-41f14472-c81170c6" -> null
      - handler                        = "index.handler" -> null
      - id                             = "cloud-Api-OnRequest-41f14472-c81170c6" -> null
      - invoke_arn                     = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-41f14472-c81170c6/invocations" -> null
      - last_modified                  = "2023-07-13T23:16:44.776+0000" -> null
      - layers                         = [] -> null
      - memory_size                    = 128 -> null
      - package_type                   = "Zip" -> null
      - publish                        = true -> null
      - qualified_arn                  = "arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-41f14472-c81170c6:8" -> null
      - qualified_invoke_arn           = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-41f14472-c81170c6:8/invocations" -> null
      - reserved_concurrent_executions = -1 -> null
      - role                           = "arn:aws:iam::223316951128:role/terraform-20230713231627414600000005" -> null
      - runtime                        = "nodejs18.x" -> null
      - s3_bucket                      = "code-c84a50b1-20230713231627414400000004" -> null
      - s3_key                         = "asset.c81170c6eea85213cd98217b95378895ec0689d1c6.4762c7248564c35e1d71bf2a502552c2.zip" -> null
      - skip_destroy                   = false -> null
      - source_code_hash               = "SAylc/bFdOEpdAIoNbYF7tJuwDlfbYuuJg89jjsIIuE=" -> null
      - source_code_size               = 162178 -> null
      - tags                           = {} -> null
      - tags_all                       = {} -> null
      - timeout                        = 30 -> null
      - version                        = "8" -> null

      - environment {
          - variables = {
              - "WING_FUNCTION_NAME"         = "cloud-Api-OnRequest-41f14472-c81170c6"
              - "WING_TARGET"                = "tf-aws"
              - "WING_TOKEN_TFTOKEN_TOKEN_1" = "\"Table-785679de\""
            } -> null
        }

      - ephemeral_storage {
          - size = 512 -> null
        }

      - tracing_config {
          - mode = "PassThrough" -> null
        }
    }

  # aws_lambda_function.cloudApi_cloudApi-OnRequest-8d2e75ec_6AC8279C will be destroyed
  # (because aws_lambda_function.cloudApi_cloudApi-OnRequest-8d2e75ec_6AC8279C is not in configuration)
  - resource "aws_lambda_function" "cloudApi_cloudApi-OnRequest-8d2e75ec_6AC8279C" {
      - architectures                  = [
          - "x86_64",
        ] -> null
      - arn                            = "arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-8d2e75ec-c88d95b6" -> null
      - function_name                  = "cloud-Api-OnRequest-8d2e75ec-c88d95b6" -> null
      - handler                        = "index.handler" -> null
      - id                             = "cloud-Api-OnRequest-8d2e75ec-c88d95b6" -> null
      - invoke_arn                     = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-8d2e75ec-c88d95b6/invocations" -> null
      - last_modified                  = "2023-07-13T23:16:44.776+0000" -> null
      - layers                         = [] -> null
      - memory_size                    = 128 -> null
      - package_type                   = "Zip" -> null
      - publish                        = true -> null
      - qualified_arn                  = "arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-8d2e75ec-c88d95b6:9" -> null
      - qualified_invoke_arn           = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:cloud-Api-OnRequest-8d2e75ec-c88d95b6:9/invocations" -> null
      - reserved_concurrent_executions = -1 -> null
      - role                           = "arn:aws:iam::223316951128:role/terraform-20230713231627411800000003" -> null
      - runtime                        = "nodejs18.x" -> null
      - s3_bucket                      = "code-c84a50b1-20230713231627414400000004" -> null
      - s3_key                         = "asset.c88d95b6bc18cd30c63db5b8cb1a92698c78a2d31c.8166d73cc8c8bec3ac71f0ac3cfe49fe.zip" -> null
      - skip_destroy                   = false -> null
      - source_code_hash               = "i4wJrR1+Zp0eO+gyr89IhTgOluDDMewLejP4y2sZFxI=" -> null
      - source_code_size               = 161255 -> null
      - tags                           = {} -> null
      - tags_all                       = {} -> null
      - timeout                        = 30 -> null
      - version                        = "9" -> null

      - environment {
          - variables = {
              - "WING_FUNCTION_NAME"         = "cloud-Api-OnRequest-8d2e75ec-c88d95b6"
              - "WING_TARGET"                = "tf-aws"
              - "WING_TOKEN_TFTOKEN_TOKEN_1" = "\"Table-785679de\""
            } -> null
        }

      - ephemeral_storage {
          - size = 512 -> null
        }

      - tracing_config {
          - mode = "PassThrough" -> null
        }
    }

  # aws_lambda_function.testputandgetaniteminthetable_Handler_8825EF34 will be destroyed
  # (because aws_lambda_function.testputandgetaniteminthetable_Handler_8825EF34 is not in configuration)
  - resource "aws_lambda_function" "testputandgetaniteminthetable_Handler_8825EF34" {
      - architectures                  = [
          - "x86_64",
        ] -> null
      - arn                            = "arn:aws:lambda:us-east-1:223316951128:function:Handler-c8b2075c" -> null
      - function_name                  = "Handler-c8b2075c" -> null
      - handler                        = "index.handler" -> null
      - id                             = "Handler-c8b2075c" -> null
      - invoke_arn                     = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:Handler-c8b2075c/invocations" -> null
      - last_modified                  = "2023-07-13T23:16:38.109+0000" -> null
      - layers                         = [] -> null
      - memory_size                    = 128 -> null
      - package_type                   = "Zip" -> null
      - publish                        = true -> null
      - qualified_arn                  = "arn:aws:lambda:us-east-1:223316951128:function:Handler-c8b2075c:10" -> null
      - qualified_invoke_arn           = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:Handler-c8b2075c:10/invocations" -> null
      - reserved_concurrent_executions = -1 -> null
      - role                           = "arn:aws:iam::223316951128:role/terraform-20230713231627409000000001" -> null
      - runtime                        = "nodejs18.x" -> null
      - s3_bucket                      = "code-c84a50b1-20230713231627414400000004" -> null
      - s3_key                         = "asset.c8b2075c0e934e8562a3cca6418a82a68ca746a3e2.5cd5d161ab6b75ff8f847fe7657b7ab4.zip" -> null
      - skip_destroy                   = false -> null
      - source_code_hash               = "IsWf0HudDCJSMQSaNTN+/GNGFYHQZ2rRqs3vBc1NDtU=" -> null
      - source_code_size               = 144868 -> null
      - tags                           = {} -> null
      - tags_all                       = {} -> null
      - timeout                        = 30 -> null
      - version                        = "10" -> null

      - environment {
          - variables = {
              - "WING_FUNCTION_NAME"         = "Handler-c8b2075c"
              - "WING_TARGET"                = "tf-aws"
              - "WING_TOKEN_TFTOKEN_TOKEN_1" = "\"Table-785679de\""
            } -> null
        }

      - ephemeral_storage {
          - size = 512 -> null
        }

      - tracing_config {
          - mode = "PassThrough" -> null
        }
    }

  # aws_lambda_function.testscanitemsinthetable_Handler_603CBAFD will be destroyed
  # (because aws_lambda_function.testscanitemsinthetable_Handler_603CBAFD is not in configuration)
  - resource "aws_lambda_function" "testscanitemsinthetable_Handler_603CBAFD" {
      - architectures                  = [
          - "x86_64",
        ] -> null
      - arn                            = "arn:aws:lambda:us-east-1:223316951128:function:Handler-c8c4065c" -> null
      - function_name                  = "Handler-c8c4065c" -> null
      - handler                        = "index.handler" -> null
      - id                             = "Handler-c8c4065c" -> null
      - invoke_arn                     = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:Handler-c8c4065c/invocations" -> null
      - last_modified                  = "2023-07-13T23:16:42.166+0000" -> null
      - layers                         = [] -> null
      - memory_size                    = 128 -> null
      - package_type                   = "Zip" -> null
      - publish                        = true -> null
      - qualified_arn                  = "arn:aws:lambda:us-east-1:223316951128:function:Handler-c8c4065c:10" -> null
      - qualified_invoke_arn           = "arn:aws:apigateway:us-east-1:lambda:path/2015-03-31/functions/arn:aws:lambda:us-east-1:223316951128:function:Handler-c8c4065c:10/invocations" -> null
      - reserved_concurrent_executions = -1 -> null
      - role                           = "arn:aws:iam::223316951128:role/terraform-20230713231627409900000002" -> null
      - runtime                        = "nodejs18.x" -> null
      - s3_bucket                      = "code-c84a50b1-20230713231627414400000004" -> null
      - s3_key                         = "asset.c8c4065c0f44ecbaea60f96af9085e0e9e53ef183a.3a9c55b9613434b93430b6dd14c35891.zip" -> null
      - skip_destroy                   = false -> null
      - source_code_hash               = "hV/kMAE52vRfhV6sO79R7ssFhuaiB7seLV9y3ZdoGvc=" -> null
      - source_code_size               = 145246 -> null
      - tags                           = {} -> null
      - tags_all                       = {} -> null
      - timeout                        = 30 -> null
      - version                        = "10" -> null

      - environment {
          - variables = {
              - "WING_FUNCTION_NAME"         = "Handler-c8c4065c"
              - "WING_TARGET"                = "tf-aws"
              - "WING_TOKEN_TFTOKEN_TOKEN_1" = "\"Table-785679de\""
            } -> null
        }

      - ephemeral_storage {
          - size = 512 -> null
        }

      - tracing_config {
          - mode = "PassThrough" -> null
        }
    }

  # aws_lambda_permission.cloudApi_api_permission-GET-60cabf0c_3E7E8C53 will be destroyed
  # (because aws_lambda_permission.cloudApi_api_permission-GET-60cabf0c_3E7E8C53 is not in configuration)
  - resource "aws_lambda_permission" "cloudApi_api_permission-GET-60cabf0c_3E7E8C53" {
      - action        = "lambda:InvokeFunction" -> null
      - function_name = "cloud-Api-OnRequest-8d2e75ec-c88d95b6" -> null
      - id            = "AllowExecutionFromAPIGateway-GET-60cabf0c" -> null
      - principal     = "apigateway.amazonaws.com" -> null
      - source_arn    = "arn:aws:execute-api:us-east-1:223316951128:q1n5thtrf1/*/GET/items" -> null
      - statement_id  = "AllowExecutionFromAPIGateway-GET-60cabf0c" -> null
    }

  # aws_lambda_permission.cloudApi_api_permission-POST-cb38ebcb_8FB5CBF5 will be destroyed
  # (because aws_lambda_permission.cloudApi_api_permission-POST-cb38ebcb_8FB5CBF5 is not in configuration)
  - resource "aws_lambda_permission" "cloudApi_api_permission-POST-cb38ebcb_8FB5CBF5" {
      - action        = "lambda:InvokeFunction" -> null
      - function_name = "cloud-Api-OnRequest-41f14472-c81170c6" -> null
      - id            = "AllowExecutionFromAPIGateway-POST-cb38ebcb" -> null
      - principal     = "apigateway.amazonaws.com" -> null
      - source_arn    = "arn:aws:execute-api:us-east-1:223316951128:q1n5thtrf1/*/POST/vote" -> null
      - statement_id  = "AllowExecutionFromAPIGateway-POST-cb38ebcb" -> null
    }

  # aws_s3_bucket.Code will be destroyed
  # (because aws_s3_bucket.Code is not in configuration)
  - resource "aws_s3_bucket" "Code" {
      - arn                         = "arn:aws:s3:::code-c84a50b1-20230713231627414400000004" -> null
      - bucket                      = "code-c84a50b1-20230713231627414400000004" -> null
      - bucket_domain_name          = "code-c84a50b1-20230713231627414400000004.s3.amazonaws.com" -> null
      - bucket_prefix               = "code-c84a50b1-" -> null
      - bucket_regional_domain_name = "code-c84a50b1-20230713231627414400000004.s3.amazonaws.com" -> null
      - force_destroy               = false -> null
      - hosted_zone_id              = "Z3AQBSTGFYJSTF" -> null
      - id                          = "code-c84a50b1-20230713231627414400000004" -> null
      - object_lock_enabled         = false -> null
      - region                      = "us-east-1" -> null
      - request_payer               = "BucketOwner" -> null
      - tags                        = {} -> null
      - tags_all                    = {} -> null

      - grant {
          - id          = "f04581eb3b45ed589d9b96602566034fb74e8c59a91cc803ea7146c2a7385834" -> null
          - permissions = [
              - "FULL_CONTROL",
            ] -> null
          - type        = "CanonicalUser" -> null
        }

      - server_side_encryption_configuration {
          - rule {
              - bucket_key_enabled = false -> null

              - apply_server_side_encryption_by_default {
                  - sse_algorithm = "AES256" -> null
                }
            }
        }

      - versioning {
          - enabled    = false -> null
          - mfa_delete = false -> null
        }
    }

  # aws_s3_object.cloudApi_cloudApi-OnRequest-41f14472_S3Object_2D3CDD60 will be destroyed
  # (because aws_s3_object.cloudApi_cloudApi-OnRequest-41f14472_S3Object_2D3CDD60 is not in configuration)
  - resource "aws_s3_object" "cloudApi_cloudApi-OnRequest-41f14472_S3Object_2D3CDD60" {
      - acl                    = "private" -> null
      - bucket                 = "code-c84a50b1-20230713231627414400000004" -> null
      - bucket_key_enabled     = false -> null
      - content_type           = "binary/octet-stream" -> null
      - etag                   = "89bda787161a819a3b70bbb732b0106a" -> null
      - force_destroy          = false -> null
      - id                     = "asset.c81170c6eea85213cd98217b95378895ec0689d1c6.4762c7248564c35e1d71bf2a502552c2.zip" -> null
      - key                    = "asset.c81170c6eea85213cd98217b95378895ec0689d1c6.4762c7248564c35e1d71bf2a502552c2.zip" -> null
      - metadata               = {} -> null
      - server_side_encryption = "AES256" -> null
      - source                 = "assets/cloudApi_cloudApi-OnRequest-41f14472_Asset_83DC60BE/4762C7248564C35E1D71BF2A502552C2/archive.zip" -> null
      - storage_class          = "STANDARD" -> null
      - tags                   = {} -> null
      - tags_all               = {} -> null
    }

  # aws_s3_object.cloudApi_cloudApi-OnRequest-8d2e75ec_S3Object_431AEB37 will be destroyed
  # (because aws_s3_object.cloudApi_cloudApi-OnRequest-8d2e75ec_S3Object_431AEB37 is not in configuration)
  - resource "aws_s3_object" "cloudApi_cloudApi-OnRequest-8d2e75ec_S3Object_431AEB37" {
      - acl                    = "private" -> null
      - bucket                 = "code-c84a50b1-20230713231627414400000004" -> null
      - bucket_key_enabled     = false -> null
      - content_type           = "binary/octet-stream" -> null
      - etag                   = "eb8fe384bf15bc5b29dd1491da8d8544" -> null
      - force_destroy          = false -> null
      - id                     = "asset.c88d95b6bc18cd30c63db5b8cb1a92698c78a2d31c.8166d73cc8c8bec3ac71f0ac3cfe49fe.zip" -> null
      - key                    = "asset.c88d95b6bc18cd30c63db5b8cb1a92698c78a2d31c.8166d73cc8c8bec3ac71f0ac3cfe49fe.zip" -> null
      - metadata               = {} -> null
      - server_side_encryption = "AES256" -> null
      - source                 = "assets/cloudApi_cloudApi-OnRequest-8d2e75ec_Asset_8197EBA4/8166D73CC8C8BEC3AC71F0AC3CFE49FE/archive.zip" -> null
      - storage_class          = "STANDARD" -> null
      - tags                   = {} -> null
      - tags_all               = {} -> null
    }

  # aws_s3_object.testputandgetaniteminthetable_Handler_S3Object_99B690DF will be destroyed
  # (because aws_s3_object.testputandgetaniteminthetable_Handler_S3Object_99B690DF is not in configuration)
  - resource "aws_s3_object" "testputandgetaniteminthetable_Handler_S3Object_99B690DF" {
      - acl                    = "private" -> null
      - bucket                 = "code-c84a50b1-20230713231627414400000004" -> null
      - bucket_key_enabled     = false -> null
      - content_type           = "binary/octet-stream" -> null
      - etag                   = "26432206d3d7efcaccf8e5e6c81cdd8a" -> null
      - force_destroy          = false -> null
      - id                     = "asset.c8b2075c0e934e8562a3cca6418a82a68ca746a3e2.5cd5d161ab6b75ff8f847fe7657b7ab4.zip" -> null
      - key                    = "asset.c8b2075c0e934e8562a3cca6418a82a68ca746a3e2.5cd5d161ab6b75ff8f847fe7657b7ab4.zip" -> null
      - metadata               = {} -> null
      - server_side_encryption = "AES256" -> null
      - source                 = "assets/testputandgetaniteminthetable_Handler_Asset_C9624529/5CD5D161AB6B75FF8F847FE7657B7AB4/archive.zip" -> null
      - storage_class          = "STANDARD" -> null
      - tags                   = {} -> null
      - tags_all               = {} -> null
    }

  # aws_s3_object.testscanitemsinthetable_Handler_S3Object_101BF1FD will be destroyed
  # (because aws_s3_object.testscanitemsinthetable_Handler_S3Object_101BF1FD is not in configuration)
  - resource "aws_s3_object" "testscanitemsinthetable_Handler_S3Object_101BF1FD" {
      - acl                    = "private" -> null
      - bucket                 = "code-c84a50b1-20230713231627414400000004" -> null
      - bucket_key_enabled     = false -> null
      - content_type           = "binary/octet-stream" -> null
      - etag                   = "8ee5ac840ecf9208a38d0899beb64498" -> null
      - force_destroy          = false -> null
      - id                     = "asset.c8c4065c0f44ecbaea60f96af9085e0e9e53ef183a.3a9c55b9613434b93430b6dd14c35891.zip" -> null
      - key                    = "asset.c8c4065c0f44ecbaea60f96af9085e0e9e53ef183a.3a9c55b9613434b93430b6dd14c35891.zip" -> null
      - metadata               = {} -> null
      - server_side_encryption = "AES256" -> null
      - source                 = "assets/testscanitemsinthetable_Handler_Asset_0C770AB9/3A9C55B9613434B93430B6DD14C35891/archive.zip" -> null
      - storage_class          = "STANDARD" -> null
      - tags                   = {} -> null
      - tags_all               = {} -> null
    }

Plan: 0 to add, 0 to change, 27 to destroy.

Changes to Outputs:
  ~ WING_TEST_RUNNER_FUNCTION_ARNS = jsonencode(
      ~ [
          - [
              - "root/Default/Default/test:put and get an item in the table",
              - "arn:aws:lambda:us-east-1:223316951128:function:Handler-c8b2075c",
            ],
          - [
              - "root/Default/Default/test:scan items in the table",
              - "arn:aws:lambda:us-east-1:223316951128:function:Handler-c8c4065c",
            ],
        ]
    )

@Chriscbr Chriscbr merged commit 1aeeb6b into main Jul 21, 2023
1 check passed
@Chriscbr Chriscbr deleted the cleanup branch July 21, 2023 18:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant