full, tested wsl config.

This commit is contained in:
Gabe Venberg 2024-05-15 13:22:50 -05:00
parent b900d6761a
commit 9f21d3020b
5 changed files with 19 additions and 13 deletions

View file

@ -83,6 +83,10 @@ inputs.nixpkgs.lib.nixosSystem {
# Enable the OpenSSH daemon.
services.openssh.enable = true;
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];

View file

@ -86,6 +86,10 @@ inputs.nixpkgs.lib.nixosSystem {
# Enable the OpenSSH daemon.
services.openssh.enable = true;
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];

View file

@ -9,22 +9,24 @@ inputs.nixpkgs.lib.nixosSystem {
modules = [
inputs.home-manager.nixosModules.home-manager
inputs.nixos-wsl.nixosModules.default
../../modules/hostopts.nix
../../modules/nixos/common.nix
../modules/hostopts.nix
../modules/nixos/common.nix
({
config,
pkgs,
...
}: {
wsl.enable=true;
wsl.enable = true;
wsl.wslConf.network.generateResolvConf = false;
networking.nameservers = ["1.1.1.1" "8.8.8.8"];
host = {
user = "gabe";
user = "nixos";
};
networking.hostName = "workstation-vm"; # Define your hostname.
networking.hostName = "gv-wsl"; # Define your hostname.
# Set your time zone.
time.timeZone = "America/Chicago";
programs.zsh.enable=true;
programs.zsh.enable = true;
environment.shells = with pkgs; [zsh];
# Define a user account. Don't forget to set a password with passwd.
users.users.${config.host.user} = {
@ -40,7 +42,6 @@ inputs.nixpkgs.lib.nixosSystem {
}: {
host = osConfig.host;
home = {
enable-speech = true;
nvim = {
enable-lsp = true;
enable-treesitter = true;
@ -54,8 +55,8 @@ inputs.nixpkgs.lib.nixosSystem {
};
};
imports = [
../../roles/home-manager/terminal.nix
../../modules/home-manager/common.nix
../roles/home-manager/terminal.nix
../modules/home-manager/common.nix
inputs.nixvim.homeManagerModules.nixvim
];
};

View file

@ -5,9 +5,6 @@
outputs,
...
}: {
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
nix = {
package = pkgs.nixFlakes;
extraOptions = ''

View file

@ -6,7 +6,7 @@
}: {
#note: needs to have something that autostarts desktop files.
services.spice-vdagentd.enable = true;
services.spice-autorandr.enable=true;
services.spice-autorandr.enable = true;
imports = [
./vm.nix
];