Files
zep/README.md
T

109 lines
3.8 KiB
Markdown

# Ditchcord (Zep)
Ditchcord is a sovereign, self-hosted communication platform designed for people who want to own their data without sacrificing a modern chat experience. Built with **Svelte 5** and **SpacetimeDB**, it provides text, voice, and video messaging for private communities, teams, and groups of friends.
> **Stop renting your community.** Ditchcord puts your data back where it belongs: on your hardware, under your control.
## Why Ditchcord?
* **Data Sovereignty:** You own the database. No middleman, no telemetry, and no "AI training" on your private conversations.
* **Frictionless Hosting:** Deploy your own instance in minutes. We favor a "one-command" philosophy to make self-hosting accessible to everyone.
* **Modern Performance:** Experience instant channel switching and fluid reactivity powered by Svelte 5 Runes and a relational WASM backend.
* **Low Idle Resources:** Ditchcord is designed to be lean. It won't eat your RAM or CPU while you aren't using it.
* **Secure by Default:** Built-in identity management and support for PGP-encrypted messaging.
## Core Features
* **Universal Communication:** High-fidelity voice channels, screen sharing, and rich text messaging with threading.
* **Private Communities:** Create private servers that require unique, secure invite links to join.
* **Client-Side Speed:** Aggressive denormalization and keyed lookups ensure O(1) performance even as your history grows.
* **Rich Media:** Built-in image management with automatic memory cleanup and custom emoji support.
* **Cross-Platform:** Access via any modern web browser or as a native desktop application via Tauri.
## The Technology Stack
Ditchcord is built on a "Lean & Fast" philosophy:
* **Frontend:** Svelte 5 (Runes), TypeScript, Vite, Vanilla CSS.
* **Backend:** [SpacetimeDB](https://spacetimedb.com) — a relational database and server-side logic engine compiled to WASM.
* **Voice/Video:** Peer-to-peer WebRTC mesh for zero-latency communication.
* **Desktop:** Native system integration via Tauri.
---
## Getting Started
### Prerequisites
* Node.js (v18+)
* pnpm
* SpacetimeDB CLI (`spacetime`)
* **For Docker:** Docker and Docker Compose
---
### One-Command Deployment (Recommended)
The fastest way to take control of your data is using Docker. This builds and starts both the frontend and your private SpacetimeDB instance in a single step.
```bash
pnpm run deploy:local
```
Once running, navigate to `http://localhost:5173` to start your community.
---
## Local Development (Manual Setup)
### 1. Backend Setup
1. Navigate to the backend directory: `cd spacetimedb`
2. Install dependencies: `npm install`
3. Publish the module to a local SpacetimeDB instance:
```bash
pnpm run spacetime:publish:local
```
### 2. Frontend Setup
1. Navigate to the project root and install dependencies: `pnpm install`
2. Configure `.env.local` for local development:
```env
VITE_SPACETIMEDB_HOST=ws://localhost:3000
VITE_SPACETIMEDB_DB_NAME=<your-db-name>
```
3. Start the development server: `pnpm run dev`
* *For local network testing with SSL, use `pnpm run dev:ssl`.*
---
## Production Deployment
### Option 1: Docker
Zep can be deployed using Docker Compose for a production-like local environment or self-hosting.
```bash
pnpm run deploy:local
```
### Option 2: Cloud (SpacetimeDB Maincloud + Cloudflare Pages)
#### Backend (SpacetimeDB Maincloud)
1. Publish the module to Maincloud:
```bash
pnpm run spacetime:publish
```
#### Frontend (Cloudflare Pages)
1. Build and deploy using Wrangler:
```bash
pnpm run deploy:cloudflare
```
---
## License
This project is open-source. See the `LICENSE` file for details.
---
> [!IMPORTANT]
> **Disclaimer:** This project is "vibe coded" and makes heavy use of AI. Expect experimental patterns and rapid structural changes.