Nomploy Nomad Packs

← All packs

filebrowser v0.1.0

Files & sync

File Browser — a clean web file manager for a directory: browse, upload, download, edit, share, and manage files and users from the browser. Deployed as a single host-networked Nomad service with a files volume and a database volume.

nomad-pack run filebrowser --registry nomploy
…or one line (add registry + run)
curl -fsSL https://packs.nomploy.com/install.sh | sh -s -- filebrowser

Needs nomad-pack on PATH. The script only adds the nomploy registry and runs this pack.

1 task http 8103 2 volumes image filebrowser/filebrowser:latest tracks :latest image bumped 28 days ago
Variables 9
values.hcl

Save as values.hcl, edit, then run:

nomad-pack run filebrowser -f values.hcl --registry nomploy
# The name of the Nomad job.
job_name = "filebrowser"

# The Nomad namespace to deploy into.
namespace = "default"

# The datacenters to deploy to.
datacenters = ["*"]

# The File Browser container image. Pin a tag in production.
image = "filebrowser/filebrowser:latest"

# Host port for the File Browser web UI (FB_PORT).
port = 8103

# Named volume for the files being managed, mounted at /srv.
files_volume = "filebrowser_files"

# Named volume for the File Browser database (/database/filebrowser.db lives here).
data_volume = "filebrowser_data"

# Placement constraints. Pin to the node holding the volumes. On a nomploy cluster: attribute = "$${meta.nomploy_control_plane}", operator = "=", value = "true".
constraints = []

# The task resources.
resources = {
    cpu    = 300
    memory = 128
  }
NameTypeDefaultDescription
job_name string
"filebrowser"
The name of the Nomad job.
namespace string
"default"
The Nomad namespace to deploy into.
datacenters list
["*"]
The datacenters to deploy to.
image string
"filebrowser/filebrowser:latest"
The File Browser container image. Pin a tag in production.
port number
8103
Host port for the File Browser web UI (FB_PORT).
files_volume string
"filebrowser_files"
Named volume for the files being managed, mounted at /srv.
data_volume string
"filebrowser_data"
Named volume for the File Browser database (/database/filebrowser.db lives here).
constraints list
[]
Placement constraints. Pin to the node holding the volumes. On a nomploy cluster: attribute = "$${meta.nomploy_control_plane}", operator = "=", value = "true".
resources object
{
    cpu    = 300
    memory = 128
  }
The task resources.
Back up this pack

This pack stores data in 2 Docker named volumes: filebrowser_filesfilebrowser_data

restic

# Run on the node hosting this pack. Point restic at your repo first:
#   export RESTIC_REPOSITORY="s3:https://<account>.r2.cloudflarestorage.com/<bucket>"
#   export RESTIC_PASSWORD="<repo-password>"
#   export AWS_ACCESS_KEY_ID=<key>  AWS_SECRET_ACCESS_KEY=<secret>
restic backup \
  /var/lib/docker/volumes/filebrowser_files/_data \
  /var/lib/docker/volumes/filebrowser_data/_data

rclone (sync to S3/R2)

rclone sync /var/lib/docker/volumes/filebrowser_files/_data backup:<bucket>/filebrowser_files
rclone sync /var/lib/docker/volumes/filebrowser_data/_data backup:<bucket>/filebrowser_data

Paths assume the default Docker volume location (/var/lib/docker/volumes). Restore by stopping the job, restoring files into the same volume, and re-running the pack.

Readme

filebrowser

File Browser — a clean web file manager for a directory: browse, upload, download, edit, preview, share, and manage files and users from the browser.

Single host-networked Nomad service with a files volume (/srv) and a database volume.

Deploy

nomad-pack registry add nomploy https://github.com/Nomploy/nomad-packs
nomad-pack run filebrowser --registry=nomploy

Configure

Variable Default Description
port 8103 Web UI port (FB_PORT).
files_volume filebrowser_files /srv — the files you manage.
data_volume filebrowser_data /database — the File Browser database.
image filebrowser/filebrowser:latest Container image. Pin a tag in production.
resources { cpu = 300, memory = 128 } Task resources.

First start creates the database and an admin account — check the task logs for the generated admin password (older images use admin / admin) and change it immediately. Pin the job to the node holding the volumes with constraints.