mirror of
https://github.com/kmein/niveum
synced 2026-03-31 01:31:13 +02:00
Compare commits
3 Commits
881aaa3f8c
...
64a59070c4
| Author | SHA1 | Date | |
|---|---|---|---|
| 64a59070c4 | |||
| c68f863bbc | |||
| fa3d41fb5b |
@@ -276,6 +276,10 @@ in {
|
||||
(pkgs.writers.writeDashBin "hass-cli" ''
|
||||
HASS_SERVER=http://zaatar.r:8123 HASS_TOKEN="$(cat ${config.age.secrets.home-assistant-token.path})" exec ${pkgs.home-assistant-cli}/bin/hass-cli "$@"
|
||||
'')
|
||||
|
||||
# xml
|
||||
saxonb_9_1
|
||||
libxml2
|
||||
];
|
||||
|
||||
age.secrets.home-assistant-token = {
|
||||
|
||||
@@ -1,29 +1,10 @@
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (import ../../lib) tmpfilesConfig;
|
||||
in {
|
||||
services.postgresql = {
|
||||
dataDir = "/var/state/postgresql/${config.services.postgresql.package.psqlSchema}";
|
||||
package = pkgs.postgresql_11;
|
||||
};
|
||||
|
||||
{pkgs, ...}: {
|
||||
services.postgresqlBackup = {
|
||||
enable = true;
|
||||
databases = ["atuin"];
|
||||
};
|
||||
|
||||
systemd.tmpfiles.rules = [
|
||||
(tmpfilesConfig {
|
||||
type = "d";
|
||||
path = "/var/state/postgresql";
|
||||
mode = "0700";
|
||||
user = "postgres";
|
||||
group = "postgres";
|
||||
})
|
||||
];
|
||||
services.postgresql.package = pkgs.postgresql_14;
|
||||
|
||||
services.atuin = {
|
||||
host = "0.0.0.0";
|
||||
|
||||
@@ -10,6 +10,7 @@ in {
|
||||
./atuin.nix
|
||||
./backup.nix
|
||||
./gaslight.nix
|
||||
./kiosk.nix
|
||||
./hardware-configuration.nix
|
||||
./moodle-dl-meinhark.nix
|
||||
./pulseaudio.nix
|
||||
@@ -89,5 +90,5 @@ in {
|
||||
retiolum = retiolumAddresses.zaatar;
|
||||
};
|
||||
|
||||
system.stateVersion = "20.09";
|
||||
system.stateVersion = "22.05";
|
||||
}
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
password = "";
|
||||
extraGroups = ["audio"];
|
||||
};
|
||||
# TODO https://github.com/cage-kiosk/cage/issues/138
|
||||
services.cage = {
|
||||
enable = true;
|
||||
user = config.users.extraUsers.kiosk.name;
|
||||
|
||||
@@ -1,15 +1,10 @@
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: {
|
||||
{config, ...}: {
|
||||
services.spotifyd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
global = {
|
||||
username_cmd = "cat ${config.age.secrets.spotify-username.path}";
|
||||
password_cmd = "cat ${config.age.secrets.spotify-password.path}";
|
||||
username_cmd = "cat $CREDENTIALS_DIRECTORY/username";
|
||||
password_cmd = "cat $CREDENTIALS_DIRECTORY/password";
|
||||
backend = "pulseaudio";
|
||||
bitrate = 320;
|
||||
device_type = "s_t_b"; # set-top box
|
||||
@@ -18,6 +13,13 @@
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services.spotifyd = {
|
||||
serviceConfig.LoadCredential = [
|
||||
"username:${config.age.secrets.spotify-username.path}"
|
||||
"password:${config.age.secrets.spotify-password.path}"
|
||||
];
|
||||
};
|
||||
|
||||
age.secrets = {
|
||||
spotify-username.file = ../../secrets/spotify-username.age;
|
||||
spotify-password.file = ../../secrets/spotify-password.age;
|
||||
@@ -28,6 +30,4 @@
|
||||
unload-module module-native-protocol-unix
|
||||
load-module module-native-protocol-unix auth-anonymous=1
|
||||
'';
|
||||
|
||||
systemd.services.spotifyd.serviceConfig.Restart = "always";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user