networking.wireless.secretsFile
NixOS option
File consisting of lines of the form varname=value to define variables for the wireless configuration. Secrets (PSKs, passwords, etc.) can be provided without adding them to the world-readable Nix store by defining them in the secrets file and referring to them in option networking.wireless.networks with the syntax ext:secretname. Example: # content of /run/secrets/wireless.conf psk_home=mypassword psk_other=6a381cea59c7a2d6b30736ba0e6f397f7564a044bcdb7a327a1d16a1ed91b327 pass_work=myworkpassword # wireless-related configuration networking.wireless.secretsFile = "/run/secrets/wireless.conf"; networking.wireless.networks = { home.pskRaw = "ext:psk_home"; other.pskRaw = "ext:psk_other"; work.auth = '' eap=PEAP identity="my-user@example.com" password=ext:pass_work ''; };
type: null or absolute pathnull
"/run/secrets/wireless.conf"