Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions content/en/docs/getting-started/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,16 @@ title: "Getting Started"
description: "Quick start guides for all platforms"
icon: "rocket_launch"
date: "2025-10-08T14:59:30Z"
lastmod: "2026-07-24T01:02:28Z"
lastmod: "2026-08-10T00:00:00Z"
order: 1
---

{{% alert context="info" %}}
**Documentation versions:** Getting started guides target **v2.0.0 (beta)** by default. Using **v1.5.x (stable)**? Each guide links to its v1.5.x counterpart — for example {{< doclink path="getting-started/docker-v1.5.x" text="Docker (v1.5.x)" />}} or {{< doclink path="getting-started/config-v1.5.x" text="Configuration (v1.5.x)" />}}.
{{% /alert %}}

{{% alert context="warning" %}}
**Upgrading to v2.0.0?**

v2.0.0 requires a config update and a one-time BoltDB → SQLite migration. Back up `database.db`, then follow the {{< doclink path="getting-started/v2/migration/" text="v2 migration guide" />}} before changing your image tag.
v2.0.0 requires a config update and a one-time database migration from the legacy format. Back up `database.db`, then follow the {{< doclink path="getting-started/v2/migration/" text="v2 migration guide" />}} before changing your image tag to `beta`.
{{% /alert %}}
178 changes: 178 additions & 0 deletions content/en/docs/getting-started/config-v1.5.x.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,178 @@
---
title: "Configuration Files (v1.5.x)"
description: "Understanding and using configuration files in FileBrowser v1.5.x (stable)"
icon: "settings"
date: "2025-10-23T00:50:09Z"
lastmod: "2026-08-10T00:00:00Z"
order: 106
---

{{% alert context="info" %}}
**This guide is for v1.5.x and older (stable).** It uses the **legacy database** (`database.db`) and the flat `server.database` config format.

Looking for **v2.0.0 (beta)**? See the {{< doclink path="getting-started/config" text="v2.0.0 configuration guide" />}} instead.
{{% /alert %}}

{{% alert context="warning" %}}
**Planning to upgrade to v2.0.0?**

v2.0.0 replaces the legacy database with a new database format and restructures configuration. Follow the {{< doclink path="getting-started/v2/migration/" text="v2 migration guide" />}} before upgrading.
{{% /alert %}}

## What is a Config File?

A configuration file (config file) is a YAML file that defines how FileBrowser Quantum should work. While FileBrowser can run without a config file using default settings, a config file is *generally necessary* and allows you to customize:

- Server settings (port, database location, sources)
- Authentication methods (password, OIDC, proxy)
- User management and permissions
- Frontend customization (themes, branding)
- Media and office integrations

