2023-02-09 11:40:11 +00:00
|
|
|
{ config, pkgs, lib, ... }:
|
|
|
|
with lib;
|
|
|
|
{
|
|
|
|
options.programs.sharing = {
|
2024-04-21 15:54:59 +00:00
|
|
|
enable = mkEnableOption ''
|
2023-02-09 11:40:11 +00:00
|
|
|
sharing, a CLI tool for sharing files.
|
|
|
|
|
|
|
|
Note that it will opens the 7478 port for TCP in the firewall, which is needed for it to function properly
|
2024-04-21 15:54:59 +00:00
|
|
|
'';
|
2023-02-09 11:40:11 +00:00
|
|
|
};
|
|
|
|
config =
|
|
|
|
let
|
|
|
|
cfg = config.programs.sharing;
|
|
|
|
in
|
|
|
|
mkIf cfg.enable {
|
|
|
|
environment.systemPackages = [ pkgs.sharing ];
|
|
|
|
networking.firewall.allowedTCPPorts = [ 7478 ];
|
|
|
|
};
|
|
|
|
}
|