Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/lib/icu/invoke.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,13 @@ async function main(argv: string[]) {
'use --service <path> to set service proto definition url'
);
}
const sockAddr = args['--sock'] ?? getSockAddr(service);
let sockAddr = args['--sock'] ?? getSockAddr(service);
if (sockAddr == null) {
throw new IcuError('use --sock <address> to set host address');
}
if (sockAddr.startsWith('/')) {
sockAddr = `unix://${sockAddr}`;
}
const { grpcDescriptor } = loadDescriptor(args['--include']);
const serviceDescriptor: any = _.get(grpcDescriptor, service);
if (serviceDescriptor == null) {
Expand Down
3 changes: 3 additions & 0 deletions src/lib/icu/listen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ async function main(argv: string[]) {
if (sockAddr == null) {
throw new IcuError('use --sock <address> to set host address');
}
if (sockAddr.startsWith('/')) {
sockAddr = `unix://${sockAddr}`;
}

const guest = new Guest(sockAddr);
await guest.start();
Expand Down