Browse Source

chore: Update CI workflows to latest Node versions

Michael Bromley 2 years ago
parent
commit
dfc09a81a2
2 changed files with 2 additions and 41 deletions
  1. 1 25
      .github/workflows/build_and_test.yml
  2. 1 16
      .github/workflows/publish_and_install.yml

+ 1 - 25
.github/workflows/build_and_test.yml

@@ -14,7 +14,7 @@ on:
       - minor
       - minor
 env:
 env:
   CI: true
   CI: true
-  node: 18.x
+  node: 20.x
 jobs:
 jobs:
   build:
   build:
     name: build
     name: build
@@ -25,15 +25,7 @@ jobs:
       uses: actions/setup-node@v3
       uses: actions/setup-node@v3
       with:
       with:
         node-version: ${{ env.node }}
         node-version: ${{ env.node }}
-#    - uses: actions/cache@v3
-#      id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
-#      with:
-#        path: '**/node_modules'
-#        key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
-#        restore-keys: |
-#          ${{ runner.os }}-yarn-
     - name: Yarn install
     - name: Yarn install
-#      if: steps.yarn-cache.outputs.cache-hit != 'true'
       run: yarn install
       run: yarn install
     - name: Build
     - name: Build
       run: yarn build
       run: yarn build
@@ -46,15 +38,7 @@ jobs:
         uses: actions/setup-node@v3
         uses: actions/setup-node@v3
         with:
         with:
           node-version: ${{ env.node }}
           node-version: ${{ env.node }}
-#      - uses: actions/cache@v3
-#        id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
-#        with:
-#          path: '**/node_modules'
-#          key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
-#          restore-keys: |
-#            ${{ runner.os }}-yarn-
       - name: Yarn install
       - name: Yarn install
-#        if: steps.yarn-cache.outputs.cache-hit != 'true'
         run: yarn install --prefer-offline
         run: yarn install --prefer-offline
       - name: Build
       - name: Build
         run: yarn lerna run ci
         run: yarn lerna run ci
@@ -113,15 +97,7 @@ jobs:
         uses: actions/setup-node@v3
         uses: actions/setup-node@v3
         with:
         with:
           node-version: ${{ env.node }}
           node-version: ${{ env.node }}
-#      - uses: actions/cache@v3
-#        id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
-#        with:
-#          path: '**/node_modules'
-#          key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
-#          restore-keys: |
-#            ${{ runner.os }}-yarn-
       - name: Yarn install
       - name: Yarn install
-#        if: steps.yarn-cache.outputs.cache-hit != 'true'
         run: yarn install --prefer-offline
         run: yarn install --prefer-offline
       - name: Build
       - name: Build
         run: yarn lerna run ci
         run: yarn lerna run ci

+ 1 - 16
.github/workflows/publish_and_install.yml

@@ -20,11 +20,7 @@ jobs:
     strategy:
     strategy:
       matrix:
       matrix:
         os: [ubuntu-latest, windows-latest, macos-latest]
         os: [ubuntu-latest, windows-latest, macos-latest]
-        # Temporarily disabled Node v18 because of this issue:
-        # https://github.com/vendure-ecommerce/vendure/actions/runs/5200017548/jobs/9378196658#step:4:48
-        # which is related to our Verdaccio setup. Will need some investigation.
-        #node-version: [16.x, 18.x]
-        node-version: [16.x]
+        node-version: [18.x, 20.x]
       fail-fast: false
       fail-fast: false
     steps:
     steps:
     - uses: actions/checkout@v3
     - uses: actions/checkout@v3
@@ -46,18 +42,7 @@ jobs:
     - name: Windows dependencies
     - name: Windows dependencies
       if: matrix.os == 'windows-latest'
       if: matrix.os == 'windows-latest'
       run: npm install -g @angular/cli
       run: npm install -g @angular/cli
-#    - name: Get yarn cache directory path
-#      id: yarn-cache-dir-path
-#      run: echo "::set-output name=dir::$(yarn cache dir)"
-#    - uses: actions/cache@v3
-#      id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
-#      with:
-#        path: '**/node_modules'
-#        key: ${{ runner.os }}-${{ matrix.node-version }}-yarn-${{ hashFiles('**/yarn.lock') }}
-#        restore-keys: |
-#          ${{ runner.os }}-${{ matrix.node-version }}-yarn-
     - name: Yarn install
     - name: Yarn install
-#      if: steps.yarn-cache.outputs.cache-hit != 'true'
       run: |
       run: |
         yarn config set unsafe-perm true
         yarn config set unsafe-perm true
         yarn install --network-timeout 1000000 --prefer-offline
         yarn install --network-timeout 1000000 --prefer-offline