Skip to content

Commit ec0c474

Browse files
committed
fix: コンパイル済みバイナリでスーパーバイザーが起動しない問題を修正
process.execPathがBunバイナリ内部パスを返すため、process.argv[0]を使用
1 parent 3f41206 commit ec0c474

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/main.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,8 @@ async function runSupervisor(): Promise<void> {
7474
logger.info("スーパーバイザー起動");
7575

7676
const spawnWorker = (): void => {
77-
const worker = Bun.spawn([process.execPath, ...process.argv.slice(1)], {
77+
const execPath = process.argv[0] ?? process.execPath;
78+
const worker = Bun.spawn([execPath, ...process.argv.slice(1)], {
7879
env: { ...process.env, [WORKER_ENV_KEY]: "1" },
7980
stdout: "inherit",
8081
stderr: "inherit",

0 commit comments

Comments
 (0)