rcedit.exe 失败,退出代码 193。wine:错误的 EXE 格式
rcedit.exe failed with exit code 193. wine: Bad EXE format
如果我尝试在我的 docker 容器中构建我的电子应用程序,我会收到以下错误消息。
build-electron_1 | rcedit.exe failed with exit code 193. wine: Bad EXE format for Z:\app\node_modules\rcedit\bin\rcedit.exe.
FROM node:10-stretch
RUN apt update
RUN apt install wine freetype
version: '3.1'
services:
build-electron:
build:
context: .
dockerfile: ./Dockerfile
volumes:
- ./:/app
working_dir: /app
command: "make install rebuild-node-sass build-package"
make install
只会触发 yarn (install)
而 make rebuild-node-sass
会启动 npm rebuild node-sass
"package-linux": "electron-packager ./build projectName --platform=linux --arch=x64 --overwrite --packageManager=yarn --prune=true --out=out/linux --asar --icon=build/favicon.ico",
"package-windows": "electron-packager ./build projectName --platform=win32 --arch=all --overwrite --packageManager=yarn --prune=true --out=out/windows --asar --icon=icon/icon.png.ico",
我现在的解决方案是:
FROM node:10
RUN dpkg --add-architecture i386 && apt-get update && apt-get install wine wine32 -y
RUN npm install electron-packager -g
VOLUME /electron
WORKDIR /electron
如果我尝试在我的 docker 容器中构建我的电子应用程序,我会收到以下错误消息。
build-electron_1 | rcedit.exe failed with exit code 193. wine: Bad EXE format for Z:\app\node_modules\rcedit\bin\rcedit.exe.
FROM node:10-stretch
RUN apt update
RUN apt install wine freetype
version: '3.1'
services:
build-electron:
build:
context: .
dockerfile: ./Dockerfile
volumes:
- ./:/app
working_dir: /app
command: "make install rebuild-node-sass build-package"
make install
只会触发 yarn (install)
而 make rebuild-node-sass
会启动 npm rebuild node-sass
"package-linux": "electron-packager ./build projectName --platform=linux --arch=x64 --overwrite --packageManager=yarn --prune=true --out=out/linux --asar --icon=build/favicon.ico",
"package-windows": "electron-packager ./build projectName --platform=win32 --arch=all --overwrite --packageManager=yarn --prune=true --out=out/windows --asar --icon=icon/icon.png.ico",
我现在的解决方案是:
FROM node:10
RUN dpkg --add-architecture i386 && apt-get update && apt-get install wine wine32 -y
RUN npm install electron-packager -g
VOLUME /electron
WORKDIR /electron