Skip to content

Commit 0211c53

Browse files
authored
Merge branch 'main' into feature/CCM-13148_fix-manual-proxy
2 parents d7368cb + c30a571 commit 0211c53

File tree

97 files changed

+18632
-17576
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

97 files changed

+18632
-17576
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
/.github/ @NHSDigital/nhs-notify-supplier-api-admins
66
*.code-workspace @NHSDigital/nhs-notify-supplier-api-admins
77
/docs/ @NHSDigital/nhs-notify-supplier-api
8-
/infrastructure/terraform/ @NHSDigital/nhs-notify-platform
8+
/infrastructure/terraform/ @NHSDigital/nhs-notify-platform @NHSDigital/nhs-notify-supplier-api-admins
99

1010
# Codeowners must be final check
1111
/.github/CODEOWNERS @NHSDigital/nhs-notify-code-owners

.github/actions/build-docs/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ runs:
1111
uses: actions/checkout@v4
1212
- uses: actions/setup-node@v4
1313
with:
14-
node-version: 18
14+
node-version: 22
1515
- name: Npm cli install
1616
working-directory: .
1717
run: npm ci

.github/actions/build-libraries/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ runs:
1111
uses: actions/checkout@v4
1212
- uses: actions/setup-node@v4
1313
with:
14-
node-version: 24
14+
node-version: 22
1515

1616
- name: Npm install
1717
working-directory: .

.github/actions/build-sandbox/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ runs:
1212
uses: actions/checkout@v4
1313
- uses: actions/setup-node@v4
1414
with:
15-
node-version: 24
15+
node-version: 22
1616

1717
- name: Npm install
1818
working-directory: .

.github/actions/build-sdk/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ runs:
1111
uses: actions/checkout@v4
1212
- uses: actions/setup-node@v4
1313
with:
14-
node-version: 18
14+
node-version: 22
1515

1616
- name: Npm install
1717
working-directory: .

.github/actions/build-server/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ runs:
1111
uses: actions/checkout@v4
1212
- uses: actions/setup-node@v4
1313
with:
14-
node-version: 24
14+
node-version: 22
1515

1616
- name: Npm install
1717
working-directory: .

infrastructure/terraform/components/api/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,13 @@ No requirements.
3737
| <a name="module_get_letter"></a> [get\_letter](#module\_get\_letter) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
3838
| <a name="module_get_letter_data"></a> [get\_letter\_data](#module\_get\_letter\_data) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
3939
| <a name="module_get_letters"></a> [get\_letters](#module\_get\_letters) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
40+
| <a name="module_get_status"></a> [get\_status](#module\_get\_status) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
4041
| <a name="module_kms"></a> [kms](#module\_kms) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-kms.zip | n/a |
42+
| <a name="module_letter_status_update"></a> [letter\_status\_update](#module\_letter\_status\_update) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
43+
| <a name="module_letter_status_updates_queue"></a> [letter\_status\_updates\_queue](#module\_letter\_status\_updates\_queue) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-sqs.zip | n/a |
4144
| <a name="module_logging_bucket"></a> [logging\_bucket](#module\_logging\_bucket) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-s3bucket.zip | n/a |
4245
| <a name="module_patch_letter"></a> [patch\_letter](#module\_patch\_letter) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
46+
| <a name="module_post_letters"></a> [post\_letters](#module\_post\_letters) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
4347
| <a name="module_post_mi"></a> [post\_mi](#module\_post\_mi) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.24/terraform-lambda.zip | n/a |
4448
| <a name="module_s3bucket_test_letters"></a> [s3bucket\_test\_letters](#module\_s3bucket\_test\_letters) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-s3bucket.zip | n/a |
4549
| <a name="module_supplier_ssl"></a> [supplier\_ssl](#module\_supplier\_ssl) | https://github.com/NHSDigital/nhs-notify-shared-modules/releases/download/v2.0.20/terraform-ssl.zip | n/a |
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
resource "aws_cloudwatch_metric_alarm" "alm-apim-client-certificate-near-expiry" {
2+
alarm_name = "${local.csi}-alm-apim-client-certificate-near-expiry"
3+
alarm_description = "RELIABILITY: An APIM client certificate is due to expire soon"
4+
5+
metric_name = "apim-client-certificate-near-expiry"
6+
namespace = "comms-apim-authorizer"
7+
8+
dimensions = {
9+
Environment = var.environment
10+
}
11+
12+
period = 60 * 60 * 4 //4 hours
13+
comparison_operator = "GreaterThanThreshold"
14+
threshold = "0"
15+
evaluation_periods = "1"
16+
statistic = "Sum"
17+
treat_missing_data = "notBreaching"
18+
19+
actions_enabled = "false"
20+
alarm_actions = []
21+
ok_actions = []
22+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
resource "aws_dynamodb_table" "suppliers" {
2+
name = "${local.csi}-suppliers"
3+
billing_mode = "PAY_PER_REQUEST"
4+
5+
hash_key = "id"
6+
range_key = "apimId"
7+
8+
ttl {
9+
attribute_name = "ttl"
10+
enabled = false
11+
}
12+
13+
global_secondary_index {
14+
name = "supplier-apim-index"
15+
hash_key = "apimId"
16+
projection_type = "ALL"
17+
}
18+
19+
attribute {
20+
name = "id"
21+
type = "S"
22+
}
23+
24+
attribute {
25+
name = "apimId"
26+
type = "S"
27+
}
28+
29+
point_in_time_recovery {
30+
enabled = true
31+
}
32+
33+
tags = var.default_tags
34+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
resource "aws_lambda_event_source_mapping" "status_updates_sqs_to_status_update_handler" {
2+
event_source_arn = module.letter_status_updates_queue.sqs_queue_arn
3+
function_name = module.letter_status_update.function_arn
4+
batch_size = 10
5+
maximum_batching_window_in_seconds = 1
6+
scaling_config { maximum_concurrency = 10 }
7+
8+
depends_on = [
9+
module.letter_status_updates_queue, # ensures queue exists
10+
module.letter_status_update # ensures update handler exists
11+
]
12+
}

0 commit comments

Comments
 (0)