File tree Expand file tree Collapse file tree 2 files changed +6
-7
lines changed
Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Original file line number Diff line number Diff line change 11import "server-only" ;
22
33import { decrypt } from "@cap/database/crypto" ;
4+ import { serverEnv } from "@cap/env" ;
45import {
56 AwsCredentials ,
67 Database ,
@@ -36,7 +37,6 @@ import {
3637 Redacted ,
3738} from "effect" ;
3839import { cookies } from "next/headers" ;
39-
4040import { allowedOrigins } from "@/utils/cors" ;
4141import { layerTracer } from "./tracing" ;
4242
@@ -56,10 +56,9 @@ const CookiePasswordAttachmentLive = Layer.effect(
5656class WorkflowRpcSecret extends Effect . Service < WorkflowRpcSecret > ( ) (
5757 "WorkflowRpcSecret" ,
5858 {
59- effect : Effect . map (
60- Config . redacted ( Config . string ( "WORKFLOWS_RPC_SECRET" ) ) ,
61- ( v ) => ( { authSecret : v } ) ,
62- ) ,
59+ sync : ( ) => ( {
60+ authSecret : Redacted . make ( serverEnv ( ) . WORKFLOWS_RPC_SECRET ) ,
61+ } ) ,
6362 } ,
6463) { }
6564
Original file line number Diff line number Diff line change @@ -67,8 +67,8 @@ function createServerEnv() {
6767 S3_PUBLIC_ENDPOINT : z . string ( ) . optional ( ) ,
6868 S3_INTERNAL_ENDPOINT : z . string ( ) . optional ( ) ,
6969 VERCEL_AWS_ROLE_ARN : z . string ( ) . optional ( ) ,
70- REMOTE_WORKFLOW_URL : z . string ( ) . optional ( ) ,
71- REMOTE_WORKFLOW_SECRET : z . string ( ) . optional ( ) ,
70+ WORKFLOWS_RPC_URL : z . string ( ) . optional ( ) ,
71+ WORKFLOWS_RPC_SECRET : z . string ( ) ,
7272 } ,
7373 experimental__runtimeEnv : {
7474 ...process . env ,
You can’t perform that action at this time.
0 commit comments