Merge pull request #48131 from Ma27/weechat-multiuser-support

nixos/weechat: add setuid wrapper for `screen' to ensure true multiuser capabilities
This commit is contained in:
Maximilian Bosch 2018-10-17 23:39:30 +02:00 committed by GitHub
commit 13e4110650
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -46,10 +46,12 @@ in
Group = "weechat"; Group = "weechat";
RemainAfterExit = "yes"; RemainAfterExit = "yes";
}; };
script = "exec ${pkgs.screen}/bin/screen -Dm -S ${cfg.sessionName} ${cfg.binary}"; script = "exec ${config.security.wrapperDir}/screen -Dm -S ${cfg.sessionName} ${cfg.binary}";
wantedBy = [ "multi-user.target" ]; wantedBy = [ "multi-user.target" ];
wants = [ "network.target" ]; wants = [ "network.target" ];
}; };
security.wrappers.screen.source = "${pkgs.screen}/bin/screen";
}; };
meta.doc = ./weechat.xml; meta.doc = ./weechat.xml;

View File

@ -54,7 +54,7 @@
</programlisting> </programlisting>
Now, the session can be re-attached like this: Now, the session can be re-attached like this:
<programlisting> <programlisting>
screen -r weechat-screen screen -x weechat/weechat-screen
</programlisting> </programlisting>
</para> </para>