1 { lib, pkgs, config, ... }:
4 myServices.pub.enable = lib.mkOption {
8 Whether to enable pub user.
13 config = lib.mkIf config.myServices.pub.enable {
14 myServices.ssh.modules = [{
15 snippet = builtins.readFile ./ldap_pub.sh;
16 dependencies = [ pkgs.coreutils ];
18 services.duplyBackup.profiles.pub = {
19 rootDir = "/var/lib/pub";
20 remotes = [ "eriomem" "ovh" ];
23 restrict = pkgs.runCommand "restrict" {
25 buildInputs = [ pkgs.makeWrapper ];
28 cp $file $out/bin/restrict
29 chmod a+x $out/bin/restrict
30 patchShebangs $out/bin/restrict
31 wrapProgram $out/bin/restrict \
32 --prefix PATH : ${lib.makeBinPath [ pkgs.bubblewrap pkgs.rrsync ]} \
33 --set TMUX_RESTRICT ${./tmux.restrict.conf}
35 purple-hangouts = pkgs.purple-hangouts.overrideAttrs(old: {
37 install -Dm755 -t $out/lib/purple-2/ libhangouts.so
38 for size in 16 22 24 48; do
39 install -TDm644 hangouts$size.png $out/share/pixmaps/pidgin/protocols/$size/hangouts.png
45 description = "Restricted shell user";
46 home = "/var/lib/pub";
47 uid = config.myEnv.users.pub.uid;
48 useDefaultShell = true;
52 (pkgs.pidgin.override { plugins = [
53 pkgs.purple-plugin-pack purple-hangouts
54 pkgs.purple-discord pkgs.purple-facebook