mirror of
https://github.com/farcasclaudiu/openclaw.git
synced 2026-06-28 19:01:47 +03:00
fix(docker): support .mjs entrypoints in images and e2e
This commit is contained in:
@@ -80,10 +80,20 @@ LOGINCTL
|
||||
fi
|
||||
npm install -g --prefix /tmp/npm-prefix "/app/$pkg_tgz"
|
||||
|
||||
npm_bin="/tmp/npm-prefix/bin/openclaw"
|
||||
npm_entry="/tmp/npm-prefix/lib/node_modules/openclaw/dist/index.js"
|
||||
git_entry="/app/dist/index.js"
|
||||
git_cli="/app/openclaw.mjs"
|
||||
npm_bin="/tmp/npm-prefix/bin/openclaw"
|
||||
npm_root="/tmp/npm-prefix/lib/node_modules/openclaw"
|
||||
if [ -f "$npm_root/dist/index.mjs" ]; then
|
||||
npm_entry="$npm_root/dist/index.mjs"
|
||||
else
|
||||
npm_entry="$npm_root/dist/index.js"
|
||||
fi
|
||||
|
||||
if [ -f "/app/dist/index.mjs" ]; then
|
||||
git_entry="/app/dist/index.mjs"
|
||||
else
|
||||
git_entry="/app/dist/index.js"
|
||||
fi
|
||||
git_cli="/app/openclaw.mjs"
|
||||
|
||||
assert_entrypoint() {
|
||||
local unit_path="$1"
|
||||
|
||||
Reference in New Issue
Block a user