之前都是好好的,现在不管怎么构建,都是报这个错,求大佬支招
Step 1/10 : FROM node:latest
---> 2d840844f8e7
Step 2/10 : MAINTAINER YW
---> Using cache
---> 6631f9f14e00
Step 3/10 : RUN rm -rf /home/projects/tlt/web
---> Using cache
---> 60a540cb51ee
Step 4/10 : RUN mkdir -p /home/projects/tlt/web
---> Using cache
---> 68c0b5da1ed5
Step 5/10 : WORKDIR /home/projects/tlt/web
---> Using cache
---> 9303483f3de8
Step 6/10 : COPY . /home/projects/tlt/web
---> Using cache
---> 16261f0a871d
Step 7/10 : RUN npm install
---> Running in 8f26bddc17d6
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR! react@"^17.0.1" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.6.0" from [email protected]
npm ERR! node_modules/next
npm ERR! next@"^9.5.5" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /root/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2020-11-26T06_58_35_880Z-debug.log
ERROR: Service 'web' failed to build : The command '/bin/sh -c npm install' returned a non-zero code: 1
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…