How do you install an earlier version of Discourse?

AI-generated summary

The discussion addresses how to install an earlier version of Discourse. johnmuhl explains that the version key in the app.yml file can be used to specify a particular version, referencing the available tags on GitHub. AstonJ seeks help identifying the version from a backup, noting the meta.json file shows a date-based version. zogstrip clarifies this is a Rails migration version, not a Discourse release. AstonJ attempts to restore a backup but finds it not appearing in the control panel. riking reassures that older backups can be restored to newer versions, and zogstrip confirms this is generally possible unless plugins require specific migrations. AstonJ plans to retry the process, noting the backup is present in the shared/standalone/backups/default directory.

I only have a backup of an older version and its recommend that both the install and backup are the same version - but how can I specify a specific version of Discourse on install?.

There should be a version key in your app.yml file.

  #version: tests-passed

Remove the # and change test-passed to the version you want to use; e.g. v1.3.4. Tags · discourse/discourse · GitHub shows the available version strings.

Thanks @johnmuhl, do you know how I can find the version from my backup?

In meta.json (in the backup) it says:

{"source":"discourse","version":20150728004647}

That’s the version of the database in rails parlance (ie: the latest migration that was run). Looks like it’s from 2015/07/28.

Yeah that’s the date of the backup too, however looking at Releases · discourse/discourse · GitHub the closest version seems to be Version v1.4.0.beta6 but I have restored that and when I go to upload a backup it says it has uploaded but it doesn’t show in the list of backups. Maybe I need to wipe everything and start again : /

You should be able to restore any older version to the current version - we keep all the info necessary to upgrade the database.

Do you mean I can install a new version of Discourse and then upload an older backup (of an older version) and restore it?

Exactly. Unless you’ve installed a plugin that requires a migration, you can restore old backups just fine :wink:

Ok thanks, I’ll try again.

Though not sure why they backup isn’t showing in the control panel (it’s there in shared/standalone/backups/default).