Skip to content

Commit

Permalink
fix(runtime): fix strange dependency installation during runtime star…
Browse files Browse the repository at this point in the history
…tup (labring#2023)
  • Loading branch information
HUAHUAI23 authored Jul 17, 2024
1 parent ec03197 commit 99ce4f1
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions runtimes/nodejs/start.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#!/bin/sh

ln -s $CUSTOM_DEPENDENCY_BASE_PATH/node_modules $PWD/functions/node_modules > /dev/null 2>&1
ln -s $CUSTOM_DEPENDENCY_BASE_PATH/node_modules $PWD/functions/node_modules >/dev/null 2>&1

# generate package.json
(
cd $CUSTOM_DEPENDENCY_BASE_PATH
npm install $DEPENDENCIES $NPM_INSTALL_FLAGS > /dev/null 2>&1
)
# (
# cd $CUSTOM_DEPENDENCY_BASE_PATH
# npm install $DEPENDENCIES $NPM_INSTALL_FLAGS > /dev/null 2>&1
# )

# source .env
echo "****** start service: node $FLAGS --experimental-vm-modules --experimental-fetch ./dist/index.js *******"
exec node $FLAGS --experimental-vm-modules --experimental-fetch ./dist/index.js
exec node $FLAGS --experimental-vm-modules --experimental-fetch ./dist/index.js

0 comments on commit 99ce4f1

Please sign in to comment.