What Outline Does
- Rich Editor: Markdown-based editor with slash commands, embeds, and real-time collaboration
- Nested Documents: Infinite nesting with drag-and-drop reordering
- Collections: Organize documents into team spaces (Engineering, Product, HR, etc.)
- Full-Text Search: Lightning-fast search across all documents
- Templates: Create document templates for recurring content types
- Comments: Inline and page-level commenting with @mentions
- Revision History: Full version history with visual diff and restore
- API: Complete REST API for automation and integration
- Integrations: Slack, Figma, Loom, Diagrams.net, Google Docs embed
Architecture
┌──────────────┐ ┌──────────────┐ ┌──────────────┐
│ Browser │────▶│ Outline │────▶│ PostgreSQL │
│ (React) │ │ Server │ │ (Data) │
└──────────────┘ │ (Node.js) │ └──────────────┘
└──────┬───────┘
│
┌─────────┼─────────┐
│ │ │
┌──────┴──┐ ┌───┴───┐ ┌───┴───┐
│ Redis │ │ MinIO │ │ OIDC │
│ (Cache) │ │(Files)│ │ (Auth) │
└─────────┘ └───────┘ └────────┘Self-Hosting
Docker Compose
services:
outline:
image: outlinewiki/outline:latest
ports:
- "3000:3000"
environment:
DATABASE_URL: postgres://outline:outline@postgres:5432/outline
REDIS_URL: redis://redis:6379
SECRET_KEY: generated-secret-key
UTILS_SECRET: generated-utils-secret
URL: http://localhost:3000
FILE_STORAGE: local
FILE_STORAGE_LOCAL_ROOT_DIR: /var/lib/outline/data
# Auth (choose one): Slack, Google, OIDC, SAML
OIDC_CLIENT_ID: your-client-id
OIDC_CLIENT_SECRET: your-client-secret
OIDC_AUTH_URI: https://auth.yourdomain.com/authorize
OIDC_TOKEN_URI: https://auth.yourdomain.com/token
OIDC_USERINFO_URI: https://auth.yourdomain.com/userinfo
depends_on:
- postgres
- redis
volumes:
- outline-data:/var/lib/outline/data
postgres:
image: postgres:16-alpine
environment:
POSTGRES_USER: outline
POSTGRES_PASSWORD: outline
POSTGRES_DB: outline
volumes:
- pg-data:/var/lib/postgresql/data
redis:
image: redis:7-alpine
volumes:
outline-data:
pg-data:Key Features
Slash Commands Editor
Type / to access:
/heading — Insert heading (H1-H3)
/list — Bullet or numbered list
/todo — Task/checkbox list
/table — Insert table
/code — Code block with syntax highlighting
/image — Upload or embed image
/embed — Embed YouTube, Figma, Loom, etc.
/diagram — Draw.io diagram
/math — LaTeX math equation
/notice — Info/warning/tip callout box
/divider — Horizontal dividerCollections & Structure
Knowledge Base
├── 📘 Engineering
│ ├── Architecture Decisions
│ │ ├── ADR-001: Database Choice
│ │ └── ADR-002: API Design
│ ├── Runbooks
│ │ ├── Deploy to Production
│ │ └── Database Migration
│ └── Onboarding
│ ├── Day 1 Setup
│ └── Week 1 Checklist
├── 📗 Product
│ ├── PRDs
│ ├── Research
│ └── Roadmap
└── 📕 Company
├── Handbook
├── Policies
└── BenefitsIntegrations
| Integration | Feature |
|---|---|
| Slack | Search wiki from Slack, post notifications |
| Figma | Embed live Figma designs |
| Loom | Embed video recordings |
| Google Docs | Import/embed docs |
| Diagrams.net | Draw diagrams inline |
| Mermaid | Code-based diagrams |
| GitHub | Embed code snippets |
API
# Search documents
curl -X POST https://outline.yourdomain.com/api/documents.search
-H "Authorization: Bearer YOUR_TOKEN"
-H "Content-Type: application/json"
-d '{"query": "deployment guide"}'
# Create document
curl -X POST https://outline.yourdomain.com/api/documents.create
-H "Authorization: Bearer YOUR_TOKEN"
-H "Content-Type: application/json"
-d '{"title": "New Guide", "text": "# Getting Started
Welcome!", "collectionId": "collection-uuid", "publish": true}'Outline vs Alternatives
| Feature | Outline | Notion | Confluence | Docmost |
|---|---|---|---|---|
| Open Source | BSL (→ Apache) | No | No | Yes (AGPL) |
| Self-hosted | Yes | No | Data Center | Yes |
| Real-time collab | Yes | Yes | Yes | Yes |
| Markdown | Native | Partial | No | Yes |
| Slash commands | Yes | Yes | No | Yes |
| API | Full REST | Full REST | REST | REST |
| Integrations | Slack, Figma | 50+ | Atlassian | Basic |
| UX quality | Excellent | Excellent | Good | Good |
常见问题
Q: Outline 的 BSL 许可证意味着什么? A: BSL(Business Source License)允许自由使用和修改,但限制作为托管服务提供给第三方。4 年后自动转为 Apache-2.0。对于自托管使用没有任何限制。
Q: 必须用 SSO 登录吗? A: 是的,Outline 需要 OAuth/OIDC 认证提供者(Slack、Google、自托管 OIDC 如 Keycloak/Authentik)。不支持简单的邮箱密码登录。这是设计决策,确保企业级安全性。
Q: 可以从 Notion/Confluence 迁移吗? A: 可以。Outline 支持从 Confluence(XML 导出)和 Notion(Markdown 导出)导入。也支持从 Markdown 文件批量导入。
来源与致谢
- GitHub: outline/outline — 38K+ ⭐ | BSL
- 官网: getoutline.com