Updates to raspi server

This commit is contained in:
Alexander Bantyev 2021-11-06 12:06:38 +03:00
parent b4ad926d08
commit 7633581020
Signed by: balsoft
GPG Key ID: E081FF12ADCB4AD5
7 changed files with 21 additions and 20 deletions

View File

@ -130,21 +130,16 @@
deploy = { deploy = {
user = "root"; user = "root";
nodes = (builtins.mapAttrs (_: machine: { nodes = (builtins.mapAttrs (name: machine:
let activateable = name == "T420-Laptop" || name == "RasPi-Server"; in {
hostname = machine.config.networking.hostName; hostname = machine.config.networking.hostName;
profiles.system = { profiles.system = {
user = "balsoft"; user = if activateable then "root" else "balsoft";
path = deploy-rs.lib.x86_64-linux.activate.noop path = with deploy-rs.lib.${machine.pkgs.system}.activate; if activateable
machine.config.system.build.toplevel; then nixos machine
else noop machine.config.system.build.toplevel;
}; };
}) self.nixosConfigurations) // { }) self.nixosConfigurations);
T420-Laptop = {
hostname =
self.nixosConfigurations.T420-Laptop.config.networking.hostName;
profiles.system.path = deploy-rs.lib.x86_64-linux.activate.nixos
self.nixosConfigurations.T420-Laptop;
};
};
}; };
}; };
} }

View File

@ -1,8 +1,12 @@
{ inputs, ... }: { { inputs, pkgs, lib, ... }: {
imports = with inputs.self.nixosModules; [ imports = with inputs.self.nixosModules; with inputs.self.nixosProfiles; [
./hardware-configuration.nix ./hardware-configuration.nix
inputs.self.nixosRoles.server inputs.self.nixosRoles.server
mailserver themes
fonts
cage
gtk
alacritty
]; ];
boot.loader.raspberryPi = { boot.loader.raspberryPi = {
@ -10,6 +14,8 @@
version = 3; version = 3;
}; };
nix.package = lib.mkForce pkgs.nixUnstable;
deviceSpecific.devInfo = { deviceSpecific.devInfo = {
cpu = { cpu = {
vendor = "broadcom"; vendor = "broadcom";

View File

@ -16,8 +16,6 @@
services.logind.lidSwitch = "ignore"; services.logind.lidSwitch = "ignore";
security.sudo.wheelNeedsPassword = false;
deviceSpecific.devInfo = { deviceSpecific.devInfo = {
legacy = true; legacy = true;
cpu = { cpu = {

View File

@ -1,5 +1,5 @@
{ config, pkgs, inputs, lib, ... }: { { config, pkgs, inputs, lib, ... }: {
environment.systemPackages = [ inputs.himalaya.defaultPackage.x86_64-linux ]; environment.systemPackages = [ inputs.himalaya.defaultPackage.${pkgs.system} ];
home-manager.users.balsoft = { home-manager.users.balsoft = {
xdg.configFile."himalaya/config.toml".text = '' xdg.configFile."himalaya/config.toml".text = ''
downloads-dir="/home/balsoft/Downloads/mail" downloads-dir="/home/balsoft/Downloads/mail"

View File

@ -23,7 +23,7 @@
"serokell-1:aIojg2Vxgv7MkzPJoftOO/I8HKX622sT+c0fjnZBLj0=" "serokell-1:aIojg2Vxgv7MkzPJoftOO/I8HKX622sT+c0fjnZBLj0="
]; ];
package = inputs.nix.defaultPackage.x86_64-linux.overrideAttrs (oa: { package = inputs.nix.defaultPackage.${pkgs.system}.overrideAttrs (oa: {
patches = [ ./nix.patch ./unset-is-macho.patch ] ++ oa.patches or [ ]; patches = [ ./nix.patch ./unset-is-macho.patch ] ++ oa.patches or [ ];
# HAHA # HAHA
doInstallCheck = false; doInstallCheck = false;

View File

@ -2,7 +2,7 @@
let let
filterGit = filterGit =
builtins.filterSource (type: name: name != ".git" || type != "directory"); builtins.filterSource (type: name: name != ".git" || type != "directory");
system = "x86_64-linux"; inherit (pkgs) system;
old = import inputs.nixpkgs-old ({ old = import inputs.nixpkgs-old ({
config = config.nixpkgs.config; config = config.nixpkgs.config;
localSystem = { inherit system; }; localSystem = { inherit system; };

View File

@ -2,4 +2,6 @@
imports = [ imports = [
./base.nix ./base.nix
]; ];
security.sudo.wheelNeedsPassword = false;
} }