continuous reorg

This commit is contained in:
John Lancaster
2024-12-08 16:03:45 -06:00
parent 9334d2cc7f
commit 343c6a89db
2 changed files with 39 additions and 26 deletions

View File

@@ -1,4 +1,4 @@
{ pkgs, ... }:
{ pkgs, userSettings, systemSettings, ... }:
{
nix.settings.experimental-features = [ "nix-command" "flakes" ];
@@ -23,4 +23,13 @@
execWheelOnly = false;
wheelNeedsPassword = false; # allows sudo without password for those in the wheel group
};
users.users.${userSettings.username} = {
isNormalUser = true;
uid = 1000;
extraGroups = [ "wheel" "networkmanager" ];
openssh.authorizedKeys.keyFiles = [ /root/.ssh/authorized_keys ];
};
time.timeZone = "${systemSettings.timeZone}";
}

View File

@@ -1,5 +1,5 @@
{
description = "Loki flake config";
description = "Panoptes flake config";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
@@ -20,39 +20,43 @@
...
} @ inputs:
let
stateVersion = "24.11";
inherit (self) outputs;
system = "x86_64-linux";
pkgs = nixpkgs.legacyPackages.${system};
stateVersion = "24.05";
nixosSystem = inputs.nixpkgs.lib.nixosSystem;
# userSettings = rec {
# username = "shahvirb"; # username on the system
# name = "Shahvir"; # name/identifier on the system
# email = "shahvirb@gmail.com";
# gitUserName = "shahvirb";
# gitUserEmail = "shahvirb@gmail.com";
# };
userSettings = rec {
username = "panoptes";
gitUserName = "John Lancaster";
gitUserEmail = "32917998+jsl12@users.noreply.github.com";
};
timeZone = "America/Chicago";
systemSettings = rec {
hostname = "panoptes-nix";
user = "panoptes";
system = "x86_64-linux";
timeZone = "America/Chicago";
locale = "en_US.UTF-8";
};
pkgs = inputs.nixpkgs.legacyPackages.${systemSettings.system};
in
{
nixosConfigurations = {
${hostname} = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs;};
"${systemSettings.hostname}" = nixosSystem {
system = systemSettings.system;
specialArgs = {
inherit inputs;
inherit outputs;
inherit userSettings;
inherit systemSettings;
};
modules = [
./configuration.nix # > Our main nixos configuration file <
"${nixpkgs}/nixos/modules/virtualisation/proxmox-lxc.nix"
"${inputs.nixpkgs}/nixos/modules/virtualisation/proxmox-lxc.nix"
({ ... }: {
nixpkgs.hostPlatform = "${system}";
# nixpkgs.hostPlatform = "${system}";
system.stateVersion = "${stateVersion}";
time.timeZone = "${timeZone}";
users.users.${user} = {
extraGroups = [ "wheel" ];
isNormalUser = true;
openssh.authorizedKeys.keyFiles = [ /root/.ssh/authorized_keys ];
};
# time.timeZone = "${systemSettings.timeZone}";
services.vscode-server.enable = true;
})
inputs.vscode-server.nixosModules.default