serenity
serenity copied to clipboard
Error while using docker image and custom dependency(sharp) for my plugin
<07-27-2024 08:49:03> [Plugins] [Info] Installing dependencies for [email protected]...
<07-27-2024 08:49:09> [Plugins] [Info] Building typescript files for [email protected]...
<07-27-2024 08:49:11> [Plugins] [Error] Failed to load plugin! Serenity Error: Could not load the "sharp" module using the linux-x64 runtime
Possible solutions:
- Ensure optional dependencies can be installed:
npm install --include=optional sharp
yarn add sharp --ignore-engines
- Ensure your package manager supports multi-platform installation:
See https://sharp.pixelplumbing.com/install#cross-platform
- Add platform-specific dependencies:
npm install --os=linux --cpu=x64 sharp
- Consult the installation documentation:
See https://sharp.pixelplumbing.com/install
at Object.<anonymous> (/root/plugins/Serenity/node_modules/sharp/lib/sharp.js:114:9)
at Module._compile (node:internal/modules/cjs/loader:1356:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1414:10)
at Object.require.extensions.<computed> [as .js] (/root/node_modules/ts-node/src/index.ts:1608:43)
at Module.load (node:internal/modules/cjs/loader:1197:32)
at Function.Module._load (node:internal/modules/cjs/loader:1013:12)
at Module.require (node:internal/modules/cjs/loader:1225:19)
at require (node:internal/modules/helpers:177:18)
at Object.<anonymous> (/root/plugins/Serenity/node_modules/sharp/lib/constructor.js:10:1)
at Module._compile (node:internal/modules/cjs/loader:1356:14)
<07-27-2024 08:49:11> [Plugins] [Success] Successfully initialized a total of 0 plugin!
Hello, how can I fix this issue?