This commit is contained in:
Steph 2022-11-21 21:59:09 +01:00
parent 7406df9cf8
commit d6c2ad91fa

View File

@ -114,6 +114,7 @@
nextcloud-client
tootle
dino
pinta
];
};
@ -127,10 +128,11 @@
noto-fonts-emoji
];
virtualisation.docker.enable = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
set-backlight-script
neovim
git
wget
@ -140,6 +142,8 @@
nodejs-18_x
steam-run
schildichat-desktop
docker
docker-compose
ripgrep
bottom
@ -177,6 +181,23 @@
services.power-profiles-daemon.enable = false;
services.tlp.enable = true;
#services.mysql.package = pkgs.mariadb;
#services.mysql.enable = true;
#services.mysql.ensureUsers = [
# {
# name = "steph";
# ensurePermissions = {
# "pixelfed.*" = "ALL PRIVILEGES";
# };
#}
#];
#services.mysql.ensureDatabases = ["pixelfed"];
#services.mysql.initialDatabases = [ {
# name = "pixelfed";
#}
#];
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
@ -337,26 +358,26 @@ $NEW_PROMPT_COMMAND"
};
let set-backlight-script = (writeShellApplication {
systemd.services.setbacklight = let set-backlight-script = (pkgs.writeShellApplication {
name = "set-backlight-script";
text = ''
#!/bin/sh
for d in /sys/class/backlight/*; do
cd $d
cd "$d"
echo $(( $(cat max_brightness) / 2)) > brightness
done
'';
});
in
systemd.services.99setbacklight = {
in {
enable = true;
description = "bar";
unitConfig = {
Type = "simple";
};
serviceConfig = {
ExecStart = "${set-backlight-script}";
ExecStart = "${set-backlight-script}/bin/set-backlight-script";
};
wantedBy = [ "multi-user.target" ];
};