Update nix shell
This commit is contained in:
parent
adae0be62a
commit
2d49bb5440
3 changed files with 40 additions and 2 deletions
|
@ -46,7 +46,7 @@
|
|||
nixos-rpi4-img = libx.mkImage { hostname = "nixos-rpi4-img"; platform = "aarch64-linux"; format = "sd-aarch64"; };
|
||||
};
|
||||
|
||||
# Devshell for bootstrapping; acessible via 'nix develop' or 'nix-shell' (legacy)
|
||||
# Devshell for bootstrapping; acessible via 'nix develop'
|
||||
devShells = libx.forAllSystems (system:
|
||||
let pkgs = nixpkgs.legacyPackages.${system};
|
||||
in import ./shell.nix { inherit pkgs sops-nix; }
|
||||
|
|
|
@ -94,7 +94,7 @@
|
|||
dday = "date +%A";
|
||||
|
||||
# nixos-rebuild
|
||||
ns = "nix-shell -p";
|
||||
ns = "nix shell";
|
||||
nr = "sudo nixos-rebuild";
|
||||
nrs = "sudo nixos-rebuild --upgrade switch";
|
||||
nrt = "sudo nixos-rebuild test";
|
||||
|
|
38
nixos/hosts/nixos-amd-osaka-01/default.nix
Normal file
38
nixos/hosts/nixos-amd-osaka-01/default.nix
Normal file
|
@ -0,0 +1,38 @@
|
|||
{ config, lib, pkgs, modulesPath, desktop, username, ... }: {
|
||||
imports = [ ];
|
||||
nixpkgs.config.allowUnfree = false;
|
||||
|
||||
boot.initrd.availableKernelModules = [ "ata_piix" "ohci_pci" "ehci_pci" "ahci" "sd_mod" "sr_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
# For cross-architecture builds
|
||||
boot.binfmt.emulatedSystems = [
|
||||
"aarch64-linux"
|
||||
"armv7l-linux"
|
||||
];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/mapper/DISK";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=@" ];
|
||||
};
|
||||
|
||||
|
||||
boot.initrd.luks.devices."DISK".device = "/dev/vda";
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
time.timeZone = "Asia/Tokyo";
|
||||
networking.hostName = "nixos-amd-osaka-01";
|
||||
|
||||
boot.loader.grub = {
|
||||
enableCryptodisk = true;
|
||||
enable = true;
|
||||
device = "/dev/vda";
|
||||
useOSProber = true;
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 22 ];
|
||||
}
|
Loading…
Reference in a new issue