{
  "service": {
    "name": "PhotoVault",
    "version": "2.8.1",
    "environment": "production",
    "publicUrl": "https://photos.example.net",
    "dataDirectory": "/srv/photovault/library",
    "readOnly": false
  },
  "server": {
    "host": "0.0.0.0",
    "port": 8080,
    "trustedProxies": [
      "10.0.0.0/8",
      "172.16.0.0/12"
    ],
    "tls": {
      "enabled": false,
      "certificateFile": null,
      "privateKeyFile": null
    },
    "limits": {
      "maximumUploadBytes": 10737418240,
      "requestTimeoutSeconds": 300,
      "concurrentUploads": 6
    }
  },
  "database": {
    "engine": "postgresql",
    "host": "postgres",
    "port": 5432,
    "name": "photovault",
    "username": "photovault",
    "sslMode": "prefer",
    "pool": {
      "minimumConnections": 2,
      "maximumConnections": 20,
      "idleTimeoutSeconds": 60
    }
  },
  "storage": {
    "originals": {
      "backend": "filesystem",
      "path": "/srv/photovault/library/originals",
      "preserveFilenames": true,
      "directoryTemplate": "{year}/{month}/{assetId}"
    },
    "thumbnails": {
      "backend": "filesystem",
      "path": "/srv/photovault/cache/thumbnails",
      "formats": [
        "webp",
        "jpeg"
      ],
      "sizes": [
        256,
        720,
        1440
      ],
      "quality": 82
    },
    "backup": {
      "enabled": true,
      "schedule": "0 3 * * *",
      "retentionDays": 30,
      "destination": {
        "backend": "s3",
        "bucket": "photovault-backups",
        "region": "ca-central-1",
        "endpoint": "https://object-storage.example.net",
        "pathPrefix": "production"
      }
    }
  },
  "authentication": {
    "localLoginEnabled": true,
    "registrationEnabled": false,
    "sessionLifetimeHours": 168,
    "oidc": {
      "enabled": true,
      "issuerUrl": "https://auth.example.net/application/o/photovault/",
      "clientId": "photovault-web",
      "scopes": [
        "openid",
        "profile",
        "email"
      ],
      "autoProvisionUsers": true,
      "defaultRole": "member"
    }
  },
  "library": {
    "supportedImageFormats": [
      "jpg",
      "jpeg",
      "png",
      "webp",
      "heic",
      "tiff",
      "dng",
      "cr2",
      "nef"
    ],
    "supportedVideoFormats": [
      "mp4",
      "mov",
      "mkv",
      "webm"
    ],
    "duplicateDetection": {
      "enabled": true,
      "strategy": "sha256",
      "perceptualSimilarityThreshold": 0.96
    },
    "metadata": {
      "readExif": true,
      "writeSidecarFiles": false,
      "extractEmbeddedPreviews": true,
      "timezoneFallback": "America/Toronto"
    },
    "indexing": {
      "watchFilesystem": true,
      "scanSchedule": "15 */6 * * *",
      "excludePatterns": [
        "**/.DS_Store",
        "**/@eaDir/**",
        "**/Thumbs.db",
        "**/.trash/**"
      ]
    }
  },
  "machineLearning": {
    "enabled": true,
    "endpoint": "http://machine-learning:3003",
    "features": {
      "faceDetection": {
        "enabled": true,
        "minimumDetectionScore": 0.7,
        "minimumFacesForPerson": 3
      },
      "smartSearch": {
        "enabled": true,
        "model": "ViT-B-32",
        "languages": [
          "en",
          "fr"
        ]
      },
      "objectRecognition": {
        "enabled": true,
        "minimumConfidence": 0.65
      }
    }
  },
  "sharing": {
    "publicLinksEnabled": true,
    "defaultExpirationDays": 14,
    "allowDownloads": true,
    "passwordProtectionAvailable": true,
    "maximumAssetsPerShare": 5000
  },
  "users": [
    {
      "id": "usr_01J4C8Q2K9M7N5P3R1T6V8W0XY",
      "email": "admin@example.net",
      "displayName": "Library Administrator",
      "role": "admin",
      "storageQuotaBytes": null,
      "preferences": {
        "theme": "system",
        "locale": "en-CA",
        "dateFormat": "YYYY-MM-DD",
        "mapProvider": "openstreetmap"
      }
    },
    {
      "id": "usr_01J4C91RZ2H8A6F5G3D7S0KQMP",
      "email": "family@example.net",
      "displayName": "Family Account",
      "role": "member",
      "storageQuotaBytes": 536870912000,
      "preferences": {
        "theme": "dark",
        "locale": "fr-CA",
        "dateFormat": "DD/MM/YYYY",
        "mapProvider": "openstreetmap"
      }
    }
  ],
  "notifications": {
    "email": {
      "enabled": true,
      "smtpHost": "smtp.example.net",
      "smtpPort": 587,
      "encryption": "starttls",
      "fromAddress": "PhotoVault <photos@example.net>"
    },
    "events": [
      "backup_failed",
      "storage_near_capacity",
      "new_shared_album",
      "security_alert"
    ]
  },
  "observability": {
    "logLevel": "info",
    "structuredLogs": true,
    "metrics": {
      "enabled": true,
      "path": "/metrics",
      "includeRuntimeMetrics": true
    },
    "healthCheck": {
      "path": "/api/health",
      "includeDependencyStatus": true
    }
  }
}