Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F2766275
D12974.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D12974.diff
View Options
diff --git a/services/terraform/remote/service_backup.tf b/services/terraform/remote/service_backup.tf
--- a/services/terraform/remote/service_backup.tf
+++ b/services/terraform/remote/service_backup.tf
@@ -1,9 +1,17 @@
locals {
- backup_service_image_tag = local.is_staging ? "0.4.1-staging" : "0.4.1"
- backup_service_container_name = "backup-service-server"
- backup_service_server_image = "commapp/backup-server:${local.backup_service_image_tag}"
+ backup_service_image_tag = local.is_staging ? "0.4.1-staging" : "0.4.1"
+ backup_service_container_name = "backup-service-server"
+ backup_service_server_image = "commapp/backup-server:${local.backup_service_image_tag}"
+ backup_service_domain_name = "backup.${local.root_domain}"
+
+ # HTTP port & configuration for ECS Service Connect
backup_service_container_http_port = 50052
- backup_service_domain_name = "backup.${local.root_domain}"
+ backup_sc_port_name = "backup-service-ecs-http"
+ backup_sc_dns_name = "backup-service"
+
+ # URL accessible by other services in the same Service Connect namespace
+ # This renders to 'http://backup-service:50052'
+ backup_local_url = "http://${local.backup_sc_dns_name}:${local.backup_service_container_http_port}"
}
resource "aws_ecs_task_definition" "backup_service" {
@@ -77,8 +85,15 @@
}
service_connect_configuration {
- # to be able to reach Blob service by DNS name
enabled = true
+ service {
+ discovery_name = local.backup_sc_dns_name
+ port_name = local.backup_sc_port_name
+ client_alias {
+ port = local.backup_service_container_http_port
+ dns_name = local.backup_sc_dns_name
+ }
+ }
}
# HTTP
diff --git a/services/terraform/remote/service_identity.tf b/services/terraform/remote/service_identity.tf
--- a/services/terraform/remote/service_identity.tf
+++ b/services/terraform/remote/service_identity.tf
@@ -76,6 +76,10 @@
name = "TUNNELBROKER_GRPC_ENDPOINT"
value = local.tunnelbroker_local_grpc_url
},
+ {
+ name = "BACKUP_SERVICE_URL",
+ value = local.backup_local_url
+ },
{
name = "OPENSEARCH_ENDPOINT"
value = module.shared.opensearch_domain_identity.endpoint
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Sep 20, 3:32 PM (19 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2150996
Default Alt Text
D12974.diff (2 KB)
Attached To
Mode
D12974: [terraform] Add Backup to ECS Service Connect
Attached
Detach File
Event Timeline
Log In to Comment