GithubHelp home page GithubHelp logo

lexbritvin / mattermost-etl-rocketchat Goto Github PK

View Code? Open in Web Editor NEW

This project forked from brightscout/mattermost-etl

7.0 1.0 1.0 177 KB

An ETL framework to migrate data to Mattermost from RocketChat

License: MIT License

JavaScript 100.00%

mattermost-etl-rocketchat's Introduction

Mattermost ETL CircleCI Code Climate Test Coverage

An ETL framework to migrate data from Jabber to Mattermost. This utility exports data from a source Jabber database and generates a Mattermost Bulk Loading import file. Eventually, we'll enhance this project to support migrations from other messaging sources.

Install

  1. Install Node.js Version 6.11.0 LTS or greater

  2. Clone this repo
    $ git clone https://github.com/Brightscout/mattermost-etl

  3. Install dependencies
    $ cd mattermost-etl
    $ npm install

  4. Run tests
    $ npm test

Configure

  1. Copy the example config file to config.js
    $ cp context/config.example.js context/config.js

  2. Modify the values in context/config.js for the source, target, and team properties.

Export

  1. Execute the ETL exporter
    $ npm start

  2. Inspect the output file, data.json, or whatever you set as the target filename. Ensure the results are as expected.

Export RocketChat

Export supports the following entities:

  1. Users and roles. Only global roles are supported
  2. Custom emoji. File storage: FileSystem and GridFS
  3. Channels
  4. Direct channels
  5. RocketChat Discussions (subchannels) are partially supported, see below
  6. User uploads. File storage: FileSystem and GridFS
  7. Posts with per user flag. Channel pins are not supported by import specification.
  8. Replies and Reactions

RocketChat exporting

  1. Copy the example config file to config.js

    cp context/config.example.rocketchat.js context/config.js
    
  2. Prepare your source and target configuration

    1. Set source.uploadsPath for file uploads (user avatars and file uploads)
    2. Set source.customEmojiPath for custom emojies
    3. Set target.filesPath for MM output directory
  3. If you have LDAP enabled, Community version of Mattermost doesn't support LDAP. If you have Community version, consider configuring ldap mapping to gitlab or disable it to use default login.

    Specify it in config.js. Set ldap_auth_service to map ldap to a MM login service. If it's GitLab, configure gitlab with host and token registered in Gitlab with User access. It is used for id mapping, without it MM won't import the users and throw an error.
    Before migrating to MM, ensure you have Gitlab integration enabled in MM and all users are present in Gitlab.

  4. If you used RocketChat discussions, they will migrate in separate channels with random names. You can merge discussions in parent channel with mergeDiscussionIntoParent

  5. Global channel in Rocket Chat us General and in Mattermost - Town Square. To have only 1 global channel, the configuration provides default example in channels.map. You can specify migration for other channels as well.

  6. Run migrate script with npm run start:rocketchat

  7. Configure Mattermost (DB and Gitlab integration) before running the migration

  8. Run the migration in MM

Import

  1. Run the Mattermost bulk loading command as explained here

Made with โ™ฅ by Brightscout

mattermost-etl-rocketchat's People

Contributors

lexbritvin avatar lkdbns avatar mkdbns avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

steve-todorov

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.