Skip to content

Commit c827295

Browse files
authored
Merge pull request #114 from OpenFunction/feature/dapr-proxy
2 parents 5bdf64a + aafb49c commit c827295

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/openfunction/async_server.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export default function (
2020
context: OpenFunctionContext
2121
): AsyncFunctionServer {
2222
// Initailize Dapr server
23-
const app = new DaprServer('localhost', context.port);
23+
const app = new DaprServer('127.0.0.1', context.port, process.env.DAPR_HOST);
2424

2525
// Create wrapper for user function
2626
const wrapper = OpenFunctionRuntime.WrapUserFunction(userFunction, context);

src/openfunction/runtime.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ class DaprRuntime extends OpenFunctionRuntime {
206206
* TODO: Should determine whether to use GRPC channel
207207
*/
208208
this.daprClient = new DaprClient(
209-
undefined,
209+
process.env.DAPR_HOST,
210210
this.sidecarPort.HTTP,
211211
CommunicationProtocolEnum.HTTP
212212
);

0 commit comments

Comments
 (0)