Skip to content

Commit 136f460

Browse files
committed
fixup! chore: remove bridge proxy and use node-bridge as default
1 parent 19d814c commit 136f460

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/binaries/node-bridge/modify_node_bin_js.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,13 @@ else
2929
exit 1
3030
fi
3131

32+
3233
# replace all occurrences of 127.0.0.1 with 0.0.0.0
3334
# TL;DR: macOS Docker's extra VM layer requires explicit binding to all interfaces (0.0.0.0) to be reachable from the host.
34-
if grep -q "127.0.0.1" "$1"; then
35-
sed -i 's/127.0.0.1/0.0.0.0/g' "$1"
36-
echo "Success: replaced '127.0.0.1' with '0.0.0.0'."
35+
if grep -q 'var ADDRESS = "http://127.0.0.1"' "$1"; then
36+
sed -i 's|var ADDRESS = "http://127.0.0.1"|var ADDRESS = "http://0.0.0.0"|g' "$1"
37+
echo "Success: replaced 'var ADDRESS = \"http://127.0.0.1\"' with 'var ADDRESS = \"http://0.0.0.0\"'."
3738
else
38-
echo "Error: no line matching '127.0.0.1' found in '$1'."
39+
echo "Error: no line matching 'var ADDRESS = \"http://127.0.0.1\"' found in '$1'."
3940
exit 1
4041
fi

0 commit comments

Comments
 (0)