From 4452a816ffd512811d4206b3c3d07476e690bed9 Mon Sep 17 00:00:00 2001 From: Paul Fitzpatrick Date: Wed, 22 Jul 2020 12:35:41 -0400 Subject: [PATCH] (core) fix docker packaging after core shuffle Summary: The docker image was not building or running correctly after breaking out more material into core. This corrects the necessary paths. Test Plan: tested by building locally with `./contain.sh ./build docker` and running containers in development and production mode. Reviewers: dsagal Reviewed By: dsagal Differential Revision: https://phab.getgrist.com/D2555 --- app/server/lib/places.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/app/server/lib/places.ts b/app/server/lib/places.ts index adf83db7..c3316cca 100644 --- a/app/server/lib/places.ts +++ b/app/server/lib/places.ts @@ -14,6 +14,7 @@ export const codeRoot = path.dirname(path.dirname(path.dirname(__dirname))); * etc. */ export function getAppRoot(): string { + if (process.env.APP_ROOT_PATH) { return process.env.APP_ROOT_PATH; } if (codeRoot.endsWith('/_build/core')) { return path.dirname(path.dirname(codeRoot)); } return codeRoot.endsWith('/_build') ? path.dirname(codeRoot) : codeRoot; }