-
Notifications
You must be signed in to change notification settings - Fork 580
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Docs to support cloud storage for Cloud exports #6545
Merged
Changes from 4 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
9465300
Docs to support cloud storage for Cloud exports
cwarnermm 738feca
Updates based on feedback
cwarnermm b023b5c
Added new mmctl export command
cwarnermm bf7f10a
Broken link fix
cwarnermm 60a37ca
refactoring of the cloud export part
JulienTant 3e0b0d6
Merge branch 'master' into mm-53454
cwarnermm eced21e
Incorporated review feedback
cwarnermm aa8cc6f
Merge branch 'master' into mm-53454
cwarnermm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,21 +14,23 @@ Migrate from Cloud to self-hosted | |
You can migrate your Cloud workspace data to a self-hosted deployment at any time. | ||
|
||
How does the process work? | ||
-------------------------- | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
Before you export and migrate your data, you must `install Mattermost </guides/deployment.html#install-guides>`_ on the server you’ll be using to run Mattermost. The migration is done using the mmctl CLI tool, which is a remote CLI tool for Mattermost that's installed locally and uses the Mattermost API. mmctl is pre-installed. | ||
|
||
The `mmctl usage notes </manage/mmctl-command-line-tool.html#mmctl-usage-notes>`_ provide some additional context and information which you can reference before and during the process. | ||
|
||
You'll be using the `mmctl export </manage/mmctl-command-line-tool.html#mmctl-export>`__ commands to export your Cloud data for channels, messages, users, etc. The export file is downloaded to a location specified in the export commands. Once the export is complete, you'll import the data into your self-hosted instance. | ||
You'll be using the `mmctl export </manage/mmctl-command-line-tool.html#mmctl-export>`__ commands to export your Cloud data for channels, messages, users, etc. The export file is downloaded to a location specified in the export commands. Once the export is complete, you'll import the data into your self-hosted instance. | ||
|
||
You can export the data to an Amazon S3 cloud storage location in cases where an export is quite large and challenging to download from the Mattermost server. See the `create the export <#create-the-export>`__ section below for details. | ||
|
||
.. note:: | ||
|
||
Prior to migrating your data from Cloud, please ensure you have the appropriate permissions within your organization to carry out the data export which may contain sensitive information. Mattermost is not liable for any actions taken after the data export. | ||
|
||
Moreover, the export process doesn’t include integrations or any custom data. Other aspects of your instance, such as specific security settings and requirements, are also not included. For assistance with migrating additional data and settings, see our support options: https://mattermost.com/support/. | ||
|
||
Once mmctl is installed, we can generate the export from the source instance. | ||
Once mmctl is authenticated, you can generate the export from the source instance. | ||
|
||
Authenticate | ||
------------ | ||
|
@@ -44,43 +46,66 @@ You'll be prompted for a username (use your admin user), password, and for a con | |
Create the export | ||
----------------- | ||
|
||
Once you're logged in, run: | ||
Once you're logged in, run the mmctl export command based on your export storage location: | ||
|
||
.. code:: | ||
.. tabs:: | ||
|
||
mmctl export create | ||
.. tab:: Local export | ||
|
||
This will create a full export of the server, and include attached files. Append ``--no-attachments`` if you do not wish to export attached files from your instance. This process can take some time, so ``mmctl`` will return immediately, and the job will run in the background on the Mattermost instance until the export is fully created. If successful, the command will immediately output a job ID, like this: | ||
Run the following mmctl command: | ||
|
||
.. code:: | ||
.. code:: | ||
|
||
mmctl export create | ||
|
||
Export process job successfully created, ID: yfrr9ku5i7fjubeshs1ksrknzc | ||
Running this command creates a full export of the server, including attached files. Append ``--no-attachments`` if you do not wish to export attached files from your instance. This process can take some time, so ``mmctl`` will return immediately, and the job will run in the background on the Mattermost instance until the export is fully created. If successful, the command will immediately output a job ID, like this: | ||
|
||
While the job is running, its status can be checked using the ID that was provided when it was created, and when it's done the output will look similar to this: | ||
.. code:: | ||
|
||
.. code:: | ||
Export process job successfully created, ID: yfrr9ku5i7fjubeshs1ksrknzc | ||
|
||
mmctl export job show yfrr9ku5i7fjubeshs1ksrknzc | ||
ID: yfrr9ku5i7fjubeshs1ksrknzc | ||
Status: success | ||
Created: 2021-11-03 10:44:13 -0500 CDT | ||
Started: 2021-11-03 10:44:23 -0500 CDT | ||
While the job is running, its status can be checked using the ID that was provided when it was created, and when it's done the output will look similar to this: | ||
|
||
Download the export | ||
------------------- | ||
.. code:: | ||
|
||
Once the status is ``success``, you can download the export onto your local machine. First, discover the name of the completed export file with ``mmctl export list``: | ||
mmctl export job show yfrr9ku5i7fjubeshs1ksrknzc | ||
ID: yfrr9ku5i7fjubeshs1ksrknzc | ||
Status: success | ||
Created: 2021-11-03 10:44:13 -0500 CDT | ||
Started: 2021-11-03 10:44:23 -0500 CDT | ||
|
||
.. code:: | ||
Once the status is ``success``, download the export onto your local machine. First, discover the name of the completed export file with ``mmctl export list``: | ||
|
||
mmctl export list | ||
r3kcj8yuwbramdt714doafi3oo_export.zip | ||
.. code:: | ||
|
||
This will show all of the exports on the server, so be sure to download the latest one and to delete it when you're done to save storage. Download the file with a command like the following, but with the filename of the export on your server: | ||
mmctl export list | ||
r3kcj8yuwbramdt714doafi3oo_export.zip | ||
|
||
.. code:: | ||
This will show all of the exports on the server, so be sure to download the latest one and to delete it when you're done to save storage. Download the file with a command like the following, but with the filename of the export on your server: | ||
|
||
.. code:: | ||
|
||
mmctl export download r3kcj8yuwbramdt714doafi3oo_export.zip | ||
|
||
.. tab:: Cloud export | ||
|
||
You can specify a dedicated cloud storage location for exports that's separate from file uploads. This option can be useful in cases where an export is quite large and challenging to download from the Mattermost server. | ||
|
||
Run the following mmctl command: | ||
|
||
.. code:: | ||
|
||
mmctl export generate-presigned-url [exportname] | ||
|
||
Running this command creates a full export of the server, including attached files, in a unique Amazon S3 cloud storage location, and generates a pre-signed URL for the export file. | ||
|
||
This process can take some time, so ``mmctl`` will return immediately, and the job will run in the background on the Mattermost instance until the export is fully created. If successful, the command will immediately output a job ID, like this: | ||
|
||
.. code:: | ||
|
||
Export process job successfully created, ID: yfrr9ku5i7fjubeshs1ksrknzc | ||
|
||
mmctl export download r3kcj8yuwbramdt714doafi3oo_export.zip | ||
From your Mattermost Cloud web instance, retrieve the file download link to the export by using the Mattermost slash command ``/exportlink [job-id|zip file|latest]``. Use the ``latest`` option to automatically pull the latest export available, or specify the download link by ``job-id`` or ``zip file``. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We need to be explicit as to where to run the slash command. Recommend we explain "hopping" over to the webapp to run the slash command and download the export. |
||
|
||
Upload the export to the new server | ||
----------------------------------- | ||
|
@@ -166,7 +191,7 @@ If you’re using plugins that aren’t listed on the Marketplace, they won’t | |
The migration only includes data from Channels. No Boards or Playbooks data is exported. | ||
|
||
Migration process | ||
^^^^^^^^^^^^^^^^^ | ||
~~~~~~~~~~~~~~~~~ | ||
|
||
**Export from your self-hosted instance** | ||
|
||
|
@@ -203,7 +228,7 @@ The completed file will be downloaded to your desktop as a ``.zip`` file. | |
The Support team will provide you with S3 credentials so you can upload the exported file. Once you’ve uploaded the file, please contact the Support team and let them know. | ||
|
||
Create a new workspace on the Mattermost Cloud | ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
In the meantime, you can log into Mattermost Cloud with your Mattermost credentials and create a Cloud workspace. | ||
|
||
|
@@ -212,17 +237,17 @@ In the meantime, you can log into Mattermost Cloud with your Mattermost credenti | |
Do not create any users in your Mattermost Cloud instance as the migration process performs this task for you. | ||
|
||
Importing your data into your Mattermost Cloud instance | ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
Once the export upload to the provided S3 bucket is complete and you’ve shared your Mattermost Cloud instance name/URL, Support can begin the import step. | ||
|
||
Depending on the size of the export this process can take some time. Support will contact you as soon as the import is complete. During this time it is highly recommended you do not use your Mattermost Cloud instance. | ||
|
||
Start using your Mattermost Cloud instance | ||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
When the export is complete, you can log into your Cloud instance and can invite your users to log in. | ||
|
||
.. note:: | ||
|
||
It’s recommended that you keep your self-hosted Mattermost server until you’ve been using your Cloud instance for a while and all is verified as is as expected. | ||
We recommend that you keep your self-hosted Mattermost server until you’ve been using your Cloud instance for a while and all is verified as is as expected. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add a section similar to that on the local export tab explaining how to show export job lists and how to check when the job is ready