NOTE: default password is photoprism
sops.secrets."services/photoprism/password" = {
owner = "photoprism";
#keyFiles: PHOTOPRISM_ADMIN_PASSWORD=<yourpassword>
path = "/var/lib/photoprism/keyFile";
};
services.photoprism = {
enable = true;
mysql = true;
# sops support
#keyFile = true;
port = 9999;
host = "127.0.0.1";
};
{ pkgs ? import <nixpkgs> { } }:
let
photoprism2nix = import (builtins.fetchTarball {
name = "photoprism2nix-2021-11-25";
url = "https://github.com/GTrunSec/photoprism2nix/archive/51d1ff6068f6823e08bba914293a3e891bdc0612.tar.gz";
sha256 = "sha256:0yqj3bg5mkz4ivpgx2agwq324sr8psdgd169f1s4kfi7krpds7l8";
});
in
pkgs.mkShell {
buildInputs = [ photoprism2nix.defaultPackage.x86_64-linux ];
}
- nix modules
imports = [ photoprism2nix.nixosModules.photoprism ]
systemctl status photoprism.service
● photoprism.service Loaded: loaded (/nix/store/narmv6gkhdryrx4a8f9j7jplf6ifl0ak-photoprism-chroot-paths/lib/systemd/system/photoprism.service; enabled; vendor preset: enabled) Drop-In: /nix/store/rghm1g5zn25pc9ddi36n7lj6g3izfrh3-system-units/photoprism.service.d └─overrides.conf Active: active (running) since Mon 2021-04-05 11:59:26 PDT; 9h ago Main PID: 2471 (photoprism) IP: 1018.0K in, 81.2K out IO: 83.6M read, 95.1M written Tasks: 18 (limit: 4915) Memory: 218.8M CPU: 24.852s CGroup: /system.slice/photoprism.service └─2471 /nix/store/2pjwd95ilvz3ji8vsaiv3s8v4a76yf09-photoprism/bin/photoprism --assets-path /nix/store/694ipsa92251kx8npq6sniqhlikc8sl8-photoprims-assets start Apr 05 21:29:30 NixOS photoprism[2471]: time="2021-04-06T04:29:30Z" level=debug msg="metadata: starting routine check" Apr 05 21:29:30 NixOS photoprism[2471]: time="2021-04-06T04:29:30Z" level=debug msg="moments: index contains 638 photos and 38 videos, using threshold 10" Apr 05 21:29:31 NixOS photoprism[2471]: time="2021-04-06T04:29:31Z" level=debug msg="moments: updated “Bays, Capes & Beaches” (public:true label:beach|seashore)" Apr 05 21:29:31 NixOS photoprism[2471]: time="2021-04-06T04:29:31Z" level=debug msg="moments: updated “Bays, Capes & Beaches” (public:true label:beach|seashore)" Apr 05 21:29:31 NixOS photoprism[2471]: time="2021-04-06T04:29:31Z" level=debug msg="moments: 110 albums saved as yaml files" Apr 05 21:44:30 NixOS photoprism[2471]: time="2021-04-06T04:44:30Z" level=debug msg="metadata: starting routine check" Apr 05 21:44:30 NixOS photoprism[2471]: time="2021-04-06T04:44:30Z" level=debug msg="moments: index contains 638 photos and 38 videos, using threshold 10" Apr 05 21:44:31 NixOS photoprism[2471]: time="2021-04-06T04:44:31Z" level=debug msg="moments: updated “Bays, Capes & Beaches” (public:true label:beach|seashore)" Apr 05 21:44:31 NixOS photoprism[2471]: time="2021-04-06T04:44:31Z" level=debug msg="moments: updated “Bays, Capes & Beaches” (public:true label:beach|seashore)" Apr 05 21:44:31 NixOS photoprism[2471]: time="2021-04-06T04:44:31Z" level=debug msg="moments: 110 albums saved as yaml files"