-
Notifications
You must be signed in to change notification settings - Fork 7
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
feat: release v1.0.4 to production #152
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Includes AWS Shield DDoS protection for ALB and Route53 as well as ECS IAM permission changes to allow the task to access DynamoDB.
Version diff |
Production: kms✅ Terraform Format: Plan: 1 to add, 0 to change, 0 to destroy Show planResource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# aws_kms_key.cloudwatch_us_east will be created
+ resource "aws_kms_key" "cloudwatch_us_east" {
+ arn = (known after apply)
+ bypass_policy_lockout_safety_check = false
+ customer_master_key_spec = "SYMMETRIC_DEFAULT"
+ description = "CloudWatch Log Group Key"
+ enable_key_rotation = true
+ id = (known after apply)
+ is_enabled = true
+ key_id = (known after apply)
+ key_usage = "ENCRYPT_DECRYPT"
+ policy = jsonencode(
{
+ Statement = [
+ {
+ Action = "kms:*"
+ Effect = "Allow"
+ Principal = {
+ AWS = "arn:aws:iam::957818836222:root"
}
+ Resource = "*"
+ Sid = "Enable IAM User Permissions"
},
+ {
+ Action = [
+ "kms:ReEncrypt*",
+ "kms:GenerateDataKey*",
+ "kms:Encrypt*",
+ "kms:Describe*",
+ "kms:Decrypt*",
]
+ Effect = "Allow"
+ Principal = {
+ Service = "logs.ca-central-1.amazonaws.com"
}
+ Resource = "*"
+ Sid = ""
},
+ {
+ Action = [
+ "kms:GenerateDataKey*",
+ "kms:Decrypt",
]
+ Effect = "Allow"
+ Principal = {
+ Service = "cloudwatch.amazonaws.com"
}
+ Resource = "*"
+ Sid = "Allow_CloudWatch_for_CMK"
},
+ {
+ Action = [
+ "kms:ReEncrypt*",
+ "kms:GenerateDataKey*",
+ "kms:Encrypt*",
+ "kms:Describe*",
+ "kms:Decrypt*",
]
+ Effect = "Allow"
+ Principal = {
+ Service = "events.amazonaws.com"
}
+ Resource = "*"
+ Sid = "CloudwatchEvents"
},
]
+ Version = "2012-10-17"
}
)
+ tags = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
+ tags_all = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
}
Plan: 1 to add, 0 to change, 0 to destroy.
Changes to Outputs:
+ kms_key_cloudwatch_us_east_arn = (known after apply)
─────────────────────────────────────────────────────────────────────────────
Saved the plan to: plan.tfplan
To perform exactly these actions, run the following command to apply:
terraform apply "plan.tfplan"
Releasing state lock. This may take a few moments...
Show Conftest results9 tests, 9 passed, 0 warnings, 0 failures, 0 exceptions
|
Production: load_balancer✅ Terraform Format: Plan: 2 to add, 0 to change, 0 to destroy Show planResource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# aws_shield_protection.alb will be created
+ resource "aws_shield_protection" "alb" {
+ arn = (known after apply)
+ id = (known after apply)
+ name = "LoadBalancer"
+ resource_arn = "arn:aws:elasticloadbalancing:ca-central-1:957818836222:loadbalancer/app/form-viewer/ef2ad28d416e7d87"
+ tags = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
+ tags_all = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
}
# aws_shield_protection.route53_hosted_zone will be created
+ resource "aws_shield_protection" "route53_hosted_zone" {
+ arn = (known after apply)
+ id = (known after apply)
+ name = "Route53HostedZone"
+ resource_arn = "arn:aws:route53:::hostedzone/Z1031499PBK3926Y7HKK"
+ tags = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
+ tags_all = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
}
Plan: 2 to add, 0 to change, 0 to destroy.
─────────────────────────────────────────────────────────────────────────────
Saved the plan to: plan.tfplan
To perform exactly these actions, run the following command to apply:
terraform apply "plan.tfplan"
Releasing state lock. This may take a few moments...
Show Conftest results9 tests, 9 passed, 0 warnings, 0 failures, 0 exceptions
|
Moro-Code
approved these changes
Dec 10, 2021
Production: app✅ Terraform Format: Plan: 1 to add, 0 to change, 0 to destroy Show planResource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# aws_iam_policy.forms_dynamodb will be created
+ resource "aws_iam_policy" "forms_dynamodb" {
+ arn = (known after apply)
+ description = "IAM policy for allowing access for Forms ECS task to read and write to the vault"
+ id = (known after apply)
+ name = "forms_dynamodb"
+ path = "/"
+ policy = jsonencode(
{
+ Statement = [
+ {
+ Action = [
+ "dynamodb:UpdateItem",
+ "dynamodb:Scan",
+ "dynamodb:Query",
+ "dynamodb:PutItem",
+ "dynamodb:GetItem",
+ "dynamodb:DeleteItem",
+ "dynamodb:BatchWriteItem",
]
+ Effect = "Allow"
+ Resource = [
+ "arn:aws:dynamodb:ca-central-1:957818836222:table/Vault",
+ "arn:aws:dynamodb:ca-central-1:957818836222:table/ReliabilityQueue",
]
+ Sid = ""
},
]
+ Version = "2012-10-17"
}
)
+ policy_id = (known after apply)
+ tags = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
+ tags_all = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
}
Plan: 1 to add, 0 to change, 0 to destroy.
─────────────────────────────────────────────────────────────────────────────
Saved the plan to: plan.tfplan
To perform exactly these actions, run the following command to apply:
terraform apply "plan.tfplan"
Releasing state lock. This may take a few moments...
Show Conftest results9 tests, 9 passed, 0 warnings, 0 failures, 0 exceptions
|
Production: alarms✅ Terraform Format: Plan: 8 to add, 0 to change, 0 to destroy Show planResource actions are indicated with the following symbols:
+ create
Terraform will perform the following actions:
# aws_cloudwatch_metric_alarm.alb_ddos will be created
+ resource "aws_cloudwatch_metric_alarm" "alb_ddos" {
+ actions_enabled = true
+ alarm_actions = [
+ "arn:aws:sns:ca-central-1:957818836222:alert-warning",
]
+ alarm_description = "DDoS detection for ALB"
+ alarm_name = "ALBDDoS"
+ arn = (known after apply)
+ comparison_operator = "GreaterThanThreshold"
+ dimensions = {
+ "ResourceArn" = "arn:aws:elasticloadbalancing:ca-central-1:957818836222:loadbalancer/app/form-viewer/ef2ad28d416e7d87"
}
+ evaluate_low_sample_count_percentiles = (known after apply)
+ evaluation_periods = 1
+ id = (known after apply)
+ metric_name = "DDoSDetected"
+ namespace = "AWS/DDoSProtection"
+ ok_actions = [
+ "arn:aws:sns:ca-central-1:957818836222:alert-ok",
]
+ period = 60
+ statistic = "Sum"
+ tags_all = (known after apply)
+ threshold = 0
+ treat_missing_data = "notBreaching"
}
# aws_cloudwatch_metric_alarm.route53_ddos will be created
+ resource "aws_cloudwatch_metric_alarm" "route53_ddos" {
+ actions_enabled = true
+ alarm_actions = (known after apply)
+ alarm_description = "DDoS detection for Route53"
+ alarm_name = "Route53DDoS"
+ arn = (known after apply)
+ comparison_operator = "GreaterThanThreshold"
+ dimensions = {
+ "ResourceArn" = "arn:aws:route53:::hostedzone/Z1031499PBK3926Y7HKK"
}
+ evaluate_low_sample_count_percentiles = (known after apply)
+ evaluation_periods = 1
+ id = (known after apply)
+ metric_name = "DDoSDetected"
+ namespace = "AWS/DDoSProtection"
+ ok_actions = (known after apply)
+ period = 60
+ statistic = "Sum"
+ tags_all = (known after apply)
+ threshold = 0
+ treat_missing_data = "notBreaching"
}
# aws_lambda_permission.notify_slack_ok_us_east will be created
+ resource "aws_lambda_permission" "notify_slack_ok_us_east" {
+ action = "lambda:InvokeFunction"
+ function_name = "NotifySlackSNS"
+ id = (known after apply)
+ principal = "sns.amazonaws.com"
+ source_arn = (known after apply)
+ statement_id = "AllowExecutionFromSNSOkAlertUSEast"
}
# aws_lambda_permission.notify_slack_warning_us_east will be created
+ resource "aws_lambda_permission" "notify_slack_warning_us_east" {
+ action = "lambda:InvokeFunction"
+ function_name = "NotifySlackSNS"
+ id = (known after apply)
+ principal = "sns.amazonaws.com"
+ source_arn = (known after apply)
+ statement_id = "AllowExecutionFromSNSWarningAlertUSEast"
}
# aws_sns_topic.alert_ok_us_east will be created
+ resource "aws_sns_topic" "alert_ok_us_east" {
+ arn = (known after apply)
+ content_based_deduplication = false
+ fifo_topic = false
+ id = (known after apply)
+ name = "alert-ok"
+ name_prefix = (known after apply)
+ owner = (known after apply)
+ policy = (known after apply)
+ tags = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
+ tags_all = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
}
# aws_sns_topic.alert_warning_us_east will be created
+ resource "aws_sns_topic" "alert_warning_us_east" {
+ arn = (known after apply)
+ content_based_deduplication = false
+ fifo_topic = false
+ id = (known after apply)
+ name = "alert-warning"
+ name_prefix = (known after apply)
+ owner = (known after apply)
+ policy = (known after apply)
+ tags = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
+ tags_all = {
+ "CostCentre" = "forms-platform-production"
+ "Terraform" = "true"
}
}
# aws_sns_topic_subscription.topic_ok_us_east will be created
+ resource "aws_sns_topic_subscription" "topic_ok_us_east" {
+ arn = (known after apply)
+ confirmation_timeout_in_minutes = 1
+ confirmation_was_authenticated = (known after apply)
+ endpoint = "arn:aws:lambda:ca-central-1:957818836222:function:NotifySlackSNS"
+ endpoint_auto_confirms = false
+ id = (known after apply)
+ owner_id = (known after apply)
+ pending_confirmation = (known after apply)
+ protocol = "lambda"
+ raw_message_delivery = false
+ topic_arn = (known after apply)
}
# aws_sns_topic_subscription.topic_warning_us_east will be created
+ resource "aws_sns_topic_subscription" "topic_warning_us_east" {
+ arn = (known after apply)
+ confirmation_timeout_in_minutes = 1
+ confirmation_was_authenticated = (known after apply)
+ endpoint = "arn:aws:lambda:ca-central-1:957818836222:function:NotifySlackSNS"
+ endpoint_auto_confirms = false
+ id = (known after apply)
+ owner_id = (known after apply)
+ pending_confirmation = (known after apply)
+ protocol = "lambda"
+ raw_message_delivery = false
+ topic_arn = (known after apply)
}
Plan: 8 to add, 0 to change, 0 to destroy.
─────────────────────────────────────────────────────────────────────────────
Saved the plan to: plan.tfplan
To perform exactly these actions, run the following command to apply:
terraform apply "plan.tfplan"
Releasing state lock. This may take a few moments...
Show Conftest resultsWARN - plan.json - main - Missing Common Tags: ["aws_cloudwatch_metric_alarm.alb_ddos"]
WARN - plan.json - main - Missing Common Tags: ["aws_cloudwatch_metric_alarm.route53_ddos"]
10 tests, 8 passed, 2 warnings, 0 failures, 0 exceptions
|
craigzour
pushed a commit
that referenced
this pull request
Dec 15, 2021
Includes AWS Shield DDoS protection for ALB and Route53 as well as ECS IAM permission changes to allow the task to access DynamoDB.
This was referenced Sep 11, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Includes AWS Shield DDoS protection for ALB and Route53 as
well as ECS IAM permission changes to allow the form viewer to access
DynamoDB.
Related