2019-05-06 23:18:10 +02:00
|
|
|
package config
|
2018-09-24 09:53:16 +02:00
|
|
|
|
2019-06-20 01:11:03 +02:00
|
|
|
import (
|
2021-01-09 12:18:59 +01:00
|
|
|
"github.com/klauspost/cpuid/v2"
|
2019-06-20 01:11:03 +02:00
|
|
|
"github.com/urfave/cli"
|
2021-09-23 13:16:05 +02:00
|
|
|
|
|
|
|
"github.com/photoprism/photoprism/internal/face"
|
2019-06-20 01:11:03 +02:00
|
|
|
)
|
2018-09-24 09:53:16 +02:00
|
|
|
|
2021-09-05 12:32:08 +02:00
|
|
|
// GlobalFlags describes global command-line parameters and flags.
|
2018-09-24 09:53:16 +02:00
|
|
|
var GlobalFlags = []cli.Flag{
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "debug",
|
2020-12-21 15:16:27 +01:00
|
|
|
Usage: "run in debug mode, shows additional log messages",
|
2018-09-24 09:53:16 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DEBUG",
|
|
|
|
},
|
2021-02-06 17:04:00 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "test",
|
|
|
|
Hidden: true,
|
|
|
|
Usage: "run in test mode",
|
|
|
|
},
|
2020-12-18 10:59:21 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "demo",
|
|
|
|
Hidden: true,
|
|
|
|
Usage: "run in demo mode",
|
|
|
|
EnvVar: "PHOTOPRISM_DEMO",
|
|
|
|
},
|
2021-01-15 18:30:26 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "sponsor",
|
|
|
|
Hidden: true,
|
2021-01-19 21:28:16 +01:00
|
|
|
Usage: "your continuous support helps to pay for development and operating expenses",
|
2021-01-15 18:30:26 +01:00
|
|
|
EnvVar: "PHOTOPRISM_SPONSOR",
|
|
|
|
},
|
2020-05-31 02:09:52 +02:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "public, p",
|
2020-12-21 15:16:27 +01:00
|
|
|
Usage: "no authentication required, disables password protection",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_PUBLIC",
|
|
|
|
},
|
2019-05-04 09:11:33 +02:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "read-only, r",
|
2020-12-21 15:16:27 +01:00
|
|
|
Usage: "don't modify originals folder; disables import, upload, and delete",
|
2020-05-29 09:23:26 +02:00
|
|
|
EnvVar: "PHOTOPRISM_READONLY",
|
2019-05-04 09:11:33 +02:00
|
|
|
},
|
2019-12-30 12:38:11 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "experimental, e",
|
|
|
|
Usage: "enable experimental features",
|
|
|
|
EnvVar: "PHOTOPRISM_EXPERIMENTAL",
|
|
|
|
},
|
2020-12-17 18:24:55 +01:00
|
|
|
cli.StringFlag{
|
2020-12-21 15:00:18 +01:00
|
|
|
Name: "admin-password",
|
2021-01-02 14:06:34 +01:00
|
|
|
Usage: "initial admin `PASSWORD`, min 4 characters",
|
2020-12-21 15:00:18 +01:00
|
|
|
EnvVar: "PHOTOPRISM_ADMIN_PASSWORD",
|
2020-12-17 18:24:55 +01:00
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "config-file, c",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "load initial config options from `FILENAME`",
|
2020-12-17 18:24:55 +01:00
|
|
|
EnvVar: "PHOTOPRISM_CONFIG_FILE",
|
|
|
|
},
|
2020-12-21 15:00:18 +01:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "config-path",
|
|
|
|
Usage: "config `PATH` containing application settings",
|
|
|
|
EnvVar: "PHOTOPRISM_CONFIG_PATH",
|
|
|
|
},
|
2020-05-31 02:09:52 +02:00
|
|
|
cli.StringFlag{
|
2020-12-18 09:11:42 +01:00
|
|
|
Name: "originals-path",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "originals `PATH` containing your photo and video collection",
|
2020-12-18 09:11:42 +01:00
|
|
|
EnvVar: "PHOTOPRISM_ORIGINALS_PATH",
|
2020-05-31 02:09:52 +02:00
|
|
|
},
|
2020-12-18 09:11:42 +01:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "originals-limit",
|
|
|
|
Value: 1000,
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "file size limit for originals in `MB`",
|
2020-12-18 09:11:42 +01:00
|
|
|
EnvVar: "PHOTOPRISM_ORIGINALS_LIMIT",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "import-path",
|
|
|
|
Usage: "optional `PATH` for importing files to originals",
|
|
|
|
EnvVar: "PHOTOPRISM_IMPORT_PATH",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "storage-path",
|
|
|
|
Usage: "storage `PATH` for cache, database and sidecar files",
|
|
|
|
EnvVar: "PHOTOPRISM_STORAGE_PATH",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "sidecar-path",
|
|
|
|
Usage: "relative or absolute storage `PATH` for sidecar files",
|
|
|
|
EnvVar: "PHOTOPRISM_SIDECAR_PATH",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "cache-path",
|
|
|
|
Usage: "cache storage `PATH` for sessions and thumbnails",
|
|
|
|
EnvVar: "PHOTOPRISM_CACHE_PATH",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "temp-path",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "temporary `PATH` for storing uploads and downloads",
|
2020-12-18 09:11:42 +01:00
|
|
|
EnvVar: "PHOTOPRISM_TEMP_PATH",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "backup-path",
|
|
|
|
Usage: "backup storage `PATH`",
|
|
|
|
EnvVar: "PHOTOPRISM_BACKUP_PATH",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "assets-path",
|
|
|
|
Usage: "assets `PATH` for static resources like models and templates",
|
|
|
|
EnvVar: "PHOTOPRISM_ASSETS_PATH",
|
2020-12-17 18:24:55 +01:00
|
|
|
},
|
2020-01-06 23:43:19 +01:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "workers, w",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "limits `NUMBER` of indexing workers",
|
2020-01-06 23:43:19 +01:00
|
|
|
EnvVar: "PHOTOPRISM_WORKERS",
|
2021-01-09 12:18:59 +01:00
|
|
|
Value: cpuid.CPU.PhysicalCores / 2,
|
2020-01-06 23:43:19 +01:00
|
|
|
},
|
2020-04-06 22:09:45 +02:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "wakeup-interval",
|
2020-12-18 09:11:42 +01:00
|
|
|
Usage: "background worker wakeup interval in `SECONDS`",
|
2020-04-06 22:09:45 +02:00
|
|
|
EnvVar: "PHOTOPRISM_WAKEUP_INTERVAL",
|
|
|
|
},
|
2021-01-02 18:56:15 +01:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "auto-index",
|
|
|
|
Usage: "auto indexing safety delay in `SECONDS` (WebDAV)",
|
|
|
|
EnvVar: "PHOTOPRISM_AUTO_INDEX",
|
|
|
|
},
|
|
|
|
cli.IntFlag{
|
|
|
|
Name: "auto-import",
|
|
|
|
Usage: "auto importing safety delay in `SECONDS` (WebDAV)",
|
|
|
|
EnvVar: "PHOTOPRISM_AUTO_IMPORT",
|
|
|
|
},
|
2020-12-18 09:11:42 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-backups",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables creating YAML metadata backup sidecar files",
|
2020-12-18 09:11:42 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_BACKUPS",
|
|
|
|
},
|
2020-12-18 10:59:21 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-webdav",
|
2021-04-30 14:24:01 +02:00
|
|
|
Usage: "disables built-in WebDAV server",
|
2020-12-18 10:59:21 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_WEBDAV",
|
|
|
|
},
|
2020-12-18 09:11:42 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-settings",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables settings UI and API",
|
2020-12-18 09:11:42 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_SETTINGS",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-places",
|
|
|
|
Usage: "disables reverse geocoding and maps",
|
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_PLACES",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-exiftool",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables metadata extraction with ExifTool",
|
2020-12-18 09:11:42 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_EXIFTOOL",
|
|
|
|
},
|
2021-08-05 15:15:33 +02:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-ffmpeg",
|
2021-09-21 14:11:15 +02:00
|
|
|
Usage: "disables video transcoding and thumbnail generation with FFmpeg",
|
2021-08-05 15:15:33 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_FFMPEG",
|
|
|
|
},
|
2021-04-30 14:24:01 +02:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-darktable",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables RAW file conversion with Darktable",
|
2021-04-30 14:24:01 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_DARKTABLE",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-rawtherapee",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables RAW file conversion with RawTherapee",
|
2021-04-30 14:24:01 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_RAWTHERAPEE",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-sips",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables RAW file conversion with Sips on macOS",
|
2021-04-30 14:24:01 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_SIPS",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-heifconvert",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "disables HEIC/HEIF file conversion",
|
2021-04-30 14:24:01 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_HEIFCONVERT",
|
|
|
|
},
|
2021-09-24 03:00:37 +02:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-tensorflow",
|
2021-09-24 05:42:06 +02:00
|
|
|
Usage: "disables all features depending on TensorFlow",
|
2021-09-24 03:00:37 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_TENSORFLOW",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-faces",
|
|
|
|
Usage: "disables facial recognition",
|
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_FACES",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "disable-classification",
|
|
|
|
Usage: "disables image classification",
|
|
|
|
EnvVar: "PHOTOPRISM_DISABLE_CLASSIFICATION",
|
|
|
|
},
|
2020-12-18 09:11:42 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "detect-nsfw",
|
|
|
|
Usage: "flag photos as private that may be offensive (requires TensorFlow)",
|
|
|
|
EnvVar: "PHOTOPRISM_DETECT_NSFW",
|
|
|
|
},
|
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "upload-nsfw",
|
|
|
|
Usage: "allow uploads that may be offensive",
|
|
|
|
EnvVar: "PHOTOPRISM_UPLOAD_NSFW",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "log-level, l",
|
|
|
|
Usage: "trace, debug, info, warning, error, fatal or panic",
|
|
|
|
Value: "info",
|
|
|
|
EnvVar: "PHOTOPRISM_LOG_LEVEL",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "log-filename",
|
|
|
|
Usage: "server log `FILENAME`",
|
|
|
|
EnvVar: "PHOTOPRISM_LOG_FILENAME",
|
|
|
|
Value: "",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "pid-filename",
|
|
|
|
Usage: "server process id `FILENAME`",
|
|
|
|
EnvVar: "PHOTOPRISM_PID_FILENAME",
|
|
|
|
},
|
2021-07-05 16:41:43 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "cdn-url",
|
|
|
|
Usage: "content delivery network `URL` (optional)",
|
|
|
|
EnvVar: "PHOTOPRISM_CDN_URL",
|
|
|
|
},
|
2019-12-11 14:10:20 +01:00
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "site-url",
|
2020-06-26 14:26:36 +02:00
|
|
|
Usage: "public site `URL`",
|
2019-12-11 14:10:20 +01:00
|
|
|
Value: "http://localhost:2342/",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_SITE_URL",
|
2019-12-11 14:10:20 +01:00
|
|
|
},
|
2020-06-26 14:26:36 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "site-preview",
|
|
|
|
Usage: "public preview image `URL`",
|
|
|
|
EnvVar: "PHOTOPRISM_SITE_PREVIEW",
|
|
|
|
},
|
2019-12-11 14:10:20 +01:00
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "site-title",
|
2019-12-11 14:10:20 +01:00
|
|
|
Usage: "site title",
|
|
|
|
Value: "PhotoPrism",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_SITE_TITLE",
|
2019-12-11 14:10:20 +01:00
|
|
|
},
|
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "site-caption",
|
2020-06-26 14:26:36 +02:00
|
|
|
Usage: "short site caption",
|
2020-06-25 18:39:48 +02:00
|
|
|
Value: "Browse Your Life",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_SITE_CAPTION",
|
2019-12-11 14:10:20 +01:00
|
|
|
},
|
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "site-description",
|
|
|
|
Usage: "long site description",
|
|
|
|
EnvVar: "PHOTOPRISM_SITE_DESCRIPTION",
|
2019-12-11 14:10:20 +01:00
|
|
|
},
|
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "site-author",
|
2020-06-26 14:26:36 +02:00
|
|
|
Usage: "site artist or copyright",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_SITE_AUTHOR",
|
|
|
|
},
|
|
|
|
cli.IntFlag{
|
|
|
|
Name: "http-port",
|
|
|
|
Value: 2342,
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "http server port `NUMBER`",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_HTTP_PORT",
|
2019-12-11 14:10:20 +01:00
|
|
|
},
|
2019-05-04 13:29:32 +02:00
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "http-host",
|
2020-06-26 14:26:36 +02:00
|
|
|
Usage: "http server `IP` address",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_HTTP_HOST",
|
2019-05-04 13:29:32 +02:00
|
|
|
},
|
2019-06-30 05:38:39 +02:00
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "http-mode, m",
|
|
|
|
Usage: "debug, release or test",
|
|
|
|
EnvVar: "PHOTOPRISM_HTTP_MODE",
|
2019-06-30 05:38:39 +02:00
|
|
|
},
|
2021-01-10 15:28:42 +01:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "http-compression, z",
|
|
|
|
Usage: "improves transfer speed and bandwidth utilization (none or gzip)",
|
|
|
|
EnvVar: "PHOTOPRISM_HTTP_COMPRESSION",
|
|
|
|
},
|
2019-06-30 05:38:39 +02:00
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "database-driver",
|
2020-06-26 14:26:36 +02:00
|
|
|
Usage: "database driver `NAME` (sqlite or mysql)",
|
2020-05-31 02:09:52 +02:00
|
|
|
Value: "sqlite",
|
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_DRIVER",
|
2019-06-30 05:38:39 +02:00
|
|
|
},
|
2018-09-24 09:53:16 +02:00
|
|
|
cli.StringFlag{
|
2020-05-31 02:09:52 +02:00
|
|
|
Name: "database-dsn",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "sqlite file name, specifying a `DSN` is optional for mariadb and mysql",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_DSN",
|
|
|
|
},
|
2020-12-11 12:46:28 +01:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "database-server",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "database server `HOST`, specifying a :port is optional",
|
2020-12-11 12:46:28 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_SERVER",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "database-name",
|
|
|
|
Value: "photoprism",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "database schema `NAME`",
|
2020-12-11 12:46:28 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_NAME",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "database-user",
|
|
|
|
Value: "photoprism",
|
|
|
|
Usage: "database user `NAME`",
|
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_USER",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
|
|
|
Name: "database-password",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "database user `PASSWORD`",
|
2020-12-11 12:46:28 +01:00
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_PASSWORD",
|
|
|
|
},
|
2020-05-31 02:09:52 +02:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "database-conns",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "`LIMIT` for open database connections",
|
2020-05-31 02:09:52 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_CONNS",
|
|
|
|
},
|
2020-07-13 10:41:45 +02:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "database-conns-idle",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "`LIMIT` for idle database connections",
|
2020-07-13 10:41:45 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DATABASE_CONNS_IDLE",
|
|
|
|
},
|
2021-05-01 10:25:34 +02:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "raw-presets",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "enables RAW file converter presets (may reduce performance)",
|
2021-05-01 10:25:34 +02:00
|
|
|
EnvVar: "PHOTOPRISM_RAW_PRESETS",
|
2020-08-12 13:16:25 +02:00
|
|
|
},
|
2019-06-06 14:44:29 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "darktable-bin",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "Darktable CLI `COMMAND` for RAW file conversion",
|
2019-06-06 14:44:29 +02:00
|
|
|
Value: "darktable-cli",
|
|
|
|
EnvVar: "PHOTOPRISM_DARKTABLE_BIN",
|
|
|
|
},
|
2021-09-21 15:33:46 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "darktable-blacklist",
|
|
|
|
Usage: "Comma-separated file extension `BLACKLIST`",
|
2021-09-24 07:44:36 +02:00
|
|
|
Value: "raf,cr3,dng",
|
2021-09-21 15:33:46 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DARKTABLE_BLACKLIST",
|
|
|
|
},
|
2021-05-01 10:25:34 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "rawtherapee-bin",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "RawTherapee CLI `COMMAND` for RAW file conversion",
|
2021-05-01 10:25:34 +02:00
|
|
|
Value: "rawtherapee-cli",
|
|
|
|
EnvVar: "PHOTOPRISM_RAWTHERAPEE_BIN",
|
2020-07-13 15:23:54 +02:00
|
|
|
},
|
2021-09-21 15:33:46 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "rawtherapee-blacklist",
|
|
|
|
Usage: "Comma-separated file extension `BLACKLIST`",
|
|
|
|
Value: "",
|
|
|
|
EnvVar: "PHOTOPRISM_RAWTHERAPEE_BLACKLIST",
|
|
|
|
},
|
2020-07-13 15:23:54 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "sips-bin",
|
2021-08-05 15:15:33 +02:00
|
|
|
Usage: "Sips `COMMAND` for RAW file conversion on macOS",
|
2020-07-13 15:23:54 +02:00
|
|
|
Value: "sips",
|
|
|
|
EnvVar: "PHOTOPRISM_SIPS_BIN",
|
2020-07-12 16:36:39 +02:00
|
|
|
},
|
2020-05-11 18:29:17 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "heifconvert-bin",
|
2020-12-18 09:11:42 +01:00
|
|
|
Usage: "HEIC/HEIF image convert `COMMAND`",
|
2020-05-11 18:29:17 +02:00
|
|
|
Value: "heif-convert",
|
|
|
|
EnvVar: "PHOTOPRISM_HEIFCONVERT_BIN",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
2020-05-13 15:36:42 +02:00
|
|
|
Name: "ffmpeg-bin",
|
2020-12-18 09:11:42 +01:00
|
|
|
Usage: "FFmpeg `COMMAND` for video transcoding and cover images",
|
2020-05-13 15:36:42 +02:00
|
|
|
Value: "ffmpeg",
|
2020-05-11 18:29:17 +02:00
|
|
|
EnvVar: "PHOTOPRISM_FFMPEG_BIN",
|
|
|
|
},
|
2021-02-11 20:22:00 +01:00
|
|
|
cli.StringFlag{
|
2021-02-16 11:40:40 +01:00
|
|
|
Name: "ffmpeg-encoder",
|
|
|
|
Usage: "FFmpeg AVC encoder `NAME`",
|
2021-02-11 20:22:00 +01:00
|
|
|
Value: "libx264",
|
2021-02-16 11:40:40 +01:00
|
|
|
EnvVar: "PHOTOPRISM_FFMPEG_ENCODER",
|
2021-02-11 20:22:00 +01:00
|
|
|
},
|
2021-02-17 18:19:52 +01:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "ffmpeg-bitrate",
|
|
|
|
Usage: "FFmpeg encoding bitrate `LIMIT` in Mbit/s",
|
|
|
|
Value: 50,
|
|
|
|
EnvVar: "PHOTOPRISM_FFMPEG_BITRATE",
|
|
|
|
},
|
2021-02-16 08:57:21 +01:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "ffmpeg-buffers",
|
|
|
|
Usage: "FFmpeg capture buffers",
|
|
|
|
Value: 32,
|
|
|
|
EnvVar: "PHOTOPRISM_FFMPEG_BUFFERS",
|
|
|
|
},
|
2019-06-06 14:44:29 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "exiftool-bin",
|
2020-12-21 15:00:18 +01:00
|
|
|
Usage: "ExifTool `COMMAND` for enhanced metadata extraction",
|
2019-06-06 14:44:29 +02:00
|
|
|
Value: "exiftool",
|
|
|
|
EnvVar: "PHOTOPRISM_EXIFTOOL_BIN",
|
|
|
|
},
|
2020-05-27 19:38:40 +02:00
|
|
|
cli.StringFlag{
|
|
|
|
Name: "download-token",
|
2021-08-20 00:10:26 +02:00
|
|
|
Usage: "static url `TOKEN` for original file downloads",
|
2020-05-27 19:38:40 +02:00
|
|
|
EnvVar: "PHOTOPRISM_DOWNLOAD_TOKEN",
|
|
|
|
},
|
|
|
|
cli.StringFlag{
|
2020-05-27 19:56:56 +02:00
|
|
|
Name: "preview-token",
|
2021-08-20 00:10:26 +02:00
|
|
|
Usage: "static url `TOKEN` for thumbnails and video streaming",
|
2020-05-27 19:56:56 +02:00
|
|
|
EnvVar: "PHOTOPRISM_PREVIEW_TOKEN",
|
2020-05-27 19:38:40 +02:00
|
|
|
},
|
2020-01-13 11:07:09 +01:00
|
|
|
cli.StringFlag{
|
2021-09-05 13:48:53 +02:00
|
|
|
Name: "thumb-filter",
|
|
|
|
Usage: "image downscaling `FILTER` (best to worst: blackman, lanczos, cubic, linear)",
|
2020-01-31 16:28:52 +01:00
|
|
|
Value: "lanczos",
|
2020-05-05 17:17:19 +02:00
|
|
|
EnvVar: "PHOTOPRISM_THUMB_FILTER",
|
2020-05-05 15:42:54 +02:00
|
|
|
},
|
2020-05-05 17:04:13 +02:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "thumb-size, s",
|
2021-09-05 13:48:53 +02:00
|
|
|
Usage: "max pre-cached thumbnail size in `PIXELS` (720-7680)",
|
2020-05-05 17:04:13 +02:00
|
|
|
Value: 2048,
|
|
|
|
EnvVar: "PHOTOPRISM_THUMB_SIZE",
|
|
|
|
},
|
2020-12-21 15:00:18 +01:00
|
|
|
cli.BoolFlag{
|
|
|
|
Name: "thumb-uncached, u",
|
2021-09-05 13:48:53 +02:00
|
|
|
Usage: "enable on-demand thumbnail generation (high memory and cpu usage)",
|
2020-12-21 15:00:18 +01:00
|
|
|
EnvVar: "PHOTOPRISM_THUMB_UNCACHED",
|
|
|
|
},
|
2020-05-05 17:04:13 +02:00
|
|
|
cli.IntFlag{
|
2020-07-13 15:23:54 +02:00
|
|
|
Name: "thumb-size-uncached, x",
|
2021-09-05 13:48:53 +02:00
|
|
|
Usage: "on-demand thumbnail generation size limit in `PIXELS` (720-7680)",
|
2020-07-15 08:30:28 +02:00
|
|
|
Value: 7680,
|
2020-07-13 15:23:54 +02:00
|
|
|
EnvVar: "PHOTOPRISM_THUMB_SIZE_UNCACHED",
|
|
|
|
},
|
|
|
|
cli.IntFlag{
|
2020-07-14 14:30:19 +02:00
|
|
|
Name: "jpeg-size",
|
2020-07-13 15:23:54 +02:00
|
|
|
Usage: "size limit for converted image files in `PIXELS` (720-30000)",
|
2020-07-15 08:30:28 +02:00
|
|
|
Value: 7680,
|
2020-07-14 14:30:19 +02:00
|
|
|
EnvVar: "PHOTOPRISM_JPEG_SIZE",
|
2020-01-13 11:07:09 +01:00
|
|
|
},
|
2020-05-19 11:00:17 +02:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "jpeg-quality, q",
|
2021-05-01 11:15:37 +02:00
|
|
|
Usage: "set to 90+ for high-quality thumbnails (25-100)",
|
2020-08-12 13:16:25 +02:00
|
|
|
Value: 92,
|
2020-05-19 11:00:17 +02:00
|
|
|
EnvVar: "PHOTOPRISM_JPEG_QUALITY",
|
|
|
|
},
|
2021-09-23 13:47:18 +02:00
|
|
|
cli.IntFlag{
|
|
|
|
Name: "face-size",
|
|
|
|
Usage: "min face size in `PIXELS`",
|
2021-09-24 03:00:37 +02:00
|
|
|
Value: 50,
|
2021-09-23 13:47:18 +02:00
|
|
|
EnvVar: "PHOTOPRISM_FACE_SIZE",
|
|
|
|
},
|
2021-09-23 13:16:05 +02:00
|
|
|
cli.Float64Flag{
|
|
|
|
Name: "face-score",
|
|
|
|
Usage: "face `QUALITY` threshold",
|
|
|
|
Value: face.ScoreThreshold,
|
|
|
|
EnvVar: "PHOTOPRISM_FACE_SCORE",
|
|
|
|
},
|
|
|
|
cli.IntFlag{
|
|
|
|
Name: "face-overlap",
|
2021-09-23 13:21:21 +02:00
|
|
|
Usage: "face area overlap threshold in `PERCENT`",
|
2021-09-23 13:16:05 +02:00
|
|
|
Value: face.OverlapThreshold,
|
|
|
|
EnvVar: "PHOTOPRISM_FACE_OVERLAP",
|
|
|
|
},
|
|
|
|
cli.IntFlag{
|
|
|
|
Name: "face-cluster-core",
|
|
|
|
Usage: "`NUMBER` of faces forming a cluster core",
|
|
|
|
Value: face.ClusterCore,
|
|
|
|
EnvVar: "PHOTOPRISM_FACE_CLUSTER_CORE",
|
|
|
|
},
|
|
|
|
cli.Float64Flag{
|
|
|
|
Name: "face-cluster-dist",
|
|
|
|
Usage: "`RADIUS` of faces forming a cluster core",
|
|
|
|
Value: face.ClusterDist,
|
|
|
|
EnvVar: "PHOTOPRISM_FACE_CLUSTER_DIST",
|
|
|
|
},
|
|
|
|
cli.Float64Flag{
|
|
|
|
Name: "face-match-dist",
|
|
|
|
Usage: "`OFFSET` distance when matching faces with clusters",
|
|
|
|
Value: face.MatchDist,
|
|
|
|
EnvVar: "PHOTOPRISM_FACE_MATCH_DIST",
|
|
|
|
},
|
2018-09-24 09:53:16 +02:00
|
|
|
}
|