mirror of
https://codeberg.org/muon/home.git
synced 2026-03-09 03:53:11 +00:00
Review/revert later
This commit is contained in:
parent
f4354da57d
commit
6bb34e1c51
13 changed files with 293 additions and 38 deletions
|
|
@ -1,4 +1,13 @@
|
|||
{ pkgs, lib, config, ... }: {
|
||||
{ pkgs, lib, config, ... }: let
|
||||
# smoop = pkgs.callPackage ./smoop.nix {};
|
||||
|
||||
steam-xinit = pkgs.writeShellScriptBin "steam-xinit" ''
|
||||
${lib.getExe pkgs.steam} &
|
||||
exec ${lib.getExe pkgs.openbox} &
|
||||
exec ${lib.getExe pkgs.xterm}
|
||||
'';
|
||||
|
||||
in {
|
||||
options.mods.containers.steam = {
|
||||
enable = lib.mkEnableOption {
|
||||
default = false;
|
||||
|
|
@ -9,12 +18,6 @@
|
|||
config = lib.mkIf config.mods.containers.steam.enable {
|
||||
mods.containers.enable = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
x2goclient
|
||||
guacamole-client
|
||||
remmina
|
||||
];
|
||||
|
||||
containers.steam = {
|
||||
privateNetwork = true;
|
||||
hostAddress = "192.168.100.10";
|
||||
|
|
@ -33,6 +36,10 @@
|
|||
hostPath = "/mnt/bulk/SteamLibrary/steamapps/appmanifest_386360.acf";
|
||||
isReadOnly = true;
|
||||
};
|
||||
"/home/steam/smoop" = {
|
||||
hostPath = "/home/muon/projects/smoop";
|
||||
isReadOnly = true;
|
||||
};
|
||||
};
|
||||
|
||||
config = { config, pkgs, lib, ... }: {
|
||||
|
|
@ -49,21 +56,66 @@
|
|||
remotePlay.openFirewall = true;
|
||||
};
|
||||
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
xterm
|
||||
glxinfo
|
||||
guacamole-server
|
||||
wget
|
||||
bottles
|
||||
|
||||
openbox
|
||||
steam-xinit
|
||||
# smoop
|
||||
novnc
|
||||
tigervnc
|
||||
xorg.xinit
|
||||
|
||||
|
||||
python3
|
||||
python3Packages.pip
|
||||
python3Packages.virtualenv
|
||||
python3Packages.tkinter
|
||||
python3Packages.xlib
|
||||
python3Packages.pillow
|
||||
python3Packages.python-dotenv
|
||||
python3Packages.pyautogui
|
||||
python3Packages.aiohttp
|
||||
python3Packages.discordpy
|
||||
python3Packages.opencv4
|
||||
stdenv.cc.cc.lib
|
||||
glib
|
||||
libglvnd
|
||||
];
|
||||
|
||||
services.xserver.enable = true;
|
||||
services.xserver.displayManager.sddm.enable = true;
|
||||
services.xserver.desktopManager.plasma5.enable = true;
|
||||
environment.sessionVariables = rec {
|
||||
LD_LIBRARY_PATH =
|
||||
"${pkgs.lib.makeLibraryPath config.environment.systemPackages}:\
|
||||
${pkgs.stdenv.cc.cc.lib.outPath}/lib:$LD_LIBRARY_PATH";
|
||||
};
|
||||
|
||||
services.xrdp.enable = true;
|
||||
services.xrdp.defaultWindowManager = "startplasma-x11";
|
||||
services.xrdp.openFirewall = true;
|
||||
services.xserver.enable = true;
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 6080 ];
|
||||
systemd.services.tiger-vnc = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
ExecStart = ''${pkgs.xorg.xinit}/bin/xinit ${steam-xinit}/bin/steam-xinit -- ${pkgs.tigervnc}/bin/Xvnc :1 SecurityTypes=None'';
|
||||
User = "steam";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services.no-vnc = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
path = [ pkgs.ps pkgs.hostname ];
|
||||
serviceConfig = {
|
||||
ExecStart = ''${pkgs.novnc}/bin/novnc --vnc localhost:5901'';
|
||||
User = "steam";
|
||||
};
|
||||
};
|
||||
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
|
|
@ -71,11 +123,10 @@
|
|||
driSupport32Bit = true;
|
||||
};
|
||||
|
||||
services.x2goserver.enable = true;
|
||||
programs.ssh.forwardX11 = true;
|
||||
# programs.ssh.forwardX11 = true;
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
settings.X11Forwarding = true;
|
||||
# settings.X11Forwarding = true;
|
||||
};
|
||||
|
||||
users.users.steam = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue