Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

fix dss deploy (#4125)

Will Hutchinson7698cda2e606
diff --git a/infra/stacks/cloud-storage-service/index.ts b/infra/stacks/cloud-storage-service/index.ts
index 2ad52e4929..189c644eb5 100644
--- a/infra/stacks/cloud-storage-service/index.ts
+++ b/infra/stacks/cloud-storage-service/index.ts
@@ -528,7 +528,7 @@ const cloudStorageService = new CloudStorageService(
value: pulumi.interpolate`${cloudfronSignerPublicKeyId}`,
},
{
- name: 'DOCUMENT_STORAGE_SERVICE_CLOUDFRONT_SIGNER_PRIVATE_KEY_SECRET_NAME',
+ name: 'DOCUMENT_STORAGE_SERVICE_CLOUDFRONT_SIGNER_PRIVATE_KEY',
value: pulumi.interpolate`${CLOUDFRONT_SIGNER_PRIVATE_KEY_SECRET_NAME}`,
},
{ name: 'ISSUER', value: pulumi.interpolate`${FUSIONAUTH_ISSUER}` },
diff --git a/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/create_permission_token.rs b/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/create_permission_token.rs
index c344b2c7e7..a57f0cfec4 100644
--- a/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/create_permission_token.rs
+++ b/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/create_permission_token.rs
@@ -77,7 +77,11 @@ pub async fn handler(
&header,
&document_permissions_token,
&jsonwebtoken::EncodingKey::from_secret(
- state.config.document_permission_jwt.as_ref().as_bytes(),
+ state
+ .config
+ .document_permission_jwt_secret_key
+ .as_ref()
+ .as_bytes(),
),
)
.map_err(|e| {
diff --git a/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/validate_permissions_token.rs b/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/validate_permissions_token.rs
index 183b374896..a6cbcbbdf7 100644
--- a/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/validate_permissions_token.rs
+++ b/rust/cloud-storage/document_storage_service/src/api/documents/permissions_token/validate_permissions_token.rs
@@ -53,7 +53,12 @@ pub async fn handler(
// Attempt to decode the token.
let decoded_jwt: DocumentPermissionsToken = match jsonwebtoken::decode::<DocumentPermissionsToken>(
&token,
- &DecodingKey::from_secret(config_context.document_permission_jwt.as_ref().as_bytes()),
+ &DecodingKey::from_secret(
+ config_context
+ .document_permission_jwt_secret_key
+ .as_ref()
+ .as_bytes(),
+ ),
&validation,
) {
Ok(decoded) => decoded.claims,
diff --git a/rust/cloud-storage/document_storage_service/src/config.rs b/rust/cloud-storage/document_storage_service/src/config.rs
index b5a64e752b..b012150a27 100644
--- a/rust/cloud-storage/document_storage_service/src/config.rs
+++ b/rust/cloud-storage/document_storage_service/src/config.rs
@@ -36,7 +36,7 @@ env_vars! {
pub struct DocumentLimit;
pub struct DocumentStorageServicePresignedUrlExpirySeconds;
pub struct DocumentStorageServicePresignedUrlBrowserCacheExpirySeconds;
- pub struct DocumentStorageServiceCloudfrontSignerPrivateKeySecretName;
+ pub struct DocumentStorageServiceCloudfrontSignerPrivateKey;
#[derive(Clone)]
pub struct DocumentPermissionJwtSecretKey;
pub struct GithubWebhookSecretKey;
@@ -137,9 +137,9 @@ pub struct Config {
pub document_storage_service_presigned_url_browser_cache_expiry_seconds: u64,
pub document_storage_service_cloudfront_signer_private_key:
- LocalOrRemoteSecret<DocumentStorageServiceCloudfrontSignerPrivateKeySecretName>,
+ LocalOrRemoteSecret<DocumentStorageServiceCloudfrontSignerPrivateKey>,
- pub document_permission_jwt: LocalOrRemoteSecret<DocumentPermissionJwtSecretKey>,
+ pub document_permission_jwt_secret_key: LocalOrRemoteSecret<DocumentPermissionJwtSecretKey>,
pub livekit_transcription_agent_name: LivekitTranscriptionAgentName,
pub internal_call_secret: InternalCallSecret,