-
Notifications
You must be signed in to change notification settings - Fork 21
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
Grant digest email adjustments #2792
Conversation
1bf6fb3
to
0b4b1d0
Compare
QA Summary
Test CoverageCoverage report for `packages/client`
Coverage report for `packages/server`
Pusher: @jeffsmohan, Action: |
Terraform Summary
Hint: If "Terraform Format & Style" failed, run OutputValidation Output
Plan OutputNote: 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 = "2024-03-20T13:04:36Z" -> "2024-03-20T16:05:29Z"
# (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 = "2024-03-20T15:15:00Z" -> "2024-03-20T16:05:29Z"
# (1 unchanged element hidden)
},
]
tags = {}
# (11 unchanged attributes hidden)
# (6 unchanged blocks 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
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:188" -> (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:188" -> (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" = "5458ee36bf5199b13f6081530d093c2ad09994a9" -> "57dd906e1a8cdfc9369590ceac802581f40be7e2"
# (2 unchanged elements hidden)
}
~ environment = [
# (7 unchanged elements hidden)
{
name = "DD_SERVICE"
value = "gost"
},
~ {
name = "DD_VERSION"
~ value = "5458ee36bf5199b13f6081530d093c2ad09994a9" -> "57dd906e1a8cdfc9369590ceac802581f40be7e2"
},
{
name = "ENABLE_GRANTS_DIGEST"
value = "false"
},
# (12 unchanged elements hidden)
]
~ image = "ghcr.io/usdigitalresponse/usdr-gost-api:5458ee36bf5199b13f6081530d093c2ad09994a9@sha256:97d3ab796d30f6fd36b8871e466c9b7edb9c05d0f842e440c1a4d9dd898f786b" -> "ghcr.io/usdigitalresponse/usdr-gost-api:57dd906e1a8cdfc9369590ceac802581f40be7e2@sha256:b9c4fe29cb311360f6a7a2b9ea55e99cf370d0bc12dc90dd83d7046a99fcd2c7"
name = "api"
- systemControls = [] -> null
- volumesFrom = [] -> null
# (9 unchanged elements hidden)
} # forces replacement,
~ {
~ dockerLabels = {
~ "com.datadoghq.tags.version" = "5458ee36bf5199b13f6081530d093c2ad09994a9" -> "57dd906e1a8cdfc9369590ceac802581f40be7e2"
# (2 unchanged elements hidden)
}
~ environment = [
# (3 unchanged elements hidden)
{
name = "DD_SERVICE"
value = "gost"
},
~ {
name = "DD_VERSION"
~ value = "5458ee36bf5199b13f6081530d093c2ad09994a9" -> "57dd906e1a8cdfc9369590ceac802581f40be7e2"
},
{
name = "ECS_FARGATE"
value = "true"
},
]
- mountPoints = [] -> null
name = "datadog"
- portMappings = [] -> null
- systemControls = [] -> null
- volumesFrom = [] -> null
# (6 unchanged elements hidden)
} # forces replacement,
]
)
~ id = "gost-staging-api" -> (known after apply)
~ revision = 188 -> (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.arpa_audit_report.aws_ecs_service.default will be updated in-place
~ resource "aws_ecs_service" "default" {
id = "arn:aws:ecs:us-west-2:357150818708:service/gost-staging/gost-staging-arpa_audit_report"
name = "gost-staging-arpa_audit_report"
tags = {}
~ task_definition = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-arpa_audit_report:157" -> (known after apply)
# (15 unchanged attributes hidden)
# (3 unchanged blocks hidden)
}
# module.arpa_audit_report.aws_ecs_task_definition.consumer must be replaced
+/- resource "aws_ecs_task_definition" "consumer" {
~ arn = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-arpa_audit_report:157" -> (known after apply)
~ arn_without_revision = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-arpa_audit_report" -> (known after apply)
~ container_definitions = (sensitive value) # forces replacement
~ id = "gost-staging-arpa_audit_report" -> (known after apply)
- ipc_mode = "" -> null
- pid_mode = "" -> null
~ revision = 157 -> (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.arpa_treasury_report.aws_ecs_service.default will be updated in-place
~ resource "aws_ecs_service" "default" {
id = "arn:aws:ecs:us-west-2:357150818708:service/gost-staging/gost-staging-treasury_report"
name = "gost-staging-treasury_report"
tags = {}
~ task_definition = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-treasury_report:146" -> (known after apply)
# (15 unchanged attributes hidden)
# (3 unchanged blocks hidden)
}
# module.arpa_treasury_report.aws_ecs_task_definition.consumer must be replaced
+/- resource "aws_ecs_task_definition" "consumer" {
~ arn = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-treasury_report:146" -> (known after apply)
~ arn_without_revision = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-treasury_report" -> (known after apply)
~ container_definitions = (sensitive value) # forces replacement
~ id = "gost-staging-treasury_report" -> (known after apply)
- ipc_mode = "" -> null
- pid_mode = "" -> null
~ revision = 146 -> (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.consume_grants.aws_ecs_service.default will be updated in-place
~ resource "aws_ecs_service" "default" {
id = "arn:aws:ecs:us-west-2:357150818708:service/gost-staging/gost-staging-consume_grants"
name = "gost-staging-consume_grants"
tags = {}
~ task_definition = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-consume_grants:173" -> (known after apply)
# (15 unchanged attributes hidden)
# (3 unchanged blocks hidden)
}
# module.consume_grants.aws_ecs_task_definition.consume_grants must be replaced
+/- resource "aws_ecs_task_definition" "consume_grants" {
~ arn = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-consume_grants:173" -> (known after apply)
~ arn_without_revision = "arn:aws:ecs:us-west-2:357150818708:task-definition/gost-staging-consume_grants" -> (known after apply)
~ container_definitions = (sensitive value) # forces replacement
~ id = "gost-staging-consume_grants" -> (known after apply)
- ipc_mode = "" -> null
- pid_mode = "" -> null
~ revision = 173 -> (known after apply)
- tags = {} -> null
# (9 unchanged attributes hidden)
# (1 unchanged block hidden)
}
# module.website.aws_s3_object.deploy-config[0] will be updated in-place
~ resource "aws_s3_object" "deploy-config" {
~ content = <<-EOT
window.APP_CONFIG = window.APP_CONFIG || {};
window.APP_CONFIG.apiURLForGOST = 'https://api.staging.grants.usdr.dev/';
window.apiURLForGOST = window.APP_CONFIG.apiURLForGOST; // Legacy
window.APP_CONFIG.DD_RUM_ENABLED = true;
- window.APP_CONFIG.DD_RUM_CONFIG = {"allowedTracingUrls":["https://api.staging.grants.usdr.dev"],"applicationId":"15db471e-2ccb-4d3c-a6bf-99b750d748f5","clientToken":"pub50834fcc1999d53e546519b1a0f03934","defaultPrivacyLevel":"mask","env":"staging","service":"gost","sessionReplaySampleRate":1,"sessionSampleRate":10,"site":"datadoghq.com","trackLongTasks":true,"trackResources":true,"trackUserInteractions":true,"version":"5458ee36bf5199b13f6081530d093c2ad09994a9"};
+ window.APP_CONFIG.DD_RUM_CONFIG = {"allowedTracingUrls":["https://api.staging.grants.usdr.dev"],"applicationId":"15db471e-2ccb-4d3c-a6bf-99b750d748f5","clientToken":"pub50834fcc1999d53e546519b1a0f03934","defaultPrivacyLevel":"mask","env":"staging","service":"gost","sessionReplaySampleRate":1,"sessionSampleRate":10,"site":"datadoghq.com","trackLongTasks":true,"trackResources":true,"trackUserInteractions":true,"version":"57dd906e1a8cdfc9369590ceac802581f40be7e2"};
window.APP_CONFIG.GOOGLE_TAG_ID = 'G-D5DFR7BN0N';
window.APP_CONFIG.featureFlags = {"myProfileEnabled":true,"newGrantsDetailPageEnabled":true,"newTerminologyEnabled":true};
window.APP_CONFIG.overrideFeatureFlag = (flagName, overrideValue) => {
const storageKey = 'featureFlags';
let overrides = {};
try {
overrides = JSON.parse(window.sessionStorage.getItem(storageKey)) || {};
} catch (e) {
console.error(`Error parsing window.sessionStorage.${storageKey} as JSON:`, e);
console.warn(`window.sessionStorage.${storageKey} will be replaced.`);
}
overrides[flagName] = overrideValue;
window.sessionStorage.setItem(storageKey, JSON.stringify(overrides));
console.log('New feature flag overrides in page session:',
window.sessionStorage.getItem(storageKey));
};
EOT
~ etag = "57d8d7f1271a9a0910d2be088a103b25" -> "32322a8d407506960c508f8aecc21aec"
id = "/config/deploy-config.js"
tags = {}
~ version_id = "5ypW4ciMpJ0jXaMMsKl8jBLKrIr..vCC" -> (known after apply)
# (10 unchanged attributes hidden)
}
# module.website.aws_s3_object.origin_dist_artifact["js/chunk-vendors.b597f269.js.map"] will be updated in-place
~ resource "aws_s3_object" "origin_dist_artifact" {
~ etag = "343fc9be049ffc9e2bf665d8112fb7e2-2" -> "6e7b791be2fc4e1d2f14d7cf8a8daac0"
id = "dist/js/chunk-vendors.b597f269.js.map"
tags = {}
~ version_id = "GbDixPd7XcmKGmP5k5NoQ1ziPtGEaD19" -> (known after apply)
# (12 unchanged attributes hidden)
}
Plan: 4 to add, 6 to change, 4 to destroy. Pusher: @jeffsmohan, Action: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Quick tweak for added consistency, but looks good!
Co-authored-by: Tyler Hendrickson <[email protected]>
Ticket #2353
Description
Tweaks the grants digest email to bring it fully in line with design expectations. Specifically:
Screenshots / Demo Video
Note that the ethereal email tool doesn't display preview text in the inbox, so we'll want to double-check this functionality with real emails sent on staging.
Testing
Testing this in dev is a lot of pretty fiddly effort, but here are the steps:
NODEMAILER_*
environment variables in yourpackages/server/.env
file from the values listed on your ethereal accountsecure: true
in our nodemailer setup (Gmail uses a secure connection, but ethereal doesn't):usdr-gost/packages/server/src/lib/email/email-nodemailer.js
Line 36 in 05f688e
docker compose down app
anddocker compose up -d
)docker compose exec app yarn node
Automated and Unit Tests
Manual tests for Reviewer
Checklist