Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
a206132d94
|
@@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
flake.modules.nixos.amdgpu = ./nixos.nix;
|
||||||
|
}
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
hardware = {
|
||||||
|
graphics = {
|
||||||
|
enable = true;
|
||||||
|
enable32Bit = true;
|
||||||
|
extraPackages = with pkgs; [
|
||||||
|
mesa rocmPackages.clr rocmPackages.clr.icd rocmPackages.rocblas
|
||||||
|
rocmPackages.hipblas rocmPackages.rpp nvtopPackages.amd
|
||||||
|
];
|
||||||
|
};
|
||||||
|
amdgpu = { initrd.enable = true; opencl.enable = true; };
|
||||||
|
};
|
||||||
|
environment.systemPackages = with pkgs; [ clinfo amdgpu_top nvtopPackages.amd ];
|
||||||
|
systemd = {
|
||||||
|
packages = with pkgs; [ lact ];
|
||||||
|
services.lactd.wantedBy = [ "multi-user.target" ];
|
||||||
|
tmpfiles.rules = let
|
||||||
|
rocmEnv = pkgs.symlinkJoin {
|
||||||
|
name = "rocm-combined";
|
||||||
|
paths = with pkgs.rocmPackages; [ clr clr.icd rocblas hipblas rpp ];
|
||||||
|
};
|
||||||
|
in [ "L+ /opt/rocm - - - - ${rocmEnv}" ];
|
||||||
|
};
|
||||||
|
environment.variables = {
|
||||||
|
ROCM_PATH = "/opt/rocm";
|
||||||
|
HIP_VISIBLE_DEVICES = "1";
|
||||||
|
ROCM_VISIBLE_DEVICES = "1";
|
||||||
|
HSA_OVERRIDE_GFX_VERSION = "10.3.0";
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
{inputs, ...}:
|
||||||
|
{
|
||||||
|
flake-file.inputs = {
|
||||||
|
rockchip = {
|
||||||
|
url = "github:raboof/nixos-rockchip/pinetab-linux-7.0";
|
||||||
|
inputs.utils.follows = "flake-utils";
|
||||||
|
inputs.nixpkgsStable.follows = "nixpkgsStable";
|
||||||
|
inputs.nixpkgsUnstable.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
|
};
|
||||||
|
|
||||||
|
config.flake.factory.pinetab2 = buildPlatform: variantModules: {
|
||||||
|
nixos.pinetab2 = {
|
||||||
|
imports = [
|
||||||
|
inputs.rockchip.nixosModules.sdImageRockchip
|
||||||
|
inputs.rockchip.nixosModules.dtOverlayPCIeFix
|
||||||
|
inputs.rockchip.nixosModules.noZFS
|
||||||
|
inputs.self.modules.nixos.pinetab2-base
|
||||||
|
] ++ variantModules;
|
||||||
|
rockchip.uBoot = inputs.rockchip.packages.${buildPlatform}.uBootPineTab2;
|
||||||
|
boot.kernelPackages =
|
||||||
|
inputs.rockchip.legacyPackages.${buildPlatform}.kernel_linux_7_0_pinetab_unstable;
|
||||||
|
hardware.firmware = [ inputs.rockchip.packages.aarch64-linux.bes2600 ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
flake.nixConfig = {
|
||||||
|
extra-trusted-public-keys = [
|
||||||
|
"marpa-local:XoO+dFN4PeauF52pYuy3Vh4Sdtl2qIdxu5aUasWKv6Q="
|
||||||
|
"phundrak.cachix.org-1:osJAkYO0ioTOPqaQCIXMfIRz1/+YYlVFkup3R2KSexk="
|
||||||
|
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||||
|
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
|
||||||
|
];
|
||||||
|
extra-substituters = [
|
||||||
|
"http://marpa:5000?priority=5"
|
||||||
|
"https://phundrak.cachix.org?priority=10"
|
||||||
|
"https://nix-community.cachix.org?priority=20"
|
||||||
|
"https://cache.nixos.org?priority=40"
|
||||||
|
];
|
||||||
|
extra-experimental-features = [ "nix-command" "flakes" ];
|
||||||
|
http-connections = 128;
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
{inputs, ...}:
|
||||||
|
{
|
||||||
|
flake-file.inputs.srvos = {
|
||||||
|
url = "github:nix-community/srvos";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
flake.modules.nixos.hetzner-server = {
|
||||||
|
imports = [
|
||||||
|
inputs.srvos.nixosModules.server
|
||||||
|
inputs.srvos.nixosModules.hardware-hetzner-cloud
|
||||||
|
inputs.srvos.nixosModules.mixins-terminfo
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
{inputs, ...}:
|
||||||
|
{
|
||||||
|
flake-file.inputs.sops-nix = {
|
||||||
|
url = "github:Mic92/sops-nix";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
flake.modules = {
|
||||||
|
nixos.sops = {
|
||||||
|
imports = [inputs.sops-nix.nixosModules.sops];
|
||||||
|
};
|
||||||
|
homeManager.sops = {
|
||||||
|
imports = [inputs.sops-nix.homeManagerModules.sops];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user