Description
按照源码中的编译说明,先编译的主程序ElectronJS,
CentOS上下载安装了最新的chrome ,命令google-chrome-stable -version,显示Google Chrome 119.0.6045.159
也按照说明将/opt/google/chrome/,全部copy到了ElectronJS下,并重命名为chrome_linux64。
也下载了对应版本的chromedriver_linux64,放到了chrome_linux64下
npm install和npm install @electron-forge/cli -g 两个命令也都执行安装成功了(换了taobao源,npm安装过程中提示需要python3,也安装了python3.8.15,安装后命令执行成功)
但最后执行npm run start_direct,总是报错,
用root用户执行会报:
easy-spider@0.3.5 start_direct
electron .
[1120/000559.944607:FATAL:electron_main_delegate.cc(294)] Running as root without --no-sandbox is not supported. See https://crbug.com/638180.
/mysofts/crawler/EasySpider-0.3.5-c/ElectronJS/node_modules/electron/dist/electron exited with signal SIGTRAP
切换普通用户后执行报错:
easy-spider@0.3.5 start_direct
electron .
[13824:1120/000541.120354:FATAL:setuid_sandbox_host.cc(158)] The SUID sandbox helper binary was found, but is not configured correctly. Rather than run without sandboxing I'm aborting now. You need to make sure that /mysofts/crawler/EasySpider-0.3.5-c/ElectronJS/node_modules/electron/dist/chrome-sandbox is owned by root and has mode 4755.
/mysofts/crawler/EasySpider-0.3.5-c/ElectronJS/node_modules/electron/dist/electron exited with signal SIGTRAP
麻烦帮忙看看,是哪里出了问题?万分感谢!!!