tv weechat-server: init
This commit is contained in:
parent
f9adf3af97
commit
90b1515dcd
24
tv/2configs/weechat-server.nix
Normal file
24
tv/2configs/weechat-server.nix
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
{ config, pkgs, ... }: {
|
||||||
|
users.users.tv.packages = [
|
||||||
|
(pkgs.writers.writeDashBin "weechat-client" ''
|
||||||
|
set -efu
|
||||||
|
exec ${pkgs.tmux}/bin/tmux attach -t weechat
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
systemd.services.weechat = {
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
environment = {
|
||||||
|
TERM = "rxvt-unicode-256color";
|
||||||
|
};
|
||||||
|
serviceConfig = {
|
||||||
|
ExecStart = "${pkgs.tmux}/bin/tmux new -d -s weechat ${pkgs.weechat}/bin/weechat";
|
||||||
|
OOMScoreAdjust = -1000;
|
||||||
|
Restart = "always";
|
||||||
|
RestartSec = "100ms";
|
||||||
|
Type = "forking";
|
||||||
|
StartLimitBurst = 0;
|
||||||
|
User = "tv";
|
||||||
|
WorkingDirectory = "/home/tv";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user