temp
This commit is contained in:
@@ -17,6 +17,8 @@ in
|
|||||||
|
|
||||||
enableSwap = mkBoolOpt false "Enable swap";
|
enableSwap = mkBoolOpt false "Enable swap";
|
||||||
|
|
||||||
|
enableLuks = mkBoolOpt false "Enable Luks";
|
||||||
|
|
||||||
swapSize = mkOpt types.str "16G" "size of swap part";
|
swapSize = mkOpt types.str "16G" "size of swap part";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -56,6 +56,62 @@ let
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# BTRFS root partition configuration
|
||||||
|
encBtrfsRoot = {
|
||||||
|
name = "cryptroot";
|
||||||
|
size = "100%";
|
||||||
|
content = {
|
||||||
|
type = "luks";
|
||||||
|
name = "cryptroot";
|
||||||
|
extraOpenArgs = [
|
||||||
|
"--allow-discards"
|
||||||
|
"--perf-no_read_workqueue"
|
||||||
|
"--perf-no_write_workqueue"
|
||||||
|
];
|
||||||
|
settings = {crypttabExtraOpts = ["fido2-device=auto" "token-timeout=10"];};
|
||||||
|
content = {
|
||||||
|
type = "btrfs";
|
||||||
|
extraArgs = [ "-f" ]; # Override existing partition
|
||||||
|
# Subvolumes must set a mountpoint in order to be mounted,
|
||||||
|
# unless their parent is mounted
|
||||||
|
subvolumes = {
|
||||||
|
"home" = {
|
||||||
|
mountOptions = [ "compress=zstd" ];
|
||||||
|
mountpoint = "/home";
|
||||||
|
};
|
||||||
|
"root" = {
|
||||||
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
mountpoint = "/root";
|
||||||
|
};
|
||||||
|
"nix" = {
|
||||||
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
mountpoint = "/nix";
|
||||||
|
};
|
||||||
|
"etc" = {
|
||||||
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
mountpoint = "/etc";
|
||||||
|
};
|
||||||
|
"log" = {
|
||||||
|
mountOptions = [
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
mountpoint = "/var/log";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
# BCacheFS root partition configuration
|
# BCacheFS root partition configuration
|
||||||
bcachefsRoot = {
|
bcachefsRoot = {
|
||||||
name = "bcachefs-root";
|
name = "bcachefs-root";
|
||||||
@@ -108,7 +164,7 @@ in
|
|||||||
size = cfg.swapSize;
|
size = cfg.swapSize;
|
||||||
};
|
};
|
||||||
|
|
||||||
root = if cfg.filesystem == "btrfs" then btrfsRoot else bcachefsRoot;
|
root = if cfg.filesystem == "btrfs" then ( if cfg.enableLuks then encBtrfsRoot else btrfsRoot) else bcachefsRoot;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -106,6 +106,7 @@ in
|
|||||||
"homekit_controller"
|
"homekit_controller"
|
||||||
"http"
|
"http"
|
||||||
"humidifier"
|
"humidifier"
|
||||||
|
"ibeacon"
|
||||||
"image"
|
"image"
|
||||||
"image_processing"
|
"image_processing"
|
||||||
"image_upload"
|
"image_upload"
|
||||||
@@ -117,6 +118,7 @@ in
|
|||||||
"input_select"
|
"input_select"
|
||||||
"input_text"
|
"input_text"
|
||||||
"ios"
|
"ios"
|
||||||
|
"ipp"
|
||||||
"isal"
|
"isal"
|
||||||
"jellyfin"
|
"jellyfin"
|
||||||
"keyboard"
|
"keyboard"
|
||||||
@@ -206,7 +208,7 @@ in
|
|||||||
"usb"
|
"usb"
|
||||||
"vacuum"
|
"vacuum"
|
||||||
"vlc"
|
"vlc"
|
||||||
"vesync"
|
# "vesync"
|
||||||
"wake_on_lan"
|
"wake_on_lan"
|
||||||
"waze_travel_time"
|
"waze_travel_time"
|
||||||
"weather"
|
"weather"
|
||||||
@@ -258,6 +260,7 @@ in
|
|||||||
extraPackages =
|
extraPackages =
|
||||||
ps: with ps; [
|
ps: with ps; [
|
||||||
pkgs.${namespace}.python-roborock
|
pkgs.${namespace}.python-roborock
|
||||||
|
pkgs.${namespace}.pyvesync
|
||||||
# # Core functionality
|
# # Core functionality
|
||||||
# aiohttp
|
# aiohttp
|
||||||
# aiodns
|
# aiodns
|
||||||
|
|||||||
38
packages/python/pyvesync/default.nix
Normal file
38
packages/python/pyvesync/default.nix
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
{
|
||||||
|
lib,
|
||||||
|
fetchFromGitHub,
|
||||||
|
python3Packages,
|
||||||
|
}:
|
||||||
|
|
||||||
|
python3Packages.buildPythonPackage rec {
|
||||||
|
pname = "pyvesync";
|
||||||
|
version = "3.0.0b8";
|
||||||
|
pyproject = true;
|
||||||
|
|
||||||
|
disabled = python3Packages.pythonOlder "3.11";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "webdjoe";
|
||||||
|
repo = "pyvesync";
|
||||||
|
rev = "dev-2.0";
|
||||||
|
hash = "sha256-hJGlcszXD8EXNPppOUuBt9obtunhymlqIGAltkAuZjA=";
|
||||||
|
};
|
||||||
|
|
||||||
|
build-system = with python3Packages; [ setuptools ];
|
||||||
|
|
||||||
|
dependencies = with python3Packages; [
|
||||||
|
aiohttp
|
||||||
|
mashumaro
|
||||||
|
python-dateutil
|
||||||
|
];
|
||||||
|
|
||||||
|
# pythonImportsCheck = [ "pyvesync" ];
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Python library to manage Etekcity Devices and Levoit Air Purifier";
|
||||||
|
homepage = "https://github.com/webdjoe/pyvesync";
|
||||||
|
changelog = "https://github.com/webdjoe/pyvesync/releases/tag/${src.tag}";
|
||||||
|
license = with licenses; [ mit ];
|
||||||
|
maintainers = with maintainers; [ fab ];
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -23,7 +23,7 @@
|
|||||||
imports = [
|
imports = [
|
||||||
./boot.nix
|
./boot.nix
|
||||||
./filesystems.nix
|
./filesystems.nix
|
||||||
./hardware-configuration.nix
|
# ./hardware-configuration.nix
|
||||||
./sops.nix
|
./sops.nix
|
||||||
./services/lsfg-vk
|
./services/lsfg-vk
|
||||||
./services/ratbagd
|
./services/ratbagd
|
||||||
@@ -44,7 +44,11 @@
|
|||||||
gaming.enable = true;
|
gaming.enable = true;
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
disko.enable = false;
|
disko = {
|
||||||
|
enable = true;
|
||||||
|
enableLuks = true;
|
||||||
|
};
|
||||||
|
|
||||||
amd = {
|
amd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
lact.enable = true;
|
lact.enable = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user