Need to downgrade your Ghost version?
This is the third in a series of posts featuring Protips, tips, tricks, hacks, and secrets provided by Our Team 🙊 — We want to share our top tips for the growing and thriving Linux community out there. Because sometimes you need a little help...
Have you ever been stuck after an update and hardly wished to downgrade...
Well here is a workaround. The thing is to trick the system to allow you to "update" to an older version.
We need to edit the update.js
file on the GhostCLI directly:
But first, you need to stop the service: ghost stop
then;
$ sudo nano /usr/lib/node_modules/ghost-cli/lib/commands/update.js
and add the latest known working version for ie.
actionVersion: "4.24.1"
###
##
#
);
}
const {force, zip, v1} = argv;
const version = argv.version ? `${argv.version}` : null;
const context = {
instance,
force,
activeVersion: instance.version, <<<
version,
zip,
v1
};
if (argv.rollback) {
if (!instance.previousVersion) {
throw new Error('No previous version found');
}
#
##
###
You should now be able to use the ghost start
command without any problem.😁
We hope we have been of some help!