Jenkins 部署報錯 error fsevents@2.3.2: The platform "linux" is incompatible with this module


今天用jenkins部署項目時,部署失敗

查看控制台輸出代碼發現如下錯誤

原因

fsevents 只能在 macOS 下安裝,無法在 linux 系統安裝,linux 下會跳過 fsevents 模塊,也不會安裝 fsevents 依賴的模塊,yarn 沒有設置忽略


解決方法

1、於是回到項目輸入命令:

yarn config set ignore-engines true

2、刪除 yarn.lock 文件

3、輸入命令 yarn install 重新安裝

4、重新部署成功

這是會發現控制台的信息

error fsevents@2.3.2: The platform "linux" is incompatible with this module
// 會變成
info fsevents@2.3.2: The platform "linux" is incompatible with this module


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM