Imports from Vanilla or PunBB formats into a discourse instance.
- Add forum2discourse gem to the discourse gemfile, and bundle install.
- Export the F2D_CONNECTION_STRING environment variable to point at the PunBB or Vanilla database. This uses datamapper-style connection strings. (http://datamapper.org/getting-started.html) - for example:
$ export F2D_CONNECTION_STRING=mysql://[email protected]:3306/database_name
- Run the relevant rake task within bundle exec
$ RAILS_ENV=production bundle exec rake forum2discourse:import_vanilla
$ RAILS_ENV=production bundle exec rake forum2discourse:import_punbb
In order for people to be able to use their existing user accounts, you will need to manually reset each user's password; passwords/authentication methods are not included.
To extend this library for another forum type:
- Create 'lib/tasks/import_(type).rb' by copying existing.
- Create 'lib/forum2discourse/models/(type)' to map the columns (see Vanilla models for an example)
- Each should respond to a to_discourse method that returns a Forum2Discourse::Models::Discourse::{Topic|Post|User|Category} instance
- Remember to define the relationships.
- Create an exporter in 'lib/forum2discourse/exporters'.
Forum2Discourse is copyright (c) 2013 Initforthe Ltd (www.initforthe.com) and Bytemark Hosting (www.bytemark.co.uk).
GNU GPL v2. See LICENSE.txt