nixos/syncoid: add possibility to use string type for sshKey options

The sshKey options do not need to be a valid path at build time. Using
string instead allow use case when the path is not known at build time
such as when using systemd credentials (e.g. `sshKey =
"\${CREDENTIALS_DIRECTORY}/zfs-replication_ed25519";`).

authored by

datafoo and committed by
Jörg Thalheim
480f5b14 d60cb669

+2 -6
+2 -6
nixos/modules/services/backup/syncoid.nix
··· 123 }; 124 125 sshKey = mkOption { 126 - type = types.nullOr types.path; 127 - # Prevent key from being copied to store 128 - apply = mapNullable toString; 129 default = null; 130 description = lib.mdDoc '' 131 SSH private key file to use to login to the remote system. Can be ··· 205 recursive = mkEnableOption (lib.mdDoc ''the transfer of child datasets''); 206 207 sshKey = mkOption { 208 - type = types.nullOr types.path; 209 - # Prevent key from being copied to store 210 - apply = mapNullable toString; 211 description = lib.mdDoc '' 212 SSH private key file to use to login to the remote system. 213 Defaults to {option}`services.syncoid.sshKey` option.
··· 123 }; 124 125 sshKey = mkOption { 126 + type = with types; nullOr (coercedTo path toString str); 127 default = null; 128 description = lib.mdDoc '' 129 SSH private key file to use to login to the remote system. Can be ··· 203 recursive = mkEnableOption (lib.mdDoc ''the transfer of child datasets''); 204 205 sshKey = mkOption { 206 + type = with types; nullOr (coercedTo path toString str); 207 description = lib.mdDoc '' 208 SSH private key file to use to login to the remote system. 209 Defaults to {option}`services.syncoid.sshKey` option.