# ![Syncthing](<https://daemonless.io/images/logos/syncthing.svg#only-light>) ![Syncthing](<https://daemonless.io/images/logos/syncthing-dark.svg#only-dark>) Syncthing

[![Build Status](<https://img.shields.io/github/actions/workflow/status/daemonless/syncthing/build.yaml?style=flat-square&amp;label=Build&amp;color=green>)](<https://github.com/daemonless/syncthing/actions>) [![Last Commit](<https://img.shields.io/github/last-commit/daemonless/syncthing?style=flat-square&amp;label=Last+Commit&amp;color=blue>)](<https://github.com/daemonless/syncthing/commits>) [![OCI Pulls](<https://img.shields.io/docker/pulls/daemonless/syncthing?style=flat-square&amp;label=OCI+Pulls&amp;color=blue>)](<https://hub.docker.com/r/daemonless/syncthing>)

Syncthing replaces proprietary sync and cloud services with something open, trustworthy and decentralized. Your data is your data alone and you deserve to choose where it is stored, if it is shared with some third party and how it's transmitted over the Internet.

[[![Syncthing screenshot 1](<https://daemonless.io/images/screenshots/syncthing/Syncthing-screenshot-dark.png>)](</images/screenshots/syncthing/Syncthing-screenshot-dark.png>)](</images/screenshots/syncthing/Syncthing-screenshot-dark.png>)

|  |  |
| --- | --- |
| **Port** | `8384` |
| **Registry** | [`ghcr.io/daemonless/syncthing`](<https://github.com/daemonless/syncthing/pkgs/container/syncthing>) |
| **Daemonless** | [daemonless/syncthing](<https://github.com/daemonless/syncthing>) |
| **Source** | [syncthing/syncthing](<https://github.com/syncthing/syncthing>) |
| **Website** | [syncthing.net](<https://syncthing.net/>) |

## Prerequisites

Before deploying, ensure your host environment is ready. See the [Quick Start Guide](<https://daemonless.io/guides/quick-start/index.md>) for host setup instructions, including the security model for host vs. container privileges.

## Deployment

**Customize Paths, UID & Ports**

Install and manage **Syncthing** on FreeBSD with [fjord](<https://fjord.daemonless.io>):

```
fjord install syncthing
```

Or open the **App Store** in the fjord web UI and install **Syncthing** from the wizard. New to fjord? See the [Install Guide](<https://fjord.daemonless.io/install/>).

```
services:
  syncthing:
    image: "ghcr.io/daemonless/syncthing:latest"
    container_name: syncthing
    volumes:
      - "/containers/syncthing:/config"
    ports:
      - "8384:8384"
      - "22000:22000"
      - "22000:22000/udp"
      - "21027:21027/udp"
    # always (not unless-stopped) so FreeBSD's podman rc.d auto-starts it at boot
    restart: always
```

Save as `compose.yaml`, then run `podman-compose up -d`.

> [!WARNING]
>
> Exposing ports in AppJail means that your service can be reached from remote hosts. If that is not your intention, do not expose the ports and communicate with the service using the jail's IPv4 address or hostname assigned by the virtual network.

```
# .env

DIRECTOR_PROJECT=syncthing
```

```
# appjail-director.yml

options:
  - virtualnet: ':<random> default'
  - nat:
services:
  syncthing:
    name: syncthing
    options:
      - container: 'args:--pull'
      - expose: '8384:8384 proto:tcp'
      - expose: '22000:22000 proto:tcp'
      - expose: '22000:22000 proto:udp'
      - expose: '21027:21027 proto:udp'
    volumes:
      - syncthing: /config
volumes:
  syncthing:
    device: '/containers/syncthing'
```

```
# Makejail

ARG tag=latest

OPTION container=boot
OPTION overwrite=force
OPTION from=ghcr.io/daemonless/syncthing:${tag}
```

Save the files above, then run `appjail-director up`.

> [!WARNING]
>
> **Experimental**
>
> Bastille's OCI support is experimental. It requires `buildah` and shares the host network stack (`inherit`). Mount volumes with `--volume HOST JAIL`; without it, image-declared volumes are stored under `${bastille_volumesdir}/${jail}`.

```
services:
  syncthing:
    name: syncthing
    image: "ghcr.io/daemonless/syncthing:latest"
    network:
      - mode: host
    volumes:
      - "/containers/syncthing:/config"
```

Save as `bastille-compose.yml`, then run `bastille up`.

Open `http://<server>:8384` from another machine (the server's own browser can't use a published port).

## Parameters

### Volumes

| Path | Description |
| --- | --- |
| `/config` | Configuration and data directory |

### Ports

| Port | Protocol | Description |
| --- | --- | --- |
| `8384` | TCP | Web UI |
| `22000` | TCP | Sync protocol (TCP/UDP) |
| `22000` | UDP | Sync protocol (TCP/UDP) |
| `21027` | UDP |  |

## Version Tags

| Tag | Description | Best For |
| :--- | :--- | :--- |
| `latest` | **Upstream Binary**. Built from official release. | Alternative build. |
| `pkg` | **FreeBSD Quarterly**. Uses stable, tested packages. | Production stability. |
| `pkg-latest` | **FreeBSD Latest**. Rolling package updates. | Staying current. |

> [!NOTE]
>
> **Implementation Details**
>
> - **Architectures:** amd64
> - **User:** `bsd` (UID/GID set via [PUID/PGID](<https://daemonless.io/guides/permissions/index.md>)). Defaults to `1000:1000`.
> - **Base:** Built on `ghcr.io/daemonless/base` (FreeBSD 15.1).

---

Need help? Join our [Discord](<https://discord.gg/Kb9tkhecZT>) community.