See an example [config file on Github](https://github.com/gtsteffaniak/filebrowser/blob/main/backend/config.yaml).

## How to Specify a Config File

FileBrowser looks for configuration in the following order of priority:

### 1. Command Line Argument
```bash
./filebrowser -c /path/to/config.yaml
```

### 2. Environment Variable
```bash
export FILEBROWSER_CONFIG="/path/to/config.yaml"
./filebrowser
```

### 3. Default Locations
- Current directory (`./config.yaml`)
- Docker default: `/home/filebrowser/data/config.yaml`

## Database Path Configuration

The database path is configured in the `server.database` setting. See {{< doclink path="configuration/server/#database" text="Server configuration" />}} for details.

**Default database locations:**
- Standalone: `./database.db` (current directory)
- Docker: first checks `/home/filebrowser/data/database.db`, then `./database.db` (current directory)

**Priority for database path:**
1. Path specified in `config.yaml` via `server.database`
2. Default location based on deployment type (standalone vs Docker)

## Docker Configuration

### Using Docker Run
```bash
# Mount your config file
docker run -d \
-v /path/to/your/config.yaml:/home/filebrowser/data/config.yaml \
-v /path/to/your/folder:/folder \
-p 80:80 \
gtstef/filebrowser:stable
```

### Using Docker Compose

<div class="pattern-card">

{{% alert context="info" %}}
Mount a host directory on `/home/filebrowser/data` if you want config, database, and cache to persist across container restarts (see {{< doclink path="getting-started/docker/" text="Docker setup" />}}).
{{% /alert %}}

```yaml
services:
filebrowser:
volumes:
- '/path/to/folder:/folder'
- './data:/home/filebrowser/data'
ports:
- '80:80'
image: gtstef/filebrowser:stable
restart: unless-stopped
```

</div>

## Basic Configuration Example

Here's a minimal config file to get you started:

```yaml
server:
sources:
- path: "/path/to/your/files" # or '/folder' in above example (do not load the full os filesystem, must be sub path)
config:
defaultEnabled: true # Give access to all users by default

auth:
adminUsername: admin
adminPassword: admin
```

## Configuration Options

FileBrowser supports extensive configuration options. You can view the complete configuration reference at:

- **Full config example**: {{< doclink path="reference/fullConfig/" text="Full Config Example" />}}
- **Current config**: In the web UI, Admins can go to Settings > System & Admin > Load Config

### Key Configuration Sections

- **Server Settings**: Port, database, sources, caching
- **Authentication**: Password, OIDC, proxy authentication
- **UsersDefaults**: New user defaults
- **Frontend**: UI customization, themes, branding
- **Integrations**: Media (FFmpeg) and office (OnlyOffice) support

## Best Practices

### 1. Keep It Simple
Only configure the settings you need. A minimal config is easier to read and maintain:

```yaml
server:
sources:
- path: "/data"
config:
defaultEnabled: true

auth:
adminUsername: admin
```

### 2. Use Environment Variables for Secrets
Instead of putting secrets in your config file, use {{< doclink path="reference/environment-variables" text="environment variables" />}}:

```yaml
auth:
methods:
oidc:
enabled: true
```

And set environment variables:
```bash
FILEBROWSER_ADMIN_PASSWORD="mysecurePassword"
FILEBROWSER_OIDC_CLIENT_ID=exampleID
FILEBROWSER_OIDC_CLIENT_SECRET=exampleSecret
```

### 3. Restart After Changes
Configuration changes require a restart to take effect:

```bash
# Stop FileBrowser
# Edit your config.yaml
# Start FileBrowser again
./filebrowser -c config.yaml
```

## Next Steps

- {{< doclink path="configuration/configuration-overview/" text="Configuration Overview" />}} - Complete configuration guide
- {{< doclink path="reference/fullconfig/" text="Full Configuration Reference" />}} - All available options
- {{< doclink path="configuration/sources/" text="Source Configuration" />}} - Configure file sources
- {{< doclink path="configuration/authentication/" text="Authentication Setup" />}} - Set up authentication methods
20 changes: 13 additions & 7 deletions content/en/docs/getting-started/config.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
---
title: "Configuration Files"
description: "Understanding and using configuration files in FileBrowser Quantum"
title: "Configuration Files (v2.0.0)"
description: "Understanding and using configuration files in FileBrowser v2.0.0 (beta)"
icon: "settings"
date: "2025-10-23T00:50:09Z"
lastmod: "2026-07-24T01:02:28Z"
lastmod: "2026-08-10T00:00:00Z"
order: 6
---

{{% alert context="info" %}}
**This guide is for v2.0.0 (beta).** It uses the **database** (`filebrowser.sqlite`) and the `server.database.path` config format.

Using **v1.5.x or older**? See the {{< doclink path="getting-started/config-v1.5.x" text="v1.5.x configuration guide" />}} instead.
{{% /alert %}}

{{% alert context="warning" %}}
**Upgrading to v2.0.0?**
**Upgrading from v1.x?**

v2.0.0 removes deprecated flat config formats and moves HTTP settings from `server` to `http`. Use the config migration tool and follow the {{< doclink path="getting-started/v2/migration/" text="v2 migration guide" />}} before upgrading.
{{% /alert %}}
Expand Down Expand Up @@ -58,7 +64,7 @@ The database path is configured under `server.database.path`. See {{< doclink pa
3. Default location based on deployment type

{{% alert context="info" %}}
**Upgrading from v1.x?** v2.0.0 uses SQLite instead of BoltDB (`database.db`). Rename your old database, set `migrateFrom`, and follow the {{< doclink path="getting-started/v2/migration/" text="migration guide" />}}. The `FILEBROWSER_DATABASE` env var is removed — use `FILEBROWSER_DATABASE_PATH` instead.
**Upgrading from v1.x?** v2.0.0 uses a new database instead of the legacy database (`database.db`). Rename your old database file, set `migrateFrom`, and follow the {{< doclink path="getting-started/v2/migration/" text="migration guide" />}}. The `FILEBROWSER_DATABASE` env var is removed — use `FILEBROWSER_DATABASE_PATH` instead.
{{% /alert %}}

## Docker Configuration
Expand All @@ -70,7 +76,7 @@ docker run -d \
-v /path/to/your/config.yaml:/home/filebrowser/data/config.yaml \
-v /path/to/your/folder:/folder \
-p 80:80 \
gtstef/filebrowser:stable
gtstef/filebrowser:beta
```

### Using Docker Compose
Expand All @@ -89,7 +95,7 @@ services:
- './data:/home/filebrowser/data'
ports:
- '80:80'
image: gtstef/filebrowser:stable
image: gtstef/filebrowser:beta
restart: unless-stopped
```

Expand Down
Loading
Loading