summaryrefslogtreecommitdiffstats
path: root/makefu/2configs/gui/wbob-kiosk.nix
diff options
context:
space:
mode:
authorjeschli <jeschli@gmail.com>2018-12-04 19:27:27 +0100
committerjeschli <jeschli@gmail.com>2018-12-04 19:27:27 +0100
commit5030b74cc5c578bb82619a24592504a6008f1a10 (patch)
tree0551e3ddb94353b7438bec02174bf3379bc89b87 /makefu/2configs/gui/wbob-kiosk.nix
parent78b289201987675844aa37abeb4279eb4051ebe0 (diff)
parent82988de84c177c247ebbe80940c4d50b9f073b4e (diff)
Merge branch 'master' of prism.r:stockholm
Diffstat (limited to 'makefu/2configs/gui/wbob-kiosk.nix')
-rw-r--r--makefu/2configs/gui/wbob-kiosk.nix32
1 files changed, 24 insertions, 8 deletions
diff --git a/makefu/2configs/gui/wbob-kiosk.nix b/makefu/2configs/gui/wbob-kiosk.nix
index 7db749227..6da1a37e7 100644
--- a/makefu/2configs/gui/wbob-kiosk.nix
+++ b/makefu/2configs/gui/wbob-kiosk.nix
@@ -4,22 +4,38 @@
imports = [
./base.nix
];
- users.users.makefu.packages = [ pkgs.chromium ];
+ users.users.makefu = {
+ packages = [ pkgs.chromium ];
+ extraGroups = [ "audio" "pulse" ];
+ };
services.xserver = {
- layout = lib.mkForce "de";
- xkbVariant = lib.mkForce "";
windowManager = lib.mkForce {
awesome.enable = false;
default = "none";
};
- desktopManager.xfce.enable = true;
+ desktopManager.xfce = {
+ extraSessionCommands = ''
+ ${pkgs.xlibs.xset}/bin/xset -display :0 s off -dpms
+ ${pkgs.xlibs.xrandr}/bin/xrandr --output HDMI2 --right-of HDMI1
+ '';
+ enable = true;
+ };
# xrandrHeads = [ "HDMI1" "HDMI2" ];
# prevent screen from turning off, disable dpms
- displayManager.sessionCommands = ''
- xset -display :0 s off -dpms
- xrandr --output HDMI2 --right-of HDMI1
- '';
};
+
+ systemd.services.xset-off = {
+ after = [ "display-manager.service" ];
+ wantedBy = [ "multi-user.target" ];
+ serviceConfig = {
+ ExecStart = "${pkgs.xlibs.xset}/bin/xset -display :0 s off -dpms";
+ RemainAfterExit = "yes";
+ TimeoutSec = "5s";
+ RestartSec="5s";
+ Restart = "on-failure";
+ };
+ };
+
}