mirror of
https://github.com/kmein/niveum
synced 2026-03-16 10:11:08 +01:00
wip: flakes
This commit is contained in:
@@ -1,29 +0,0 @@
|
||||
{ pkgs, lib, config, ... }:
|
||||
with lib;
|
||||
let cfg = config.niveum.dropbox;
|
||||
in {
|
||||
options.niveum.dropbox = { enable = mkEnableOption "Dropbox"; };
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
environment.systemPackages = [ pkgs.dropbox-cli ];
|
||||
|
||||
networking.firewall = {
|
||||
allowedTCPPorts = [ 17500 ];
|
||||
allowedUDPPorts = [ 17500 ];
|
||||
};
|
||||
|
||||
systemd.user.services.dropbox = {
|
||||
description = "Dropbox synchronisation service";
|
||||
wantedBy = [ "graphical-session.target" ];
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.dropbox.out}/bin/dropbox";
|
||||
ExecReload = "${pkgs.coreutils.out}/bin/kill -HUP $MAINPID";
|
||||
KillMode = "control-group"; # upstream recommends process
|
||||
Restart = "on-failure";
|
||||
PrivateTmp = true;
|
||||
ProtectSystem = "full";
|
||||
Nice = 10;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user