Skip to content

Repository files navigation

⚡ LightDrive

Self-hosted cloud storage with file sharing, previews, analytics, and a REST API.

Built with SvelteKit, Prisma.

Quick Install (Linux)

curl -fsSL https://raw.githubusercontent.com/lbirkert/lightdrive/main/setup.sh | bash

Installs Node.js, clones the repo, builds the app, and registers a systemd service.
Works on Debian, Ubuntu, Fedora, Arch, openSUSE, and Raspberry Pi OS.
Run the same command again to update.

Local Development

git clone https://github.com/lbirkert/lightdrive.git
cd lightdrive
cp .env.example .env
npm install
npm run dev

Features

📁 File managementFolder tree, list/grid views, drag-and-drop uploads
🔗 Share linksGranular permissions (view, edit, insert, structure)
👥 CollaborationInvite users to folders with role-based access
🖼️ PreviewsImages, PDFs, documents (docx/md/txt/csv), audio/video
📊 AnalyticsStorage usage, upload/download activity charts
🔒 SecurityArgon2 hashing, HTTP-only session cookies
📡 REST APIFull API with Scalar documentation at /api-docs

Screenshots

LightDrive app

Routes

PathDescription
/Marketing landing page
/drive/{userId}Personal drive
/drive/{shareToken}Shared drive (via share link)
/authSign in / Sign up
/accountAccount settings
/account/preferencesTheme preferences
/account/sharesManage share links
/dashboardUsage analytics
/api-docsREST API reference

Environment

VariableDefaultDescription
DATABASE_URLfile:./dev.dbSQLite database path
ORIGINPublic URL (required for production)
PORT3000Server port
BODY_SIZE_LIMIT52428800Max upload size (bytes)

Tech Stack

  • Runtime: Node.js 24
  • Framework: SvelteKit (Svelte 5)
  • Database: SQLite via Prisma + libSQL (PostgreSQL optional)
  • Auth: Argon2 password hashing, HTTP-only session cookies
  • Icons: Lucide
  • Previews: Sharp (images), Mammoth (docx), Marked (markdown)
  • Transcoding: FFmpeg (audio/video)

About

blazingly fast google drive clone

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages