From f75ff56785f2c9c2a91b982209a4102a52a4ea6d Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Wed, 12 Jan 2022 17:23:34 +0100 Subject: [PATCH] execute script directly --- backend/src/webhook/github.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/backend/src/webhook/github.ts b/backend/src/webhook/github.ts index 31ce5ed94..fdeb0dfaf 100644 --- a/backend/src/webhook/github.ts +++ b/backend/src/webhook/github.ts @@ -15,11 +15,8 @@ export const githubWebhook = async (req: any, res: any): Promise => { if (payload.ref === `refs/heads/${CONFIG.WEBHOOK_GITHUB_BRANCH}`) { // spawn shell and detach process to allow killing of parent process in the update script const child = spawn( - '/bin/bash', - [ - path.join(__dirname, '../../../deployment/bare_metal/start.sh'), - CONFIG.WEBHOOK_GITHUB_BRANCH, - ], + path.join(__dirname, '../../../deployment/bare_metal/start.sh'), + [CONFIG.WEBHOOK_GITHUB_BRANCH], { detached: true, stdio: ['ignore', 'ignore', 'ignore'],