Enable RetroArch on Steam Deck
This commit is contained in:
parent
202e5c098a
commit
8534c96c66
17 changed files with 127 additions and 113 deletions
|
|
@ -16,13 +16,6 @@ with lib; {
|
|||
The home directory for the default user.
|
||||
'';
|
||||
};
|
||||
wildcard = mkOption {
|
||||
type = types.str;
|
||||
default = "0.0.0.0";
|
||||
description = ''
|
||||
The localhost address.
|
||||
'';
|
||||
};
|
||||
localhost = mkOption {
|
||||
type = types.str;
|
||||
default = "127.0.0.1";
|
||||
|
|
@ -52,6 +45,13 @@ with lib; {
|
|||
The post master email address.
|
||||
'';
|
||||
};
|
||||
privateKeyFiles = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = if config.services.openssh.enable then builtins.map (key: key.path) config.services.openssh.hostKeys else [ "/root/.ssh/${config.networking.hostName}" ];
|
||||
description = ''
|
||||
The private key files for sops.
|
||||
'';
|
||||
};
|
||||
publicKeys = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [
|
||||
|
|
@ -61,13 +61,6 @@ with lib; {
|
|||
The public keys for SSH authentication.
|
||||
'';
|
||||
};
|
||||
privateKeyFiles = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = if config.services.openssh.enable then builtins.map (key: key.path) config.services.openssh.hostKeys else [ "/root/.ssh/${config.networking.hostName}" ];
|
||||
description = ''
|
||||
The private key files for sops.
|
||||
'';
|
||||
};
|
||||
sopsFile = mkOption {
|
||||
type = types.path;
|
||||
default = ./secrets.yaml;
|
||||
|
|
@ -75,6 +68,17 @@ with lib; {
|
|||
The secrets file for device.
|
||||
'';
|
||||
};
|
||||
syncthingDevices = mkOption {
|
||||
type = types.attrsOf (types.attrsOf types.str);
|
||||
default = {
|
||||
blitzar.id = "KGCBCIZ-GG6KMQ2-FLK5BWW-GLCEDML-5LCI24S-UKO5UWL-HWNCPYX-ZWWD5AQ";
|
||||
nebula.id = "NJXA5XS-2PSWECD-UHBV7JH-IR2RSWY-PRUPFTZ-AHL7IN6-RXSLZKB-2FUNRQH";
|
||||
protostar.id = "MEEIJ3F-NYIB55Y-SDCWCLX-6XOR6YU-OQO477W-JAPG6F6-LRBGBGG-FENYPQE";
|
||||
};
|
||||
description = ''
|
||||
The device information for syncthing
|
||||
'';
|
||||
};
|
||||
userName = mkOption {
|
||||
type = types.str;
|
||||
default = "macronova";
|
||||
|
|
@ -82,5 +86,12 @@ with lib; {
|
|||
The username across all devices.
|
||||
'';
|
||||
};
|
||||
wildcard = mkOption {
|
||||
type = types.str;
|
||||
default = "0.0.0.0";
|
||||
description = ''
|
||||
The localhost address.
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
let
|
||||
home = config.constants.homeDir;
|
||||
usr = config.constants.userName;
|
||||
usrPwdFile = "users/${usr}/password";
|
||||
in
|
||||
|
|
@ -89,6 +90,15 @@ in
|
|||
};
|
||||
};
|
||||
resolved.enable = true;
|
||||
syncthing = {
|
||||
configDir = "${home}/.config/syncthing";
|
||||
dataDir = "${home}/.local/share/syncthing";
|
||||
openDefaultPorts = true;
|
||||
overrideDevices = true;
|
||||
overrideFolders = true;
|
||||
settings.devices = config.constants.syncthingDevices;
|
||||
user = usr;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets.${usrPwdFile}.neededForUsers = true;
|
||||
|
|
|
|||
36
flake.lock
generated
36
flake.lock
generated
|
|
@ -21,11 +21,11 @@
|
|||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709286488,
|
||||
"narHash": "sha256-RDpTZ72zLu05djvXRzK76Ysqp9zSdh84ax/edEaJucs=",
|
||||
"lastModified": 1709439398,
|
||||
"narHash": "sha256-MW0zp3ta7SvdpjvhVCbtP20ewRwQZX2vRFn14gTc4Kg=",
|
||||
"owner": "nix-community",
|
||||
"repo": "disko",
|
||||
"rev": "bde7dd352c07d43bd5b8245e6c39074a391fdd46",
|
||||
"rev": "1f76b318aa11170c8ca8c225a9b4c458a5fcbb57",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -70,11 +70,11 @@
|
|||
},
|
||||
"hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1709147990,
|
||||
"narHash": "sha256-vpXMWoaCtMYJ7lisJedCRhQG9BSsInEyZnnG5GfY9tQ=",
|
||||
"lastModified": 1709410583,
|
||||
"narHash": "sha256-esOSUoQ7mblwcsSea0K17McZuwAIjoS6dq/4b83+lvw=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "33a97b5814d36ddd65ad678ad07ce43b1a67f159",
|
||||
"rev": "59e37017b9ed31dee303dbbd4531c594df95cfbc",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -88,11 +88,11 @@
|
|||
"nixpkgs": "nixpkgs_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709204054,
|
||||
"narHash": "sha256-U1idK0JHs1XOfSI1APYuXi4AEADf+B+ZU4Wifc0pBHk=",
|
||||
"lastModified": 1709485962,
|
||||
"narHash": "sha256-rmFB4uE10+LJbcVE4ePgiuHOBlUIjQOeZt4VQVJTU8M=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "2f3367769a93b226c467551315e9e270c3f78b15",
|
||||
"rev": "d579633ff9915a8f4058d5c439281097e92380a8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -253,11 +253,11 @@
|
|||
},
|
||||
"nixpkgs-stable": {
|
||||
"locked": {
|
||||
"lastModified": 1708819810,
|
||||
"narHash": "sha256-1KosU+ZFXf31GPeCBNxobZWMgHsSOJcrSFA6F2jhzdE=",
|
||||
"lastModified": 1709428628,
|
||||
"narHash": "sha256-//ZCCnpVai/ShtO2vPjh3AWgo8riXCaret6V9s7Hew4=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "89a2a12e6c8c6a56c72eb3589982c8e2f89c70ea",
|
||||
"rev": "66d65cb00b82ffa04ee03347595aa20e41fe3555",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -364,11 +364,11 @@
|
|||
},
|
||||
"nixpkgs_8": {
|
||||
"locked": {
|
||||
"lastModified": 1708751719,
|
||||
"narHash": "sha256-0uWOKSpXJXmXswOvDM5Vk3blB74apFB6rNGWV5IjoN0=",
|
||||
"lastModified": 1709356872,
|
||||
"narHash": "sha256-mvxCirJbtkP0cZ6ABdwcgTk0u3bgLoIoEFIoYBvD6+4=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "f63ce824cd2f036216eb5f637dfef31e1a03ee89",
|
||||
"rev": "458b097d81f90275b3fdf03796f0563844926708",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -397,11 +397,11 @@
|
|||
"nixpkgs-stable": "nixpkgs-stable"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1708987867,
|
||||
"narHash": "sha256-k2lDaDWNTU5sBVHanYzjDKVDmk29RHIgdbbXu5sdzBA=",
|
||||
"lastModified": 1709434911,
|
||||
"narHash": "sha256-UN47hQPM9ijwoz7cYq10xl19hvlSP/232+M5vZDOMs4=",
|
||||
"owner": "Mic92",
|
||||
"repo": "sops-nix",
|
||||
"rev": "a1c8de14f60924fafe13aea66b46157f0150f4cf",
|
||||
"rev": "075df9d85ee70cfb53e598058045e1738f05e273",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
imports = with inputs; [
|
||||
disko.nixosModules.default
|
||||
hardware.nixosModules.asus-zephyrus-ga402
|
||||
] ++ [
|
||||
../../common
|
||||
./audio.nix
|
||||
./configuration.nix
|
||||
./device.nix
|
||||
|
|
@ -16,6 +16,5 @@
|
|||
./syncthing.nix
|
||||
./tailscale.nix
|
||||
./zfs.nix
|
||||
../../common
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ let usr = config.constants.userName; in {
|
|||
let xdgCfg = config.xdg; in {
|
||||
gtk = {
|
||||
enable = true;
|
||||
gtk2.configLocation = "${xdgCfg.configHome}/gtk-2.0/gtkrc";
|
||||
theme = {
|
||||
name = "Sweet-Dark";
|
||||
package = pkgs.sweet;
|
||||
|
|
|
|||
|
|
@ -1,28 +1,14 @@
|
|||
{ config, ... }:
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
services.syncthing = let home = config.constants.homeDir; in {
|
||||
services.syncthing = {
|
||||
enable = true;
|
||||
configDir = "${home}/.config/syncthing";
|
||||
dataDir = "${home}/.local/share/syncthing";
|
||||
openDefaultPorts = true;
|
||||
overrideDevices = true;
|
||||
overrideFolders = true;
|
||||
settings = let media = "nebula"; in {
|
||||
devices.${media} = {
|
||||
name = media;
|
||||
id = "NJXA5XS-2PSWECD-UHBV7JH-IR2RSWY-PRUPFTZ-AHL7IN6-RXSLZKB-2FUNRQH";
|
||||
};
|
||||
folders.music = {
|
||||
enable = true;
|
||||
devices = [ media ];
|
||||
id = "Music";
|
||||
label = "Music";
|
||||
path = "~/Music";
|
||||
type = "sendonly";
|
||||
};
|
||||
settings.folders.music = {
|
||||
enable = true;
|
||||
devices = [ "nebula" ];
|
||||
path = "~/Music";
|
||||
type = "sendonly";
|
||||
};
|
||||
user = config.constants.userName;
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -3,11 +3,10 @@
|
|||
{
|
||||
imports = with inputs; [
|
||||
hardware.nixosModules.common-cpu-intel
|
||||
] ++ [
|
||||
../../common
|
||||
./configuration.nix
|
||||
./hardware-configuration.nix
|
||||
./network.nix
|
||||
./tailscale.nix
|
||||
../../common
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
disko.nixosModules.default
|
||||
hardware.nixosModules.common-cpu-amd
|
||||
hardware.nixosModules.common-cpu-amd-pstate
|
||||
] ++ [
|
||||
../../common
|
||||
./conduit.nix
|
||||
./configuration.nix
|
||||
./disko.nix
|
||||
|
|
@ -16,6 +16,5 @@
|
|||
./syncthing.nix
|
||||
./tailscale.nix
|
||||
./zfs.nix
|
||||
../../common
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@
|
|||
wifi.backend = "iwd";
|
||||
};
|
||||
nftables.enable = true;
|
||||
tempAddresses = "disabled";
|
||||
wireless.iwd.enable = true;
|
||||
};
|
||||
services.openssh.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,27 +1,13 @@
|
|||
{ config, ... }:
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
services.syncthing = let home = config.constants.homeDir; in {
|
||||
services.syncthing = {
|
||||
enable = true;
|
||||
configDir = "${home}/.config/syncthing";
|
||||
dataDir = "${home}/.local/share/syncthing";
|
||||
openDefaultPorts = true;
|
||||
overrideDevices = true;
|
||||
overrideFolders = true;
|
||||
settings = let pc = "blitzar"; in {
|
||||
devices.${pc} = {
|
||||
name = pc;
|
||||
id = "KGCBCIZ-GG6KMQ2-FLK5BWW-GLCEDML-5LCI24S-UKO5UWL-HWNCPYX-ZWWD5AQ";
|
||||
};
|
||||
folders.music = {
|
||||
enable = true;
|
||||
devices = [ pc ];
|
||||
id = "Music";
|
||||
label = "Music";
|
||||
path = "~/Music";
|
||||
type = "receiveonly";
|
||||
};
|
||||
settings.folders.music = {
|
||||
enable = true;
|
||||
devices = [ "blitzar" ];
|
||||
path = "~/Music";
|
||||
type = "receiveonly";
|
||||
};
|
||||
user = config.constants.userName;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,10 +6,13 @@
|
|||
|
||||
{
|
||||
# Configuration boot
|
||||
boot.loader = {
|
||||
efi.canTouchEfiVariables = true;
|
||||
systemd-boot.enable = true;
|
||||
timeout = 0;
|
||||
boot = {
|
||||
initrd.systemd.enable = true;
|
||||
loader = {
|
||||
efi.canTouchEfiVariables = true;
|
||||
systemd-boot.enable = true;
|
||||
timeout = 0;
|
||||
};
|
||||
};
|
||||
|
||||
# Change secrets file
|
||||
|
|
|
|||
|
|
@ -4,15 +4,15 @@
|
|||
imports = with inputs; [
|
||||
disko.nixosModules.default
|
||||
jovian.nixosModules.default
|
||||
] ++ [
|
||||
../../common
|
||||
./configuration.nix
|
||||
./disko.nix
|
||||
./gui.nix
|
||||
./hardware-configuration.nix
|
||||
./locale.nix
|
||||
./network.nix
|
||||
./syncthing.nix
|
||||
./tailscale.nix
|
||||
./zfs.nix
|
||||
../../common
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,18 +1,30 @@
|
|||
{ config, ... }:
|
||||
{ config, inputs, pkgs, ... }:
|
||||
|
||||
let usr = config.constants.userName; in {
|
||||
let
|
||||
usr = config.constants.userName;
|
||||
jovianPkgs = pkgs.extend inputs.jovian.overlays.default;
|
||||
in
|
||||
{
|
||||
home-manager.users.${usr}.home.packages = with jovianPkgs; [
|
||||
(retroarch.override {
|
||||
cores = with libretro; [
|
||||
pcsx2
|
||||
ppsspp
|
||||
];
|
||||
})
|
||||
yuzu
|
||||
];
|
||||
jovian = {
|
||||
decky-loader = {
|
||||
enable = true;
|
||||
user = usr;
|
||||
};
|
||||
devices.steamdeck.enable = true;
|
||||
steam = {
|
||||
enable = true;
|
||||
autoStart = true;
|
||||
desktopSession = "plasma";
|
||||
desktopSession = "gamescope-wayland";
|
||||
user = usr;
|
||||
};
|
||||
};
|
||||
|
||||
services.xserver = {
|
||||
enable = true;
|
||||
desktopManager.plasma6.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
16
linux/protostar/locale.nix
Normal file
16
linux/protostar/locale.nix
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
# Configure default fonts
|
||||
fonts = {
|
||||
fontconfig.defaultFonts = {
|
||||
serif = [ "Noto Serif" "Noto Serif CJK SC" ];
|
||||
sansSerif = [ "Inter" "Noto Sans CJK SC" ];
|
||||
monospace = [ "Iosevka" "Noto Sans Mono CJK SC" ];
|
||||
};
|
||||
packages = with pkgs; [
|
||||
sarasa-gothic
|
||||
noto-fonts-emoji
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
@ -1,10 +1,15 @@
|
|||
{ ... }:
|
||||
{ config, ... }:
|
||||
|
||||
{
|
||||
networking = {
|
||||
firewall.trustedInterfaces = [ config.services.tailscale.interfaceName ];
|
||||
hostId = "74247225";
|
||||
networkmanager.enable = true;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
nftables.enable = true;
|
||||
wireless.iwd.enable = true;
|
||||
};
|
||||
services.openssh.enable = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,18 +1,9 @@
|
|||
{ config, ... }:
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
services.syncthing = let home = config.constants.homeDir; in {
|
||||
services.syncthing = {
|
||||
enable = true;
|
||||
configDir = "${home}/.config/syncthing";
|
||||
dataDir = "${home}/.local/share/syncthing";
|
||||
openDefaultPorts = true;
|
||||
overrideDevices = true;
|
||||
overrideFolders = true;
|
||||
# settings = let pc = "blitzar"; in {
|
||||
# devices.${pc} = {
|
||||
# name = pc;
|
||||
# id = "KGCBCIZ-GG6KMQ2-FLK5BWW-GLCEDML-5LCI24S-UKO5UWL-HWNCPYX-ZWWD5AQ";
|
||||
# };
|
||||
# folders.music = {
|
||||
# enable = true;
|
||||
# devices = [ pc ];
|
||||
|
|
@ -22,6 +13,5 @@
|
|||
# type = "receiveonly";
|
||||
# };
|
||||
# };
|
||||
user = config.constants.userName;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
{ inputs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
inputs.mailserver.nixosModules.default
|
||||
imports = with inputs; [
|
||||
mailserver.nixosModules.default
|
||||
../../common
|
||||
./caddy.nix
|
||||
./configuration.nix
|
||||
./hardware-configuration.nix
|
||||
|
|
@ -10,6 +11,5 @@
|
|||
./mailserver.nix
|
||||
./network.nix
|
||||
./vaultwarden.nix
|
||||
../../common
|
||||
];
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue