Yuki Takei 1 год назад
Родитель
Сommit
fe42f9540f

+ 12 - 12
.github/workflows/ci-app.yml

@@ -44,9 +44,9 @@ jobs:
           path: |
             **/node_modules
             !**/node_modules/.cache/turbo
-          key: node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+          key: node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
           restore-keys: |
-            node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-
+            node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-
             node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-
 
       - name: Cache/Restore dist
@@ -56,9 +56,9 @@ jobs:
             **/.turbo
             **/dist
             **/node_modules/.cache/turbo
-          key: dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-${{ github.sha }}
+          key: dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-${{ github.sha }}
           restore-keys: |
-            dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-
+            dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-
             dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-
 
       - name: Install dependencies
@@ -110,9 +110,9 @@ jobs:
           path: |
             **/node_modules
             !**/node_modules/.cache/turbo
-          key: node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+          key: node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
           restore-keys: |
-            node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-
+            node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-
             node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-
 
       - name: Cache/Restore dist
@@ -122,9 +122,9 @@ jobs:
             **/.turbo
             **/dist
             **/node_modules/.cache/turbo
-          key: dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-${{ github.sha }}
+          key: dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-${{ github.sha }}
           restore-keys: |
-            dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-
+            dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-
             dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-
 
       - name: Install dependencies
@@ -186,9 +186,9 @@ jobs:
           path: |
             **/node_modules
             !**/node_modules/.cache/turbo
-          key: node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+          key: node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
           restore-keys: |
-            node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-
+            node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-
             node_modules-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-
 
       - name: Cache/Restore dist
@@ -198,9 +198,9 @@ jobs:
             **/.turbo
             **/dist
             **/node_modules/.cache/turbo
-          key: dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-${{ github.sha }}
+          key: dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-${{ github.sha }}
           restore-keys: |
-            dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.ref_name }}-
+            dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-${{ github.head_ref || github.ref_name }}-
             dist-ci-app-${{ runner.OS }}-node${{ matrix.node-version }}-
 
       - name: Install dependencies

+ 10 - 10
.github/workflows/reusable-app-prod.yml

@@ -53,9 +53,9 @@ jobs:
         path: |
           **/node_modules
           !**/node_modules/.cache/turbo
-        key: node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+        key: node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
         restore-keys: |
-          node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-
+          node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-
           node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-
 
     - name: Install dependencies
@@ -71,9 +71,9 @@ jobs:
           **/dist
           **/node_modules/.cache/turbo
           ${{ github.workspace }}/apps/app/.next
-        key: dist-app-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-${{ github.sha }}
+        key: dist-app-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-${{ github.sha }}
         restore-keys: |
-          dist-app-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-
+          dist-app-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-
           dist-app-prod-${{ runner.OS }}-node${{ inputs.node-version }}-
 
     - name: Build
@@ -166,9 +166,9 @@ jobs:
         path: |
           **/node_modules
         # shared key with build-prod
-        key: node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+        key: node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
         restore-keys: |
-          node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-
+          node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-
           node_modules-app-build-prod-${{ runner.OS }}-node${{ inputs.node-version }}-
 
     - name: Install dependencies
@@ -258,9 +258,9 @@ jobs:
         path: |
           **/node_modules
         # shared key with ci-app.yml
-        key: node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+        key: node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
         restore-keys: |
-          node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-
+          node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-
           node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-
 
     - name: Cache/Restore Cypress files
@@ -387,9 +387,9 @@ jobs:
         path: |
           **/node_modules
         # shared key with ci-app.yml
-        key: node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+        key: node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
         restore-keys: |
-          node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-
+          node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-
           node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-
 
     - name: Install dependencies

+ 2 - 2
.github/workflows/reusable-app-reg-suit.yml

@@ -66,9 +66,9 @@ jobs:
         path: |
           **/node_modules
         # shared key with ci-app.yml
-        key: node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
+        key: node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-${{ hashFiles('**/yarn.lock') }}
         restore-keys: |
-          node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.ref_name }}-
+          node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-${{ github.head_ref || github.ref_name }}-
           node_modules-ci-app-${{ runner.OS }}-node${{ inputs.node-version }}-
 
     - name: Install dependencies