]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cmake: s/--prod/--configuration=production/ 46143/head
authorKefu Chai <tchaikov@gmail.com>
Wed, 4 May 2022 11:21:20 +0000 (19:21 +0800)
committerKefu Chai <tchaikov@gmail.com>
Wed, 4 May 2022 15:34:55 +0000 (23:34 +0800)
to silence the warning from Angular 12.0 and up, which complains like:

Option "--prod" is deprecated: Use "--configuration production" instead

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
make-dist
src/pybind/mgr/dashboard/ci/cephadm/start-cluster.sh
src/pybind/mgr/dashboard/frontend/CMakeLists.txt
src/pybind/mgr/dashboard/run-frontend-unittests.sh

index df1d88ae3e307035b147357bfadc3bf9a66423a7..ffb3b2f60852a07ad7d10151c1e720756683108a 100755 (executable)
--- a/make-dist
+++ b/make-dist
@@ -138,9 +138,9 @@ build_dashboard_frontend() {
   . $TEMP_DIR/bin/activate
   NG_CLI_ANALYTICS=false timeout 1h npm ci
   echo "Building ceph-dashboard frontend with build:localize script";
-  # we need to use "--" because so that "--prod" survives accross all
-  # scripts redirections inside package.json
-  npm run build:localize -- --prod
+  # we need to use "--" because so that "--configuration production"
+  # survives accross all scripts redirections inside package.json
+  npm run build:localize -- --configuration production
   deactivate
   cd $CURR_DIR
   rm -rf $TEMP_DIR
index 26fbd8a7c4b699f194280d2075e845ad203430c3..b69e28e41ebe6cc182f2c27660d0570d3fe84bc9 100755 (executable)
@@ -64,7 +64,7 @@ if [[ -n "$JENKINS_HOME" ]]; then
     npm cache clean --force
 fi
 npm ci
-FRONTEND_BUILD_OPTS='-- --prod'
+FRONTEND_BUILD_OPTS='-- --configuration production'
 if [[ -n "${DEV_MODE}" ]]; then
     FRONTEND_BUILD_OPTS+=' --deleteOutputPath=false --watch'
 fi
index cb76722bac1a8fefb107a3e021e77fd529b0b59b..f92c34791c07024f5accae280a4590d6ee2e54c3 100644 (file)
@@ -109,7 +109,7 @@ execute_process(
 set(frontend_dist_dir "${CMAKE_CURRENT_BINARY_DIR}/dist")
 set(npm_args "--output-path ${frontend_dist_dir}")
 if(NOT CMAKE_BUILD_TYPE STREQUAL Debug)
-  string(APPEND npm_args " --prod --progress=false")
+  string(APPEND npm_args " --configuration=production --progress=false")
 else()
   string(APPEND npm_args " --progress=false")
 endif()
index 997b86bbf679b8a629810ae63a6cea758e1b7f5d..0ef10fadd4958b6a6f1ddd6bd8ac9f5a6ee7cfef 100755 (executable)
@@ -11,7 +11,7 @@ if [ `uname` != "FreeBSD" ]; then
 fi
 
 # Build
-npm run build -- --prod --progress=false || failed=true
+npm run build -- --configuration=production --progress=false || failed=true
 
 # Unit Tests
 npm run test:ci || failed=true