Skip to content

Commit d54f98c

Browse files
authored
Merge pull request #8495 from jberkus/slackbackup
Add backup instructions for private channels from Slack
2 parents 2a3acd2 + 63332b6 commit d54f98c

14 files changed

+141
-1
lines changed

communication/slack-backup/README.md

Lines changed: 140 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,140 @@
1+
# HOWTO Backup Private Channels and DMs from Slack
2+
3+
To back up private channels, and direct message chains, from Slack we currently recommend [slackdump](https://github.com/rusq/slackdump).
4+
5+
It is a relatively easy to use commandline tool to backup your channels and DMs and store the data locally. No fees or 3rd-party online storage is involved, making it suitable for even confidential private channels.
6+
7+
## Preparing to Export
8+
9+
Decide which member of your private channel will archive it. This should be someone who is prepared to follow up before the June 20th deadline, and can easily install and use Slackdump. You should also give some thought as to [what you will do with the archive files](#what-should-i-do-with-the-backup-files) afterwards, although the critical thing is to make sure that someone makes a copy before the deadline.
10+
11+
## Installing Slackdump
12+
13+
Slackdump is supporting various platforms. You can find the latest release [here](https://github.com/rusq/slackdump/releases/tag/v3.1.4). The installation instructions below are taken from [the official instructions of the project](https://github.com/rusq/slackdump/?tab=readme-ov-file#installation-and-quickstart) with a few additions based on our experience.
14+
15+
### MacOS
16+
17+
The easiest way to install on a Mac is using Brew:
18+
19+
```
20+
brew install slackdump
21+
```
22+
23+
Some Linux distros also support Brew, which can be an easy way to install there as well.
24+
25+
### Other OSes
26+
27+
On other Operating Systems, please follow these steps:
28+
29+
1. Download the latest release for your operating system from the [releases] page.
30+
1. Unpack the archive to any directory.
31+
1. Run the `./slackdump` or `slackdump.exe` executable (see note below).
32+
33+
[releases]: https://github.com/rusq/slackdump/releases/
34+
35+
> [!NOTE]
36+
> On Windows and macOS you may be presented with "Unknown developer" window.
37+
> The reason for this is that the executable hasn't been signed by
38+
> the developer certificate.
39+
40+
To work around this:
41+
42+
- **on Windows**: click "more information", and press "Run
43+
Anyway" button.
44+
- **on macOS** 14 Sonoma and prior: open the folder in Finder, hold Option
45+
and double click the executable, choose Run.
46+
- **on macOS** 15 Sequoia and later: start the slackdump, OS will show the
47+
"Unknown developer" window, then go to System Preferences -> Security and
48+
Privacy -> General, and press "Open Anyway" button.
49+
50+
## Basic Slackdump Navigation
51+
52+
Most of the Slackdump CLI uses this basic navigation:
53+
54+
* Use TAB to navigate between fields
55+
* Use up and down arrows to navigate between items on a list
56+
* Use ENTER to select an option
57+
* Use ESC to go back to a higher-level menu
58+
59+
## Step by Step Walkthrough
60+
61+
Use the wizard to get started:
62+
63+
![screenshot of starting the wizard](runwizard.jpeg)
64+
65+
Choose "Workspace", and then "New" to authenticate for the Kubernetes Slack. You will be prompted to choose a method for logging in.
66+
67+
![screenshot of login choices menu](login.jpeg)
68+
69+
You can select any of the login options that work for you. For some users, the default browser login does not work. If it fails for you, we recommend the Cookie and Workspace Name Option.
70+
71+
![screenshot of cookie login choice](cookielogin.jpeg)
72+
73+
To retrieve the Cookie, Login into [https://kubernetes.slack.com](https://kubernetes.slack.com) with your credentials through your regular browser. You can retrieve the cookie using your browser's web developer tools (this works on both Firefox and Chrome). It will start with the string `xoxd`.
74+
75+
![screenshot of looking at the cookie in Chrome web developer tools](getcookie.jpeg)
76+
77+
Enter "kubernetes" for the workspace name, your session cookie, and select "Yes" for "Confirm creation of workspace" to create credentials.
78+
79+
![screenshot of the create credentials from cookie interface](createcredential.jpeg)
80+
81+
Navigate the menus and select "Export" (not "Dump"). You will be asked for a login.
82+
83+
![menu of choices, with Export highlighted](export.png)
84+
85+
Now you can export your private Channels and DMs. The easiest way is to use ChannelIDs.
86+
87+
To retrieve a ChannelID of a private channel, select the channel and click on the 3 dots to choose "Open channel details". The popup will display the Channel ID at the bottom.
88+
89+
![showing "open channel details" on a channel](channelid1.jpeg)
90+
91+
![showing the channelid at the bottom of the dialog](channelid2.jpeg)
92+
93+
For DMs, you follow a similar method. Click the three dots and select "Open conversation details". Afterwards you can copy a ChannelID.
94+
95+
![selecting channel details from a direct message](channelid3.jpeg)
96+
97+
![showing where the channel id is in the dialog](channelid4.jpeg)
98+
99+
Now you can export the channel contents, selecting each channel via its ID. We recommend the "standard" storage type.
100+
101+
![screenshot of the UI showing the options for exporting a channel](exportdata1.jpeg)
102+
103+
Once you have selected all the options, hit ESC to go back, and choose "Run Export". Slackdump will do a lot of pulling data, and eventually create a zip file in the root of your home directory.
104+
105+
![example of Slackdump exporting a channel](exportdata2.jpeg)
106+
107+
## View the export:
108+
109+
Once the workspace data is dumped, you can run built-in viewer:
110+
111+
```shell
112+
slackdump view <zip or directory>
113+
```
114+
115+
The built-in viewer supports all types of dumps:
116+
117+
1. Slackdump Archive format
118+
1. Standard and Mattermost Slack Export
119+
1. Dump mode files
120+
121+
Alternatively, you can use one of the following tools to view the
122+
export results:
123+
124+
- [SlackLogViewer] - a fast and powerful Slack Export viewer written in C++, works on Export files (images won't be displayed, unless you used an export token flag).
125+
- [Slackdump2Html] - a great Python application that converts Slack Dump to a
126+
static browsable HTML. It works on Dump mode files.
127+
- [slack export viewer][slack-export-viewer] - Slack Export Viewer is a well known viewer for
128+
slack export files. Supports displaying files if saved in the "Standard" file mode.
129+
130+
[SlackLogViewer]: https://github.com/thayakawa-gh/SlackLogViewer/releases
131+
[Slackdump2Html]: https://github.com/kununu/slackdump2html
132+
[slack-export-viewer]: https://github.com/hfaran/slack-export-viewer
133+
134+
## What Should I Do with the Backup Files?
135+
136+
**Kubernetes Private Channels**: Contact #sig-contribex about getting a folder for your group in the Kubernetes-owned Google Drive. Let them know who should have access to the folder.
137+
138+
**Non-Kubernetes Private Channels**: For other projects on our Slack with private channels (there's a few), it will be up to you to figure out an appropriate community-owned location for the export.
139+
140+
**Direct Message Threads**: In most cases, DMs you back up should stay in your own storage. If there is some reason why a DM thread should belong to the Kubernetes community, then contact ContribEx.
78.6 KB
Loading
45.4 KB
Loading
30.5 KB
Loading
27.2 KB
Loading
40.4 KB
Loading
49.3 KB
Loading

communication/slack-backup/export.png

68.2 KB
Loading
33.4 KB
Loading
48.9 KB
Loading
314 KB
Loading

communication/slack-backup/login.jpeg

37.8 KB
Loading
23.1 KB
Loading

communication/slack-migration-faq.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ If you are responsible for a channel or a team with a Slack User Group, you'll n
1616

1717
**Saved Files and Pinned Posts**: If your channel has important saved files and information in Pinned Posts, you need to copy that information to other media such as GitHub files or GoogleDocs *as soon as possible* and instead have a Bookmark linking to that location. Once our account is downgraded, we will not be able to access pinned posts and files more than 90 days old.
1818

19-
**Private Channels**: Private Channels are *not* backed up to our archives because they can't be. If you have important information in private channels which is more than 90 days old, copy it to another location as soon as possible. The Slack Admins are looking for a tools which supports backing up private channels; please request a backup on the #slack-admins channel as soon as possible if you need this.
19+
**Private Channels**: Private Channels are *not* backed up to our archives because they can't be. If you have important information in private channels which is more than 90 days old, copy it to another location as soon as possible. We recommend backing up the contents of your private channel [using Slackdump](slack-backup/README.md), an open source tool.
2020

2121
### Within The Next Few Weeks
2222

0 commit comments

Comments
 (0)