Compare commits
No commits in common. "4664804d9091b4fb2b27acb03848c8e64d41f5f2" and "5a5d34911cf866ac37d84c6043a645920f37f795" have entirely different histories.
4664804d90
...
5a5d34911c
@ -64,23 +64,6 @@
|
|||||||
# force: true
|
# force: true
|
||||||
# diff: false
|
# diff: false
|
||||||
|
|
||||||
- name: Create directories
|
|
||||||
file:
|
|
||||||
name: "{{ item }}"
|
|
||||||
state: directory
|
|
||||||
mode: 0700
|
|
||||||
owner: nochainstounlock
|
|
||||||
group: nochainstounlock
|
|
||||||
loop:
|
|
||||||
- /home/nochainstounlock/.ssh
|
|
||||||
|
|
||||||
- name: Set authorized keys
|
|
||||||
authorized_key:
|
|
||||||
user: nochainstounlock
|
|
||||||
key: |
|
|
||||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMrjXsXjtxEm47XnRZfo67kJULoc0NBLrB0lPYFiS2Ar kodi@neelix
|
|
||||||
exclusive: true
|
|
||||||
|
|
||||||
- import_tasks: tasks/freebsd.yaml
|
- import_tasks: tasks/freebsd.yaml
|
||||||
when: 'os_flavor == "freebsd"'
|
when: 'os_flavor == "freebsd"'
|
||||||
|
|
||||||
|
@ -57,8 +57,6 @@
|
|||||||
./roles/chromecast
|
./roles/chromecast
|
||||||
./roles/memtest86
|
./roles/memtest86
|
||||||
./roles/kodi
|
./roles/kodi
|
||||||
./roles/ansible
|
|
||||||
./roles/bluetooth
|
|
||||||
];
|
];
|
||||||
|
|
||||||
nix.settings.experimental-features = [
|
nix.settings.experimental-features = [
|
||||||
|
@ -29,5 +29,4 @@
|
|||||||
me.graphicsCardType = "intel";
|
me.graphicsCardType = "intel";
|
||||||
|
|
||||||
me.kodi.enable = true;
|
me.kodi.enable = true;
|
||||||
me.bluetooth.enable = true;
|
|
||||||
}
|
}
|
||||||
|
@ -33,5 +33,4 @@
|
|||||||
me.graphicsCardType = "amd";
|
me.graphicsCardType = "amd";
|
||||||
|
|
||||||
me.sway.enable = true;
|
me.sway.enable = true;
|
||||||
me.ansible.enable = true;
|
|
||||||
}
|
}
|
||||||
|
@ -1,46 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports = [ ];
|
|
||||||
|
|
||||||
options.me = {
|
|
||||||
ansible.enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = false;
|
|
||||||
example = true;
|
|
||||||
description = "Whether we want to install ansible.";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = lib.mkIf config.me.ansible.enable (
|
|
||||||
lib.mkMerge [
|
|
||||||
{
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
ansible
|
|
||||||
];
|
|
||||||
|
|
||||||
nixpkgs.overlays = [
|
|
||||||
(final: prev: {
|
|
||||||
ansible = pkgs.symlinkJoin {
|
|
||||||
name = "ansible";
|
|
||||||
paths = [
|
|
||||||
(prev.ansible.overridePythonAttrs {
|
|
||||||
propagatedBuildInputs = prev.ansible.propagatedBuildInputs ++ [ prev.python3Packages.jmespath ];
|
|
||||||
})
|
|
||||||
];
|
|
||||||
buildInputs = [ pkgs.makeWrapper ];
|
|
||||||
postBuild = ''
|
|
||||||
wrapProgram $out/bin/ansible --prefix PATH : ${lib.makeBinPath [ ]}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
|
||||||
}
|
|
||||||
]
|
|
||||||
);
|
|
||||||
}
|
|
@ -1,46 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports = [ ];
|
|
||||||
|
|
||||||
options.me = {
|
|
||||||
bluetooth.enable = lib.mkOption {
|
|
||||||
type = lib.types.bool;
|
|
||||||
default = false;
|
|
||||||
example = true;
|
|
||||||
description = "Whether we want to install bluetooth.";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = lib.mkIf config.me.bluetooth.enable (
|
|
||||||
lib.mkMerge [
|
|
||||||
{
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
];
|
|
||||||
|
|
||||||
hardware.bluetooth = {
|
|
||||||
enable = true;
|
|
||||||
powerOnBoot = true;
|
|
||||||
settings = {
|
|
||||||
General = {
|
|
||||||
# Enable support for showing battery charge level.
|
|
||||||
Experimental = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.persistence."/persist" = lib.mkIf (!config.me.buildingIso) {
|
|
||||||
hideMounts = true;
|
|
||||||
directories = [
|
|
||||||
"/var/lib/bluetooth" # Bluetooth pairing information.
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
]
|
|
||||||
);
|
|
||||||
}
|
|
@ -41,8 +41,6 @@
|
|||||||
# Automatically delete old generations
|
# Automatically delete old generations
|
||||||
boot.loader.systemd-boot.configurationLimit = 3;
|
boot.loader.systemd-boot.configurationLimit = 3;
|
||||||
|
|
||||||
boot.loader.systemd-boot.memtest86.enable = true;
|
|
||||||
|
|
||||||
# Check what will be lost with `zfs diff zroot/linux/root@blank`
|
# Check what will be lost with `zfs diff zroot/linux/root@blank`
|
||||||
boot.initrd.systemd.enable = lib.mkDefault true;
|
boot.initrd.systemd.enable = lib.mkDefault true;
|
||||||
boot.initrd.systemd.services.zfs-rollback = {
|
boot.initrd.systemd.services.zfs-rollback = {
|
||||||
|
@ -24,75 +24,10 @@
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
(lib.mkIf config.me.graphical {
|
(lib.mkIf config.me.graphical {
|
||||||
|
users.extraUsers.kodi.isNormalUser = true;
|
||||||
services.cage.user = "kodi";
|
services.cage.user = "kodi";
|
||||||
services.cage.program = "${pkgs.kodi-wayland}/bin/kodi-standalone";
|
services.cage.program = "${pkgs.kodi-wayland}/bin/kodi-standalone";
|
||||||
services.cage.enable = true;
|
services.cage.enable = true;
|
||||||
|
|
||||||
nixpkgs.overlays = [
|
|
||||||
(final: prev: {
|
|
||||||
kodi-wayland = prev.kodi-wayland.withPackages (
|
|
||||||
kodiPkgs: with kodiPkgs; [
|
|
||||||
joystick
|
|
||||||
vfs-sftp
|
|
||||||
]
|
|
||||||
);
|
|
||||||
})
|
|
||||||
];
|
|
||||||
|
|
||||||
users.users.kodi = {
|
|
||||||
isNormalUser = true;
|
|
||||||
createHome = true; # https://github.com/NixOS/nixpkgs/issues/6481
|
|
||||||
group = "kodi";
|
|
||||||
extraGroups = [ ];
|
|
||||||
uid = 12000;
|
|
||||||
packages = with pkgs; [
|
|
||||||
tree
|
|
||||||
];
|
|
||||||
# Generate with `mkpasswd -m scrypt`
|
|
||||||
hashedPassword = "$7$CU..../....VXvNQ8za3wSGpdzGXNT50/$HcFtn/yvwPMCw4888BelpiAPLAxe/zU87fD.d/N6U48";
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGu+k5lrirokdW5zVdRVBOqEOAvAPlIkG/MdJNc9g5ky"
|
|
||||||
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIEI6mu6I5Jp+Ib0vJxapGHbEShZjyvzV8jz5DnzDrI39AAAABHNzaDo="
|
|
||||||
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIAFNcSXwvy+brYTOGo56G93Ptuq2MmZsjvRWAfMqbmMLAAAABHNzaDo="
|
|
||||||
];
|
|
||||||
};
|
|
||||||
users.groups.kodi.gid = 12000;
|
|
||||||
|
|
||||||
environment.persistence."/persist" = lib.mkIf (!config.me.buildingIso) {
|
|
||||||
hideMounts = true;
|
|
||||||
users.kodi = {
|
|
||||||
directories = [
|
|
||||||
{
|
|
||||||
directory = ".ssh";
|
|
||||||
user = "kodi";
|
|
||||||
group = "kodi";
|
|
||||||
mode = "0755";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
directory = ".kodi";
|
|
||||||
user = "kodi";
|
|
||||||
group = "kodi";
|
|
||||||
mode = "0755";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home-manager.users.kodi =
|
|
||||||
{ pkgs, ... }:
|
|
||||||
{
|
|
||||||
# home.file.".kodi/userdata/mediasources.xml".source = ./files/mediasources.xml;
|
|
||||||
|
|
||||||
# home.file.".kodi/userdata/addon_data/peripheral.joystick/resources/buttonmaps/xml/linux/DualSense_Wireless_Controller_13b_8a.xml".source =
|
|
||||||
# ./files/DualSense_Wireless_Controller_13b_8a.xml;
|
|
||||||
|
|
||||||
# TODO: Maybe .kodi/userdata/sources.xml
|
|
||||||
# TODO: ./userdata/guisettings.xml:303: <setting id="filecache.memorysize">128</setting>
|
|
||||||
|
|
||||||
# The state version is required and should stay at the version you
|
|
||||||
# originally installed.
|
|
||||||
home.stateVersion = "24.11";
|
|
||||||
};
|
|
||||||
})
|
})
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
@ -1,38 +0,0 @@
|
|||||||
<?xml version="1.0" ?>
|
|
||||||
<buttonmap>
|
|
||||||
<device name="DualSense Wireless Controller" provider="linux" buttoncount="13" axiscount="8">
|
|
||||||
<configuration>
|
|
||||||
<axis index="2" center="-1" range="2" />
|
|
||||||
<axis index="5" center="-1" range="2" />
|
|
||||||
</configuration>
|
|
||||||
<controller id="game.controller.default">
|
|
||||||
<feature name="a" button="0" />
|
|
||||||
<feature name="b" button="1" />
|
|
||||||
<feature name="back" button="9" />
|
|
||||||
<feature name="down" axis="+7" />
|
|
||||||
<feature name="guide" button="10" />
|
|
||||||
<feature name="left" axis="-6" />
|
|
||||||
<feature name="leftbumper" button="4" />
|
|
||||||
<feature name="leftstick">
|
|
||||||
<up axis="-1" />
|
|
||||||
<down axis="+1" />
|
|
||||||
<right axis="+0" />
|
|
||||||
<left axis="-0" />
|
|
||||||
</feature>
|
|
||||||
<feature name="lefttrigger" button="6" />
|
|
||||||
<feature name="right" axis="+6" />
|
|
||||||
<feature name="rightbumper" button="5" />
|
|
||||||
<feature name="rightstick">
|
|
||||||
<up axis="-4" />
|
|
||||||
<down axis="+4" />
|
|
||||||
<right axis="+3" />
|
|
||||||
<left axis="-3" />
|
|
||||||
</feature>
|
|
||||||
<feature name="righttrigger" button="7" />
|
|
||||||
<feature name="start" button="8" />
|
|
||||||
<feature name="up" axis="-7" />
|
|
||||||
<feature name="x" button="3" />
|
|
||||||
<feature name="y" button="2" />
|
|
||||||
</controller>
|
|
||||||
</device>
|
|
||||||
</buttonmap>
|
|
@ -1,5 +0,0 @@
|
|||||||
<mediasources>
|
|
||||||
<network>
|
|
||||||
<location id="0">sftp://nochainstounlock@stuff.fizz.buzz:42069/readonly/library/</location>
|
|
||||||
</network>
|
|
||||||
</mediasources>
|
|
Loading…
x
Reference in New Issue
Block a user