未找到Circle CI Workflows存档缓存

问题描述 投票:1回答:1

我为Circle CI创建了配置:

version: 2
jobs:
  dependencies:
    docker:
      - image: circleci/node:10
    steps:
      - checkout
      - restore_cache:
          keys:
            - v2-dependencies-{{ checksum "package.json" }}
            - v2-dependencies-
      - run: yarn install
      - save_cache:
          paths:
            - node_modules
            - /root/.cache/Cypress
          key: v2-dependencies-{{ checksum "package.json" }}
  test:
    docker:
      - image: cypress/base:10
    steps:
      - checkout
      - restore_cache:
          keys:
            - v2-dependencies-{{ checksum "package.json" }}
            - v2-dependencies-
      - run: ls -la
      - run: yarn cy:cache
      - run: yarn cy:ci
      - run: yarn report:coverage

workflows:
  version: 2
  build:
    jobs:
      - dependencies
      - test:
          requires:
          - dependencies

我期望:它应该首先安装所有依赖项,并将其缓存以在以后的工作中使用这些依赖项(例如,用于测试)]

会发生什么:它安装所有依赖项并对其进行缓存,但是在test作业中,它取消存档缓存,但不在测试运行所在的目录中。

ls-la的输出]:

enter image description here

cypress命令的输出:enter image description here

我做错了。如何正确使用上一个作业的缓存?

我为Circle CI创建了配置:版本:2作业:依赖项:docker:-图像:circleci / node:10步骤:-检出-restore_cache:密钥:-v2 -...

github continuous-integration circleci circleci-2.0
1个回答
0
投票
您应使用

相同图像

© www.soinside.com 2019 - 2024. All rights reserved.