lio config in new style
This commit is contained in:
parent
230c1182e1
commit
03465ab505
9 changed files with 1738 additions and 41 deletions
4
components/hm/obs.nix
Normal file
4
components/hm/obs.nix
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
programs.obs-studio.enable = true;
|
||||||
|
}
|
33
components/hm/slicer.nix
Normal file
33
components/hm/slicer.nix
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
|
let
|
||||||
|
orca-slicer-fix = pkgs.stdenv.mkDerivation {
|
||||||
|
name = "orca-slicer";
|
||||||
|
buildInputs = [ pkgs.makeWrapper ];
|
||||||
|
unpackPhase = "true";
|
||||||
|
buildPhase = ''
|
||||||
|
mkdir -p $out/bin
|
||||||
|
makeWrapper ${pkgs.orca-slicer}/bin/orca-slicer $out/bin/orca-slicer \
|
||||||
|
--set WEBKIT_DISABLE_DMABUF_RENDERER 1
|
||||||
|
'';
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
|
mkdir -p $out/share/applications
|
||||||
|
cat > $out/share/applications/orca-slicer.desktop <<EOF
|
||||||
|
[Desktop Entry]
|
||||||
|
Name=Orca Slicer
|
||||||
|
Comment=3D printing slicer
|
||||||
|
Exec=$out/bin/orca-slicer
|
||||||
|
Icon=orca-slicer
|
||||||
|
Terminal=false
|
||||||
|
Type=Application
|
||||||
|
Categories=Graphics;3DGraphics;
|
||||||
|
EOF
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
prusa-slicer
|
||||||
|
orca-slicer-fix
|
||||||
|
];
|
||||||
|
}
|
4
components/nix/steam.nix
Normal file
4
components/nix/steam.nix
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
programs.steam.enable = true;
|
||||||
|
}
|
|
@ -1,33 +1,7 @@
|
||||||
{
|
{
|
||||||
settings,
|
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
{
|
{
|
||||||
imports = [
|
|
||||||
# Users this machine has
|
|
||||||
(settings.usersDir + "/root/configuration.nix")
|
|
||||||
(settings.usersDir + "/josh/configuration.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
# My custom modules
|
|
||||||
mods = {
|
|
||||||
boot_systemd.enable = true;
|
|
||||||
shell_common.enable = true;
|
|
||||||
# de_cosmic.enable = true;
|
|
||||||
audio.enable = true;
|
|
||||||
de_gnome_xorg.enable = true;
|
|
||||||
# de_gnome_wayland.enable = true;
|
|
||||||
neovim.enable = true;
|
|
||||||
tty_caps_esc.enable = true;
|
|
||||||
docker.enable = true;
|
|
||||||
fonts.enable = true;
|
|
||||||
ssh.enable = true;
|
|
||||||
stormd.enable = true;
|
|
||||||
nebula.enable = true;
|
|
||||||
rustdesk.enable = true;
|
|
||||||
saber.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# opening this port for dev purposes
|
# opening this port for dev purposes
|
||||||
networking.firewall.allowedTCPPorts = [
|
networking.firewall.allowedTCPPorts = [
|
||||||
5173 # Vite
|
5173 # Vite
|
||||||
|
|
1530
hosts/lio/flake.lock
generated
Normal file
1530
hosts/lio/flake.lock
generated
Normal file
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1,143 @@
|
||||||
|
{
|
||||||
|
description = "lio system flake";
|
||||||
|
|
||||||
|
inputs = {
|
||||||
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
|
||||||
|
|
||||||
|
mods_common.url = "../../modules/common";
|
||||||
|
mods_common.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
mods_boot_systemd.url = "../../modules/boot_systemd";
|
||||||
|
mods_de_cosmic.url = "../../modules/de_cosmic";
|
||||||
|
mods_de_cosmic.inputs.nixpkgs-stable.follows = "nixpkgs";
|
||||||
|
mods_de_cosmic.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
mods_ros_neovim.url = "../../modules/neovim";
|
||||||
|
mods_ros_stormd.url = "../../modules/stormd";
|
||||||
|
mods_nebula.url = "../../modules/nebula";
|
||||||
|
mods_home-manager.url = "../../modules/home_manager";
|
||||||
|
mods_home-manager.inputs.home-manager.url = "github:rycee/home-manager/release-24.11";
|
||||||
|
mods_home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs =
|
||||||
|
{
|
||||||
|
nixpkgs,
|
||||||
|
...
|
||||||
|
}@inputs:
|
||||||
|
let
|
||||||
|
configuration_name = "lio";
|
||||||
|
lib = nixpkgs.lib;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
nixosConfigurations = {
|
||||||
|
"${configuration_name}" =
|
||||||
|
let
|
||||||
|
auto_modules = builtins.concatMap (
|
||||||
|
input:
|
||||||
|
lib.optionals
|
||||||
|
(builtins.hasAttr "nixosModules" input && builtins.hasAttr "default" input.nixosModules)
|
||||||
|
[
|
||||||
|
input.nixosModules.default
|
||||||
|
]
|
||||||
|
) (builtins.attrValues inputs);
|
||||||
|
in
|
||||||
|
(lib.nixosSystem {
|
||||||
|
modules = [
|
||||||
|
./configuration.nix
|
||||||
|
./hardware-configuration.nix
|
||||||
|
(
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../../components/nix/lua.nix
|
||||||
|
../../components/nix/rust-repl.nix
|
||||||
|
../../components/nix/qflipper.nix
|
||||||
|
../../components/nix/qdirstat.nix
|
||||||
|
../../components/nix/steam.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
# Also allow this key to work for root user, this will let us use this as a remote builder easier
|
||||||
|
users.users.root.openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJN2nsLmAlF6zj5dEBkNSJaqcCya+aB6I0imY8Q5Ew0S nix2lio"
|
||||||
|
];
|
||||||
|
|
||||||
|
mods = {
|
||||||
|
common = {
|
||||||
|
systemName = configuration_name;
|
||||||
|
allowUnfree = true;
|
||||||
|
primaryUser = "josh";
|
||||||
|
docker = true;
|
||||||
|
zsh = true;
|
||||||
|
users = {
|
||||||
|
josh = {
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJN2nsLmAlF6zj5dEBkNSJaqcCya+aB6I0imY8Q5Ew0S nix2lio"
|
||||||
|
];
|
||||||
|
initialPassword = "password1";
|
||||||
|
isNormalUser = true;
|
||||||
|
extraGroups = [
|
||||||
|
"wheel"
|
||||||
|
"networkmanager"
|
||||||
|
"video"
|
||||||
|
"input"
|
||||||
|
];
|
||||||
|
shell = pkgs.zsh;
|
||||||
|
packages = with pkgs; [
|
||||||
|
signal-desktop
|
||||||
|
spotify
|
||||||
|
blender
|
||||||
|
google-chrome
|
||||||
|
discordo
|
||||||
|
discord
|
||||||
|
# nautilus qimgv # file browsing (not needed in cosmic)
|
||||||
|
firefox-esr
|
||||||
|
# freecad
|
||||||
|
# openscad
|
||||||
|
# ladybird
|
||||||
|
# ollama
|
||||||
|
vlc
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
home_manager = {
|
||||||
|
users = {
|
||||||
|
josh = {
|
||||||
|
imports = [
|
||||||
|
../../components/hm/tmux/tmux.nix
|
||||||
|
../../components/hm/alacritty.nix
|
||||||
|
../../components/hm/atuin.nix
|
||||||
|
../../components/hm/direnv.nix
|
||||||
|
../../components/hm/git.nix
|
||||||
|
# ../../components/hm/launcher_rofi.nix # not needed in cosmic
|
||||||
|
../../components/hm/nix_deprecations.nix
|
||||||
|
../../components/hm/obs.nix
|
||||||
|
../../components/hm/postgres.nix
|
||||||
|
../../components/hm/slicer.nix
|
||||||
|
../../components/hm/ssh.nix
|
||||||
|
../../components/hm/starship.nix
|
||||||
|
../../components/hm/zoxide.nix
|
||||||
|
../../components/hm/zsh.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
# root = {
|
||||||
|
# imports = [
|
||||||
|
# ../../components/hm/nix_deprecations.nix
|
||||||
|
# ../../components/hm/postgres.nix
|
||||||
|
# ../../components/hm/starship.nix
|
||||||
|
# ../../components/hm/zoxide.nix
|
||||||
|
# ../../components/hm/zsh.nix
|
||||||
|
# ];
|
||||||
|
# };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
)
|
||||||
|
] ++ auto_modules;
|
||||||
|
specialArgs = {
|
||||||
|
inherit inputs;
|
||||||
|
};
|
||||||
|
});
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
description = "Oren system flake";
|
description = "oren system flake";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
|
||||||
|
@ -75,9 +75,8 @@
|
||||||
];
|
];
|
||||||
shell = pkgs.zsh;
|
shell = pkgs.zsh;
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
# blender
|
signal-desktop
|
||||||
google-chrome
|
google-chrome
|
||||||
# comma
|
|
||||||
discordo
|
discordo
|
||||||
discord
|
discord
|
||||||
# nautilus qimgv # file browsing (not needed in cosmic)
|
# nautilus qimgv # file browsing (not needed in cosmic)
|
||||||
|
|
|
@ -11,21 +11,21 @@
|
||||||
|
|
||||||
# My custom modules
|
# My custom modules
|
||||||
mods = {
|
mods = {
|
||||||
boot_systemd.enable = true;
|
boot_systemd.enable = true; # new
|
||||||
shell_common.enable = true;
|
shell_common.enable = true; # new
|
||||||
# de_cosmic.enable = true;
|
# de_cosmic.enable = true; # TODO
|
||||||
audio.enable = true;
|
audio.enable = true;
|
||||||
de_gnome_xorg.enable = true;
|
de_gnome_xorg.enable = true;
|
||||||
# de_gnome_wayland.enable = true;
|
# de_gnome_wayland.enable = true;
|
||||||
neovim.enable = true;
|
neovim.enable = true; # new
|
||||||
tty_caps_esc.enable = true;
|
tty_caps_esc.enable = true; # new
|
||||||
docker.enable = true;
|
docker.enable = true; # new
|
||||||
fonts.enable = true;
|
fonts.enable = true; # new
|
||||||
ssh.enable = true;
|
ssh.enable = true; # new
|
||||||
stormd.enable = true;
|
stormd.enable = true; # new
|
||||||
nebula.enable = true;
|
nebula.enable = true; # new
|
||||||
rustdesk.enable = true;
|
rustdesk.enable = true; # TODO
|
||||||
saber.enable = true;
|
saber.enable = true; # removed
|
||||||
};
|
};
|
||||||
|
|
||||||
# opening this port for dev purposes
|
# opening this port for dev purposes
|
||||||
|
|
|
@ -53,6 +53,7 @@
|
||||||
};
|
};
|
||||||
docker = mkEnableOption (lib.mdDoc "Enable docker");
|
docker = mkEnableOption (lib.mdDoc "Enable docker");
|
||||||
zsh = mkEnableOption (lib.mdDoc "Enable zsh");
|
zsh = mkEnableOption (lib.mdDoc "Enable zsh");
|
||||||
|
enableSleep = mkEnableOption (lib.mdDoc "Enable auto sleeping");
|
||||||
users = mkOption {
|
users = mkOption {
|
||||||
type = types.attrsOf types.attrs;
|
type = types.attrsOf types.attrs;
|
||||||
default = { };
|
default = { };
|
||||||
|
@ -181,6 +182,15 @@
|
||||||
DefaultTimeoutStopSec=8s
|
DefaultTimeoutStopSec=8s
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
# Turn off sleep
|
||||||
|
systemd.sleep.extraConfig = mkIf (!cfg.enableSleep) ''
|
||||||
|
[Sleep]
|
||||||
|
AllowSuspend=no
|
||||||
|
AllowHibernation=no
|
||||||
|
AllowSuspendThenHibernate=no
|
||||||
|
AllowHybridSleep=no
|
||||||
|
'';
|
||||||
|
|
||||||
# Some basics
|
# Some basics
|
||||||
nixpkgs.config.allowUnfree = cfg.allowUnfree;
|
nixpkgs.config.allowUnfree = cfg.allowUnfree;
|
||||||
nixpkgs.config.allowUnfreePredicate = (pkg: true);
|
nixpkgs.config.allowUnfreePredicate = (pkg: true);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue