]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
pybind/mgr/dashboard/frontend: add NPM_CACHEDIR envvar, use in bwc
authorDan Mick <dan.mick@redhat.com>
Wed, 13 Aug 2025 19:16:45 +0000 (12:16 -0700)
committerJohn Mulligan <phlogistonjohn@asynchrono.us>
Fri, 22 Aug 2025 15:09:14 +0000 (11:09 -0400)
commit5777cc5dabcdf8c175668a047d35555733091e7c
treee101d32f528d7c815b93c3a77229b86358b05437
parentbc2a5652c7894692ee2bea99ea1003eb85c60161
pybind/mgr/dashboard/frontend: add NPM_CACHEDIR envvar, use in bwc

Add an optional NPM_CACHEDIR environment variable to serve as the
cache parameter for npm in the dashboard frontend build.  The idea
is to allow it to persist across builds so that we decrease the load
on registry.npmjs.org, which has been throttling our requests when
using build-with-container.py, and also hopefully improve the time
of the frontend npm operations.

build-with-container.py also grows a --npm-cache-path option to allow
setting it for container builds and passing the envvar to the build.

Fixes: https://tracker.ceph.com/issues/72298
Signed-off-by: Dan Mick <dan.mick@redhat.com>
(cherry picked from commit ad7e6117a9e99061a3ad7e03709dd31e34832966)
src/pybind/mgr/dashboard/frontend/CMakeLists.txt
src/script/build-with-container.py