Image optimization - sharp not installed

Hi, image resizing isn’t working for me. Just trying out Ghost and I really like it so far, but I’m not very familiar with Node. Thanks!

If you’re looking for help, please provide information about your environment. If you delete this template and don’t provide any information, your topic will be closed.

If you aren’t running the latest version of Ghost, the first thing we will ask you to do is update to the latest version of Ghost.

And

  • How was Ghost installed and configured? Installed following the instructions on this page: How To Install Ghost Headless Node.JS CMS Using RunCloud, I had to update Node to the latest version and tried to install snap using “sudo npm install sharp --unsafe-perm”
  • What Node version, database, OS & browser are you using? Node: v12.18.2, DB: 1:10.2.32+maria~bionic, OS: Ubuntu 18.04, Browser: Chrome
  • What errors or information do you see in the console?
    at processImmediate (internal/timers.js:458:21)\n at process.topLevelDomainCallback (domain.js:137:15)"},“msg”:“Sharp wasn’t installed”,“time”:“2020-07-09T18:57:47.375Z”,“v”:0}
  • What steps could someone else take to reproduce the issue you’re having?

I was able to figure it out myself - a failed attempt to update node after installing ghost caused all kinds of problems. I ended up doing an uninstall/reinstall and everything is working OK so far.

1 Like

I was able to solve this issue with some installation of missing packages:

See more details here: Ghost Blog - Solved Error Sharp wasn’t installed

I run into a similar issue, i manage to install sharp on the server through npm, however, when i then want to upload the image, ghost still states that sharp isn’t installed.

How can i make the installation apply to ghost?

I solved the issue by updating to ghost v5.42.2. from v5.42.1 with installing sharp through NPM before updating.

To anyone still not understanding what to do (I looked for the answer for a solid two days) you need to install, using the root user, sharp to the /var/www/ghost directory. So:

cd /var/www/ghost
npm install sharp

these two commands solved the issue for me, using the root user.