From a3ceec4b8117caa1acdcf91b0eb690dca3c0c994 Mon Sep 17 00:00:00 2001 From: Michael Date: Thu, 5 Sep 2024 02:26:18 +0300 Subject: [PATCH] fix env dirs --- .../src/internal/verdaccio/verdaccio-registry.ts | 13 +++++++------ tooling/build-env/src/utils/setup.ts | 2 +- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/tooling/build-env/src/internal/verdaccio/verdaccio-registry.ts b/tooling/build-env/src/internal/verdaccio/verdaccio-registry.ts index 9cb9ce1c..b5cddc01 100644 --- a/tooling/build-env/src/internal/verdaccio/verdaccio-registry.ts +++ b/tooling/build-env/src/internal/verdaccio/verdaccio-registry.ts @@ -5,6 +5,7 @@ import { logger } from '@nx/devkit'; import { objectToCliArgs } from '../utils/terminal-command'; import { executeProcess } from '../utils/execute-process'; import { uniquePort } from '../utils/utils'; +import {getEnvironmentsRoot} from "@org/build-env"; export function logInfo(msg: string) { info(msg, 'Verdaccio: '); @@ -87,12 +88,12 @@ export type StarVerdaccioOptions = VerdaccioExecuterOptions & export async function startVerdaccioServer({ targetName = 'start-verdaccio', - port = String(uniquePort()), - storage = join('tmp', targetName, 'storage'), - location = 'none', - clear = true, - verbose = true, - projectName, + projectName, + port = String(uniquePort()), + storage = join(getEnvironmentsRoot(projectName), targetName, 'storage'), + location = 'none', + clear = true, + verbose = true, ...opt }: StarVerdaccioOptions): Promise { let startDetected = false; diff --git a/tooling/build-env/src/utils/setup.ts b/tooling/build-env/src/utils/setup.ts index 8671cf13..0f2ee10d 100644 --- a/tooling/build-env/src/utils/setup.ts +++ b/tooling/build-env/src/utils/setup.ts @@ -4,7 +4,7 @@ import { DEFAULT_ENVIRONMENTS_OUTPUT_DIR } from '../internal/constants'; export function getEnvironmentsRoot( environmentsDir: string = DEFAULT_ENVIRONMENTS_OUTPUT_DIR ) { - return join('tmp', environmentsDir); + return environmentsDir; } /**