]> source.dussan.org Git - sonarqube.git/commitdiff
Add yarn cache to global caching
authorPhilippe Perrin <philippe.perrin@sonarsource.com>
Fri, 10 Sep 2021 09:48:59 +0000 (11:48 +0200)
committersonartech <sonartech@sonarsource.com>
Mon, 13 Sep 2021 20:03:34 +0000 (20:03 +0000)
.cirrus.yml

index d91fc6cad3832aef23ca8510de3500ba2ba8c33a..76b60b271d7793410372f4924614c71fb687dd5e 100644 (file)
@@ -83,9 +83,9 @@ screenshots_on_failure_template: &REPORTS_JUNIT_SCREENSHOTS_ON_FAILURE_TEMPLATE
   screenshots_artifacts:
     path: "**/build/screenshots/**/*"
 
-node_modules_cache_template: &NODE_MODULES_CACHE_TEMPLATE
-  node_modules_cache:
-    folder: "**/node_modules"
+yarn_cache_template: &YARN_CACHE_TEMPLATE
+  yarn_cache:
+    folder: "~/.yarn/berry/cache"
     fingerprint_script: |
       cat \
         server/sonar-web/yarn.lock \
@@ -101,7 +101,7 @@ custom_clone_script_template: &CUSTOM_CLONE_SCRIPT_TEMPLATE
     git reset --hard $CIRRUS_CHANGE_IN_REPO
 
 build_task:
-  <<: *NODE_MODULES_CACHE_TEMPLATE
+  <<: *YARN_CACHE_TEMPLATE
   only_if: >-
            $CIRRUS_BRANCH !=~ "dogfood/.*" &&
            $CIRRUS_BRANCH != "public_master" &&
@@ -129,7 +129,7 @@ build_task:
 
 validate_task:
   <<: *ONLY_DEFAUT_DEPENDING_ON_BUILD_TEMPLATE
-  <<: *NODE_MODULES_CACHE_TEMPLATE
+  <<: *YARN_CACHE_TEMPLATE
   timeout_in: 90m
   gke_container:
     <<: *GKE_CONTAINER_TEMPLATE
@@ -144,7 +144,7 @@ validate_task:
 
 yarn_check-ci_task:
   <<: *ONLY_DEFAUT_DEPENDING_ON_BUILD_TEMPLATE
-  <<: *NODE_MODULES_CACHE_TEMPLATE
+  <<: *YARN_CACHE_TEMPLATE
   timeout_in: 90m
   gke_container:
     <<: *GKE_CONTAINER_TEMPLATE
@@ -520,7 +520,6 @@ upgd_mssql2019_task:
   on_failure:
     <<: *REPORTS_JUNIT_ON_FAILURE_TEMPLATE
 
-
 upgd_oracle12_task:
   <<: *ONLY_NIGHTLY_DEPENDING_ON_BUILD_TEMPLATE
   gke_container: