!apXxbtexmNGJaAryzM:nixos.org

NixOS on WSL

320 Members
https://github.com/nix-community/NixOS-WSL52 Servers

Load older messages


SenderMessageTime
26 Aug 2025
@ptramo:matrix.orgPierre Carriercreate a .wsl file17:38:19
@k900:0upti.meK900Build a .wsl file from a NixOS config (with the WSL modules included)? Yes17:38:37
@ptramo:matrix.orgPierre Carrierthat I can restore on other machines in as little time as possible. double click and go17:38:40
@nzbr:nzbr.denzbr (they/it) It should be possible (wsl --export I think), but I don't know if it will work well 17:39:34
@k900:0upti.meK900I think what they want is to build a tarball17:40:08
@k900:0upti.meK900Which is yes a thing you can do17:40:13
@ptramo:matrix.orgPierre Carrieryeah --export has all the transient stuff I'd rather lose17:40:20
@nzbr:nzbr.denzbr (they/it)Building a .wsl file from your own config should work fine though. But I don't remember the command for doing that without flakes17:40:28
@ptramo:matrix.orgPierre Carrieras in, not carry around17:40:35
@ptramo:matrix.orgPierre CarrierI use flakes17:41:07
@k900:0upti.meK900 It should be nix-build <nixpkgs/nixos> -A config.system.build.tarballBuilder 17:41:04
@ptramo:matrix.orgPierre Carrierhttps://github.com/pcarrier/nix17:41:20
@k900:0upti.meK900 Then it should be nix build .#nixosConfigurations.<hostname>.config.system.build.tarballBuilder 17:41:22
@ptramo:matrix.orgPierre Carrierah perfect appreciate it17:48:07
@nzbr:nzbr.denzbr (they/it) Does that automatically know to look in /etc/nixos/configuration.nix? 17:50:23
@k900:0upti.meK900Yes17:52:03
@nzbr:nzbr.denzbr (they/it)Neat17:52:10
@ptramo:matrix.orgPierre Carrierhmmm kinda lost here sorry. new x64 install, only added git to the nix-env and cloned the repo:18:17:59
@ptramo:matrix.orgPierre Carrier *

hmmm kinda lost here sorry. new x64 install, only added git to the nix-env and cloned the repo:

18:18:21
@ptramo:matrix.orgPierre Carrier *

hmmm kinda lost here sorry. new x64 install, only added git to the nix-env and cloned the repo:

[nixos@nixos:/src/sys]$ sudo nix-channel --update
unpacking 2 channels...

[nixos@nixos:/src/sys]$ sudo nixos-rebuild switch
building Nix...
building the system configuration...
activating the configuration...
setting up /run/booted-system...
setting up /bin...
setting up /sbin...
setting up /etc...
setting up /sbin/init shim...
reloading user units for nixos...
restarting sysinit-reactivation.target
Done. The new configuration is /nix/store/pwp82labadhpgsq86wbyfi8pbh3jvxwb-nixos-system-nixos-25.05.808723.b1b329146965

[nixos@nixos:/src/sys]$ sudo nixos-rebuild switch --flake .#wsl
/nix/store/f9iszzwi9k32cjafcmmvd4dawayva1ml-nixos-rebuild-ng-0.0.0/bin/.nixos-rebuild-wrapped: /nix/store/f9iszzwi9k32cjafcmmvd4dawayva1ml-nixos-rebuild-ng-0.0.0/bin/nixos-rebuild: line 3: syntax error near unexpected token `lambda'
/nix/store/f9iszzwi9k32cjafcmmvd4dawayva1ml-nixos-rebuild-ng-0.0.0/bin/.nixos-rebuild-wrapped: /nix/store/f9iszzwi9k32cjafcmmvd4dawayva1ml-nixos-rebuild-ng-0.0.0/bin/nixos-rebuild: line 3: `import sys;import site;import functools;sys.argv[0] = '/nix/store/f9iszzwi9k32cjafcmmvd4dawayva1ml-nixos-rebuild-ng-0.0.0/bin/nixos-rebuild';functools.reduce(lambda k, p: site.addsitedir(p, k), ['/nix/store/f9iszzwi9k32cjafcmmvd4dawayva1ml-nixos-rebuild-ng-0.0.0/lib/python3.13/site-packages'], site._init_pathinfo());'
18:18:32
@ptramo:matrix.orgPierre Carrier* https://github.com/pcarrier/sys18:19:27
@ptramo:matrix.orgPierre CarrierRedacted or Malformed Event18:20:34
@ptramo:matrix.orgPierre Carrier* oh it seems to maybe call the python from windows hu. no idea where that python even comes from, no uninstall available, not in scoop, not in winget. hmmm18:22:48
@ptramo:matrix.orgPierre Carrierwell, dunno what caused it, but it's gone19:41:34
27 Aug 2025
@ptramo:matrix.orgPierre Carrieranything to know for forwarding X11 using SSH?19:57:18
@k900:0upti.meK900 Don't, mostly 19:58:09
@ptramo:matrix.orgPierre Carrierwell I kinda need to19:58:21
@ptramo:matrix.orgPierre CarrierI run both hosts19:58:29
@k900:0upti.meK900WSL runs a Wayland compositor, not X, and forwarding XWayland will be a mess19:58:39
@k900:0upti.meK900 You probably want to use VNC or something 19:58:43

Show newer messages


Back to Room ListRoom Version: 9