【发布时间】:2020-03-22 16:30:28
【问题描述】:
我正在尝试通过 Windows 上的 Linux 在我的 Windows 10 机器上运行电子锻造应用程序(使用新的内置 Windows bash 功能)。
在运行electron-forge start 时,我收到了错误消息:
[1484:1126/222326.466455:FATAL:setuid_sandbox_host.cc(157)] 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 /mnt/c/.../node_modules/electron/dist/chrome-sandbox is owned by root and has mode 4755.
通过一些搜索,这个thread on the electron Github 清楚地表明这是设计使然,解决它的方法是在安装所有依赖项后以 root 用户身份运行 chmod。
我尝试执行此操作,并且该命令看起来有效(将 chmod 运行到 4755 时没有错误),但这并不能修复运行 electron-forge start - 我仍然收到相同的错误消息。我调查了一下,似乎这与允许 linux 子系统控制每个 this Microsoft thread 的权限的文件有关。
还有其他技巧可以让 electron forge 在 Windows 上与 bash 一起工作吗?
【问题讨论】:
标签: windows electron windows-subsystem-for-linux electron-forge