Set `ssh_command` in borgmatic settings

I want to set the [ssh_command](borgmatic - ⚙️ Configuration) in borgmatic.

For all I can tell, this option is not possible to set via any of the borgmatic options exposed to home-manager.

What am I missing?

It looks like all extraConfig options are passed verbatim to the config file.

I wonder if using any of them works:

{
  programs.borgmatic.backups.thenameofyourbackup.location.extraConfig = {
    ssh_command = "ssh -i /path/to/private/key";
  };
}
1 Like