Skip to content

Commit

Permalink
change target host
Browse files Browse the repository at this point in the history
  • Loading branch information
spiceratops committed Jul 25, 2024
1 parent 09fbd75 commit 1b40093
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 91 deletions.
9 changes: 6 additions & 3 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@
# Supported systems for your flake packages, shell, etc.
systems = [
"aarch64-linux"
"i686-linux"
"x86_64-linux"
"aarch64-darwin"
"x86_64-darwin"
];
# This is a function that generates an attribute by calling a function you
# pass to it, with each system as an argument
Expand All @@ -49,19 +52,19 @@
# NixOS configuration entrypoint
# Available through 'nixos-rebuild --flake .#your-hostname'
nixosConfigurations = {
devbox = nixpkgs.lib.nixosSystem {
nixstation = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs;};
modules = [
# > Our main nixos configuration file <
./hosts/devbox/configuration.nix
./hosts/nixstation/configuration.nix
];
};
};

# Standalone home-manager configuration entrypoint
# Available through 'home-manager --flake .#your-username@your-hostname'
homeConfigurations = {
"stewart@devbox" = home-manager.lib.homeManagerConfiguration {
"stewart@nixstation" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance
extraSpecialArgs = {inherit inputs outputs;};
modules = [
Expand Down
85 changes: 0 additions & 85 deletions hosts/devbox/hardware-configuration.nix

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

# Import your generated (nixos-generate-config) hardware configuration
./hardware-configuration.nix
<nixos-wsl/modules>
#<nixos-wsl/modules>
];

nixpkgs = {
Expand Down Expand Up @@ -69,13 +69,13 @@
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};

networking.hostName = "devbox";
networking.hostName = "nixstation";

users.users = {
stewart = {
isNormalUser = true;
openssh.authorizedKeys.keys = [
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAcbIqtYV7xyO1+sP1sCx+/Z6HYTsh+1gYG+5VF1pCW3
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAcbIqtYV7xyO1+sP1sCx+/Z6HYTsh+1gYG+5VF1pCW3"
];
extraGroups = ["wheel"];
};
Expand Down
37 changes: 37 additions & 0 deletions hosts/nixstation/hardware-configuration.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Do not modify this file! It was generated by ‘nixos-generate-config’
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:

{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];

boot.initrd.availableKernelModules = [ "uhci_hcd" "ehci_pci" "ahci" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];

fileSystems."/" =
{ device = "/dev/disk/by-uuid/027313d9-415d-4fb9-9976-cdecaa58090a";
fsType = "ext4";
};

fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/C572-7537";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};

swapDevices = [ ];

# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp6s18.useDHCP = lib.mkDefault true;

nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}

0 comments on commit 1b40093

Please sign in to comment.