Sharkord

Data Directory

Where Sharkord keeps the database, uploads, config and plugins, and how to back it up or move it.

Everything lives in one directory. Back it up and you have backed up the server.

Location

PlatformPath
Linux~/.config/sharkord
macOS~/Library/Application Support/sharkord
Windows%APPDATA%\sharkord
Docker/home/bun/.config/sharkord

XDG_CONFIG_HOME is respected on Linux. SHARKORD_DATA_PATH=/srv/sharkord moves it anywhere.

What's Inside

EntryContents
config.iniServer configuration
db.sqliteThe database: users, roles, channels, messages, settings
backups/Snapshots taken automatically before migrations
uploads/Files being uploaded, before they are confirmed
public/Stored attachments, avatars, banners, and emojis. See Storage and Uploads
tmp/Scratch space for in-flight operations
logs/Server logs
plugins/Installed plugins, one folder each
plugin-data/What each plugin wrote. Survives plugin updates, one folder each
interface/The web client for the running version
mediasoup/The media worker binary
drizzle/Database migration state

Only edit config.ini by hand.

Backups

Stop the server, copy the directory, start it. Copying db.sqlite while it is being written can give a backup that will not open. If you cannot stop it, use sqlite3 db.sqlite "VACUUM INTO 'backup.sqlite'".

Moving or Resetting

  • Move: stop, copy the directory to the new machine, start the same version there. Update webRtc.announcedAddress if the IP changed.
  • Reset: delete the directory. Next start is a fresh server with a new owner token.

On this page