재학습/오류

[Docker] nodejs 도커파일 빌드 시 에러

재이든 2022. 12. 26. 16:37
반응형
npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but package-lock.json was generated for lockfileVersion@2. I'll try to do my best with it!

> @nestjs/core@9.2.1 postinstall /usr/src/app/node_modules/@nestjs/core
> opencollective || exit 0

                           Thanks for installing nest 
                 Please consider donating to our open collective
                        to help us maintain this package.
                                         
                            Number of contributors: 0
                              Number of backers: 876
                             Annual budget: $186,382
                             Current balance: $14,128
                                         
             Become a partner: https://opencollective.com/nest/donate
                                         
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@2.3.2 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.3.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

 

 

 

읽어보니 대충 버전이안맞는다고 하는 것 같다.

따라서 찍어봤다

 

AWS EC 2 Node - 19.3

도커파일 Node - 9-alpine

 

아하..

EC2는 19.3버전인데 도커에는 9버전이구나..

 

그래서 도커파일도 19버전으로 바꿈.

 

그랬더니 문제없이 docker build완료!

 

 

 

반응형