Move Blu-ray drive from sayuri to fuuko
This removes makemkv-specific configuration from sayuri and adds it to fuuko. It also changes the makemkv sandbox to now hardcode fuuko’s configuration.
This commit is contained in:
parent
e4c8012f57
commit
aaaf7d3ccc
|
@ -7,7 +7,7 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
boot = {
|
boot = {
|
||||||
kernelModules = [ "kvm-amd" ];
|
kernelModules = [ "kvm-amd" "sg" ];
|
||||||
extraModulePackages = [ ];
|
extraModulePackages = [ ];
|
||||||
supportedFilesystems = [ "btrfs" ];
|
supportedFilesystems = [ "btrfs" ];
|
||||||
kernelParams = [ "ip=dhcp" ];
|
kernelParams = [ "ip=dhcp" ];
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
};
|
};
|
||||||
initrd = {
|
initrd = {
|
||||||
availableKernelModules = [ "aesni_intel" "ahci" "ehci_pci" "nvme" "sd_mod" "sr_mod" "usb_storage" "usbhid" "xhci_pci" ];
|
availableKernelModules = [ "aesni_intel" "ahci" "ehci_pci" "nvme" "sd_mod" "sr_mod" "usb_storage" "usbhid" "xhci_pci" ];
|
||||||
kernelModules = [ "dm-snapshot" "sg" ];
|
kernelModules = [ "dm-snapshot" ];
|
||||||
luks.devices = {
|
luks.devices = {
|
||||||
root = {
|
root = {
|
||||||
name = "root";
|
name = "root";
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
extraGroups = [
|
extraGroups = [
|
||||||
"adbusers"
|
"adbusers"
|
||||||
|
"cdrom"
|
||||||
"corectrl"
|
"corectrl"
|
||||||
"dialout"
|
"dialout"
|
||||||
"keys"
|
"keys"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ lib, nixosConfig, pkgs, ... }:
|
{ lib, nixosConfig, pkgs, ... }:
|
||||||
let
|
let
|
||||||
# TODO: Do not hardcode /dev/{sr0,sg2} (right paths on sayuri)
|
# TODO: Do not hardcode /dev/{sr0,sg1} (right paths on fuuko)
|
||||||
makemkv-sandbox = pkgs.writeShellScriptBin "makemkv-sandbox" /* bash */ ''
|
makemkv-sandbox = pkgs.writeShellScriptBin "makemkv-sandbox" /* bash */ ''
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
mkdir -p $HOME/.MakeMKV
|
mkdir -p $HOME/.MakeMKV
|
||||||
|
@ -9,25 +9,23 @@ let
|
||||||
--proc /proc \
|
--proc /proc \
|
||||||
--dev /dev \
|
--dev /dev \
|
||||||
--unshare-all \
|
--unshare-all \
|
||||||
|
--share-net \
|
||||||
--die-with-parent \
|
--die-with-parent \
|
||||||
--ro-bind /nix/store /nix/store \
|
--ro-bind /nix/store /nix/store \
|
||||||
--dev-bind /dev/dri /dev/dri \
|
|
||||||
--ro-bind /sys/dev/char /sys/dev/char \
|
|
||||||
--ro-bind /sys/devices/pci0000:00 /sys/devices/pci0000:00 \
|
--ro-bind /sys/devices/pci0000:00 /sys/devices/pci0000:00 \
|
||||||
--ro-bind $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY \
|
--ro-bind $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY $XDG_RUNTIME_DIR/$WAYLAND_DISPLAY \
|
||||||
--ro-bind /run/opengl-driver /run/opengl-driver \
|
|
||||||
--ro-bind /etc/fonts /etc/fonts \
|
|
||||||
--new-session \
|
--new-session \
|
||||||
--bind $HOME/.MakeMKV $HOME/.MakeMKV \
|
--bind $HOME/.MakeMKV $HOME/.MakeMKV \
|
||||||
--dev-bind-try /dev/sr0 /dev/sr0 \
|
--dev-bind-try /dev/sr0 /dev/sr0 \
|
||||||
--dev-bind-try /dev/sg2 /dev/sg2 \
|
--dev-bind-try /dev/sg1 /dev/sg1 \
|
||||||
--dev-bind-try /sys/bus/scsi /sys/bus/scsi \
|
--dev-bind-try /sys/bus/scsi /sys/bus/scsi \
|
||||||
--bind ''${PWD_TARGET:-$PWD} ''${PWD_TARGET:-$PWD} \
|
--bind ''${PWD_TARGET:-$PWD} ''${PWD_TARGET:-$PWD} \
|
||||||
${pkgs.unstable.makemkv}/bin/makemkv
|
${pkgs.unstable.makemkv}/bin/makemkv
|
||||||
'';
|
'';
|
||||||
in
|
in
|
||||||
lib.mkIf (nixosConfig.sbruder.gui.enable && nixosConfig.sbruder.unfree.allowSoftware) {
|
lib.mkIf ((nixosConfig.sbruder.gui.enable || nixosConfig.networking.hostName == "fuuko") && nixosConfig.sbruder.unfree.allowSoftware) {
|
||||||
home.packages = [
|
home.packages = with pkgs; [
|
||||||
makemkv-sandbox
|
makemkv-sandbox
|
||||||
|
waypipe
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue