If you’ve got a copy of Ghost running on a Raspberry Pi (or perhaps another ARM-based server) you’ll probably have noticed that it takes AAAAAGES to login.
To fix it, cd
into your Ghost directory:
cd /path/to/ghost
And run the following command:
sudo npm install bcrypt && sudo sed -i "s/require('bcryptjs')/require('bcrypt')/" core/server/models/user.js
Here’s what happens
sudo npm install bcrypt
installs the bcrypt library into your Ghost installation.&&
makes sure that command completed successfully before running the next onesudo sed -i "s/require('bcryptjs')/require('bcrypt')/" core/server/models/user.js
finds the stringrequire=('bcryptjs')
, which is what tells Ghost to use the bcryptjs library, and replaces it withrequire=('bcrypt')
, telling it to use your newly installed (faster) bcrypt library instead.
Enjoy your speedy new Ghost login!