2019-03-13

<slabity> As long as you didn't make manual changes to hardware-configuration.nix it should be fine
<slabity> octe: nixos-generate-config
<slabity> Is there a way to check what a variable is set to on a particular system configuration? For example if I set `services.xserver.enable` to true, then `hardware.opengl.enable` should be true even if I don't explicitly set that.
<slabity> Android: Sorry, forgot it was in a different named package
<slabity> ,locate nix-locate
<slabity> ,locate hello
<slabity> Android: Try nix-locate. Or use the bot
<slabity> clever: I don't see why not. It is a distribution
<clever> slabity: then my haskell-init, with only 2 files, is technically a distro, lol
<slabity> 'Distro' is such an ambiguous term. I think of anything that creates a bootable environment a 'distro'
<slabity> Wow that's neat
<slabity> Android: If you're interested, some of us make our configurations (mostly) public: https://gitlab.com/slabity/nixos-config
<slabity> We need a NixHub for sharing moduels
<slabity> Android: I'm not sure what you mean. You can do that. But all the modules we use come from nixpkgs
<slabity> Android: Yes, but someone still needs to create those modules. And unfortunately the Nix community is quite small
<slabity> Android: Unfortunately not
<slabity> I use some KDE services. Maybe I'll look at creating an easy-to-use module that just enables those services
<slabity> Does `services.xserver.desktopManager.plasma5` not include kdeconnect?
<slabity> Does the kdeconnect process start up when you login?
<slabity> Android: It's not necesary. It just makes it easier for some services. You should still be able to use kdeconnect without it
<slabity> Rather than system-level
<slabity> Android: It's a tool for configuring user-level nix configs.
<slabity> Android: Are you using home-manager for enabling kdeconnect?

2019-03-12

<infinisil> slabity: Or alternatively, if I don't want to make it public that I set a certain option, I can just set it in the private repo
<infinisil> slabity: This allows me to refer to all the secret stuff like this: https://github.com/Infinisil/system/blob/9fc395983566bedbdf27e2d3c3a2c88202dd7bcc/config/personal/wlan.nix#L4
<infinisil> slabity: In there I define a set of options under `config.private`, which defines all the private things
<infinisil> slabity: I'm keeping a separate, private repository as a submodule in my configuration
<slabity> clever: Wrong person :P
<clever> slabity: /etc/wpa_supplicant.conf is unmanaged, and i just copy it over from another laptop
<clever> slabity: i simply dont have nixos manage the wifi config
<slabity> I think git-secret might let me do that.
<slabity> sphalerite: I'd like to be able to keep my configuration public for others to reference, but keep those kind of credentials private.
<sphalerite> slabity: what's your threat model? :)
<slabity> How do you guys manage various `passwordFile` options? I'm guessing it's not safe to store them unencrypted in a git repo
<slabity> reilithion: Override the configuration environment after it's already built? Like modifying the nix-store directly?
<slabity> Does nixops not deploy to nixos-containers?

2019-03-11

<slabity> For some reason I thought the run command starts the container, but that appears to just run a single command
<slabity> Nevermind I'm stupid and didn't start
<clever> slabity: what about `machinectl show myc -p Leader` ?
<srhb> slabity: start :)
<slabity> Tried to run `nixos-container run myc`, but same error
<clever> slabity: it will use machinectl to find the leader of the container
<srhb> slabity: Did you start it first?
<slabity> I can confirm /var/lib/containers/myc exists as well. Any ideas why it can't connect?
<slabity> unable to get container's main PID
<slabity> I made a nixos-container with a simple config. No errors on creation, and it appears in `sudo nixos-container list`. However, when I try to root-login, I get the following:
<slabity> Could not get path to machine: No machine 'myc' known

2019-03-04

<slabity> tokudan: Sorry, that option is for nix-build
<tokudan[m]> slabity: i'll just use nix-build
<tokudan[m]> slabity: unrecognised flag '--verbose=5'
<slabity> tokudan: I believe '--verbose=5' will print out everything

2019-03-01

<slabity> Is there anyway to rebuild it? It's causing a bunch of i/o errors
<slabity> Is it safe to delete /nix/store/.links? I think it's messing up my filesystem
<slabity> Hey all, yesterday I ran into an error with NixOS and btrfs on a drive (corrupt leaf node). I reinstalled on another drive and seem to have a similar issue. Is anyone else running btrfs on nixos-unstable and could see if dmesg has any errors?

2019-02-27

<slabity> Wait, you're leaving nixos for windows?
<tilpner> slabity: It will eat more memory that could be used for other things
<gchristensen> slabity: I do erase / on each boot, except for a few dirs
<slabity> Generating the symlinks at boot seems like low overhead
<slabity> I have been wondering, why not use a tmpfs for the root directory? Most things in / are just symlinked to the actual /nix/store/ contents
<slabity> brtfs here, but yea, I have /nix on a separate volume
<clever> slabity: the module adds itself to systemPackages
<slabity> clever: Thanks. That works perfectly
<clever> slabity: nix-build '<nixpkgs/nixos/release.nix>' -A options should do it
<slabity> clever: Is there an easy way to extract that optionsJSON using `nix eval` or something like that?
<clever> slabity: line 204 makes an olink-db, and 238 makes man pages
<slabity> clever: Beautiful. Thank you
<clever> slabity: this takes an optionsList and generates a json of every option: https://github.com/NixOS/nixpkgs/blob/59f6083281e0e481adf9ff1fbbd30165d4e1e897/nixos/doc/manual/default.nix#L238-L252
<clever> slabity: one min
<slabity> Where can I find out how the manpage for `configuration.nix` is created? I'd like to see how it extracts all those options

2019-02-18

<slabity> I believe POSIX only defines `#!/bin/sh` and `#!/usr/bin/env` anyways
<slabity> schneid3306: If the script properly uses `#!/usr/bin/env`, it should work fine

2019-02-15

<slabity> Okay that format is pretty nice
<slabity> Viewing it as multiple pages is much nicer
<slabity> Yea, a single webpage is not the best media for that kind of info
<slabity> Nice
<slabity> What's that quote from?

2019-02-14

<slabity> Kill it with fire
<slabity> pkgdesc="Docker powered mini-Heroku in around 100 lines of Bash."
<slabity> Aren't commits flattened on merging though?

2019-02-12

<slabity> samrose_: Looks like my solution requires the mozilla overlay to get the 'rustChannelOf' variable
<slabity> I just put `preferredRustChannel = super.rustChannelOf { date = "..."; channel = "nightly" };' in my local overlay.
<slabity> samrose: I actually do this exact thing with the mozilla overlay.
<rycee> slabity: Yeah. One of these days I'll write something about it in the manual :-)
<slabity> Nice. That might clean up my config a bit
<infinisil> slabity: home-manager#97
<slabity> You can use home-manager as a nixos module?
<srhb> slabity: Right :)
<slabity> srhb: Nevermind, I'm assuming they want all possible nixpkgs.config.* values
<srhb> slabity: The naming is confusing.
<srhb> slabity: Not really, no. It contains nixpkgs.config which is the actual nixpkgs config set (and is not really documented further)
<slabity> srhb: But it contains the nixpkgs.* options within
<srhb> slabity: No, that's NixOS
<slabity> pinkypie: 'man configuration.nix'

2019-02-08

<tilpner> slabity: I've tried that, it's not a good idea. The store will eat all your file permissions, and you'll be sad
<slabity> tilpner: Namespaces? I just want to unpack a tarball and create an environment out of it. I'm not looking at special security permissions
<tilpner> slabity: I wouldn't expect you to be able to get user namespaces during a build. That said, I haven't tried
<slabity> It looks like build-support/vm is all kvm stuff
<slabity> I don't want a virtual machine. More of a container
<slabity> I have a tarball that can be used to bootstrap Arch Linux for example. But it sounds like buildFHSUserEnv won't do that?
<symphorien> slabity: there is runInLinuxVm or something like that
<slabity> Bootstrap Debian into a derivation and use that as a base for installing debian packages for example
<slabity> tilpner: My endgoal is to create a bootstrapped environment that can be used as a base for other packages.
<slabity> I have a tarball that contains a barebones FHS. I want to create a derivation that creates an isolated chroot and unpacks the tarball
<slabity> What does it do? The manual says it should create an isolated root environment.
<slabity> tilpner: I expect to be dropped in an isolated chroot
<tilpner> slabity: That works though, what did you expect?
<slabity> Then run ./result/bin/newenv
<slabity> tilpner: `nix build '({ pkgs ? import <nixpkgs> { } }: pkgs.buildFHSUserEnv { name = "newenv"; })'`
<tilpner> slabity: How are you trying to run that? That should error in multiple ways
<slabity> I have a very simple derivation: '{ pkgs }: pkgs.buildFHSUserEnv rec { name "test" }'. Attempting to run it doesn't result in an error, but it doesn't create a new environment
<tilpner> slabity: Yes, what's your question/error
<slabity> Is anyone familiar with how to use buildFHSUserEnv properly? It doesn't seem to be creating any type of isolated environment for me.
<slabity> Does buildFHSUserEnv not create an isolated root? The nixpkgs manual says it does, but it seems to be completely disregarded when I try to use it.
<slabity> It just ends up running bash in whichever directory I'm in
<slabity> `nix build '({ pkgs ? import <nixpkgs> { } }: pkgs.buildFHSUserEnv { name = "newenv"; })' && ./result/bin/newenv` does not drop me in an FHS chroot
<slabity> However, it doesn't produce an FHS environment like I expect. It just produces a `bin/newenv` executable that puts me in a bash shell in my home directory. Is there something I'm missing?
<slabity> I have a simple derivation; `{ pkgs }: pkgs.buildFHSUserEnv { name = "newenv"; }`
<slabity> Hell I'd like to eventually make a Windows VM derivation for easy setup
<slabity> I think it'd be cool to just say 'nix-env -iA vms.ubuntu' and have it automatically create a derivation with a ubuntu VM
<slabity> simpson: Sort of? I'd like to try and package up some VMs first.
<simpson> slabity: Hopefully, though, you have at least one specific package in mind.
<simpson> slabity: Note that `dockerTools.pullImage` is *already* in nixpkgs!
<slabity> Unless that would be useful contribution to nixpkgs, but I'm not sure that is the best place for it
<slabity> simpson: The Arch thing was just an example. I'd like to create them for other popular repos, dockerhub, snaps, appimages, etc. so that developers can easily run programs from other platforms effectively
<slabity> NUR looks like it uses packageoverrides. Not a channel or overlay.
<simpson> slabity: Trying to remember the name of the effect; basically, it'd be less effort to just contribute to nixpkgs. What's in Arch that you find useful but not in nixpkgs?
<slabity> For example, I want to make one channel/overlay that provides methods of parsing and building Arch PKGBUILD packages
<slabity> simpson: I want to create something that can provide new configuration options and packages that is easily shared with others.
<tilpner> slabity: You can create your own channels, and share them with others
<slabity> So you can't share custom channels?
<slabity> Is there a practical difference between creating a custom overlay and creating a custom channel?

2019-02-05

<slabity> Because I guess it got rid of swing.plaf.windows.WindowsLookAndFeel? Which is for some reason required in the app I'm using
<slabity> vaibhavsagar: Openjdk8 has a bug in it for the particular app I'm using, and openjdk11 doesn't even run. Crashes with a 'NoClassDefFoundError'
<vaibhavsagar> slabity: can you use openjdk?
<slabity> I need to regress to 8, which doesn't even work properly
<slabity> infinisil: Especially since there doesn't seem to be an oraclejdk10 or 11
<infinisil> slabity: cransom: I wish people would pay a bit more attention to backwards compatibilty and deprecation..
<slabity> Does anyone know what happened to the oraclejdk9 package? It's like it just vanished from the nixpkgs repo.

2019-02-01

<thibm> slabity: you can mount bind the store, but take care of NIX_IGNORE_SYMLINK_STORE (look at man pages of any nix tool). And that may not be a good idea to do at runtime
<slabity> makefu: Thanks. I'll look into that.
<makefu> slabity: what the nixos iso is using is overlayfs, so you an have a "lower" store which contains read-only packages and a write-store on top of it.
<slabity> Is it possible to have multiple Nix stores on a single machine? I'd like to put a read-only one on an SD card that I can move between systems

2018-12-24

<slabity> Oh I did not know you can search by filetype
<slabity> You can run it locally using nix-index and nix-locate
<slabity> ,locate adb
<slabity> silver_hook: You can use nix-locate to find packages easier
<silver_hook> slabity: That makes sense from the technical PoV, yeah …but it’s not easy to find for the end-user :/
<slabity> For the udev rule reason
<slabity> silver_hook: There is a package. It's just easier to add it to your system config
<ottidmes> slabity: its more flexible, because you just manage your own checkout so its transparant nixpkgs is just a git checkout, and I have never run into any issue with my channels. So all those issues with nix-channel, they seem like unnecessary to me
<slabity> ottidmes: Makes sense.
<ottidmes> slabity: I always see questions pop up about nix channels that always have to do with things like root and user not using the same channels and other issues, while I just made my system so that everything refers to the same channel, and if I want others, like unstable for some packages, I can always do that with a pinned nixpkgs in my overlay
<slabity> ottidmes: Can you elaborate?
<slabity> Assuming I'm understanding your question correctly
<slabity> Yea, in the install phase you can put `mkdir $out/srv` and you should get what you want

2018-12-21

<slabity> Only the nix builder users can modify the /nix/store
<slabity> Yea, nix-shell is still run by your user
<slabity> jomik: Could you post your derivation? There's a lot of possibilities
<ilya-fedin> slabity: I am using systemd-boot. And, as I wrote above, the problem is that the boot record remains. I did not try to load the boot record of the previous generation, perhaps all the other files (except for the kernel, it is there) have been deleted.
<slabity> And less likely to try booting into an invalid generation
<slabity> Should the gc command regenerate the grub config? That might make it less confusing
<clever> slabity: you must nixos-rebuild after a GC, to regenerate the grub config
<ottidmes> slabity: ah that could be it
<slabity> Or do you need a nixos-rebuild before they're removed?
<slabity> Does nix-collect-garbage remove the grub entries for past generations?
<slabity> So you're saying it's keeping the current generation and the previous one, but deleting all others?
<slabity> Did you run it as root?
<ottidmes> ilya-fedin: then it is like slabity says `nix-collect-garbage -d`
<slabity> or `nix-collect-garbage -d` for all old generations
<slabity> `nix-collect-garbage --delete-older-than 30d` for 30 days
<slabity> ilya-fedin: You can use the `--delete-older-than` flag
<ilya-fedin> slabity: how?
<slabity> ilya-fedin: You need to delete those generations before the garbage collector will remove their dependencies
<slabity> I wouldn't be surprised if it's not the default in NixOS
<slabity> BFQ has only recently been mainlined, and isn't enables by default upstream, right?
<ilya-fedin> slabity: I found this file, thought there was something else. :(
<slabity> Yea, my mistake
<slabity> ilya-fedin: Nevermind. It looks like there actually is a list: https://github.com/NixOS/nixpkgs/blob/master/pkgs/os-specific/linux/kernel/patches.nix
<slabity> Just had to add that file to kernelPatches for it to apply
<slabity> I don't think there's a list of all kernel packages
<slabity> ilya-fedin: Kernel patches can range very widely

2018-12-19

<slabity> gchristensen: What if I don't use readFile? Is there some other way of loading a file as a string and evaluating it as one so that the variables expand?
<slabity> So that variables like ${...} get evaluated
<slabity> If I read in a file with `builtins.readFile`, how can I have it evaluated like a Nix string?
<slabity> Let me guess, Nerdfonts? That always takes forever to download
<slabity> Is firefox-bin not acquired via fetch*?
<slabity> gchristensen: Thanks.
<slabity> I'm assuming it's built with Nix somewhere in nixpkgs?
<slabity> Where can I find information on how NixOS's initramfs is generated?

2018-12-13

<slabity> Lots of missing documentation right now when it comes to Nix
<slabity> Nice
<slabity> `pypi2nix -V 3.6 -E gcc -E libffi.dev -E postgresql -E zlib -E openssl.dev -E libxml2.dev -E libxslt.dev -E zlib.dev -r requirements.txt`
<slabity> `git clone https://github.com/taigaio/taiga-back && cd taiga-back`
<slabity> Can be replicated with the following two commands:
<slabity> Anyone here have experience with `pypi2nix`? I'm trying to use it to build https://github.com/taigaio/taiga-back but it says `The headers or library files could not be found for zlib` despite having `-E zlib -E zlib.dev` options
<slabity> But that was pretty quick. Nice
<slabity> I actually don't use sublime. I was just confirming I could build it
<Synthetica> slabity: If you don't like S3, you should be able to switch back once that's merged
<slabity> Synthetica: You beat me to it :P
<smrtak> Synthetica: slabity thank you for your fast response
<slabity> I can confirm sublime3 works. Can you use that?
<slabity> smrtak: Looks like the file is no longer provided by the mirror.

2018-11-19

<Neo--> slabity, thanks, though I wasn't planning on using it just to get it to run dunst :)
<slabity> Yea, I use home-manager
<slabity> Neo--: Have you seen https://github.com/rycee/home-manager? You can use it to integrate dunst pretty well
<Neo--> slabity, how did you configure it to start for user? do you use home manager to run it as a service?
<Neo--> slabity, indeed - it appears I was in an old shell where I was root, with user account I need to start it manually
<slabity> Neo--: Can you try bringing it up manually? I'm not sure if auto-running starts it up as your user
<slabity> Also, `home-manager` has a dunst service wrapped in a service to integrate into nix
<slabity> Neo--: I use dunst. How are you calling it?
<slabity> I kinda like the idea of having Nix on a router. As long as it only uses binary caches

2018-11-16

<slabity> Might need to use home-manager to get that to work though
<slabity> jabraham: You could try calculating it in your nix config.
<slabity> jabranham: I do not believe dunst has HiDPI support. You may just need to increase the font size in your config.

2018-11-15

<jonreeve> slabity: Ok. I just posted to the Unix StackExchange if anyone wants to check it out there: https://unix.stackexchange.com/questions/481981/how-can-i-install-gnome-in-nixos
<slabity> Thanks
<slabity> infinisil: I did not know that. Are there other nix-related channels?
<slabity> jonreeve: I don't really know what could cause an IO error like that.
<jonreeve> slabity: Oh wait, here's the actual error: https://www.pastery.net/rwngwh/
<jonreeve> slabity: I did find this in my system logs, though, by doing `journalctl -g gnome-shell`: https://www.pastery.net/xcersz/
<jonreeve> slabity: Hm, /var/log/gdm seems to be empty
<slabity> If you gist/pastebin it, we can see if anything stands out
<slabity> jonreeve: I believe GDM's log file is in /var/log. It might have some information if the desktop won't start
<slabity> jonreeve: Using GDM?

2018-11-12

<slabity> If it's looking for a binary name like and being executed by some sort of shell that resolved PATH, then you can rely on it.
<slabity> If it's looking for an absolute path like /usr/bin/whatever then it's safe to say it needs that exact path
<slabity> romildo: Not unless the program calling those binaries will resolve the paths
<romildo> slabity, is it reasonable to use /run/current-system/sw as a prefix for most of those hard coded paths?
<slabity> Might not be the best idea, but you could always create an FHS derivation and symlink those paths to the actual paths
<slabity> Unless you want to work upstream and expose it as a build option
<slabity> romildo: Changing source code would best be done with a patch
<slabity> I got nix-locate to work though. Just get some errors with some random packages I don't use
<ottidmes> slabity: on what version of NixOS are you? unstable/18.09?
<infinisil> slabity: ottidmes: Temporarily undo the overlays and packageOverrides and try again
<slabity> I am getting a lot of 'Error fetching the file listing for store path '...' failed'
<ottidmes> slabity: nix-index is what the tool that contains nix-locate, nix-index generates a local index which nix-locate uses
<slabity> That's a tool I definitely need then. My overlay can wait
<slabity> nix-index does that too?
<slabity> Oh that's cool
<slabity> ,locate llvm-nm
<slabity> Is that a chat command?
<slabity> Now I just need to figure out where to find the `llvm-nm` binary
<slabity> ottidmes: Thanks. I'll see if I can add it to my custom overlay
<ottidmes> slabity: so you should just write an overlay yourself, overlaying rust, instead of using packageOverrides
<ottidmes> slabity: I do not believe you can do that, because overlays are applied afterwards: https://github.com/NixOS/nixpkgs/blob/370ce8fcd39a3ed1002db0d7fb281576e39fc4ef/pkgs/top-level/stage.nix#L189
<slabity> In this case I'm using the mozilla overlay and trying `rust = super.latest.rustChannels.nightly.rust.override {...};`
<slabity> For `packageOverrides`, can you override a package that comes from an overlay? Nix is telling me it can't find the package I'm specifying.

2018-11-05

<sphalerite> slabity: looks to me like it's a matter of putting the relevant package in your user or system profile (e.g. kdeFrameworks.kwallet) and ensuring kwalletd5 gets started on login
<slabity> Things like KWallet, KDE Connect, etc.
<sphalerite> slabity: only showed up once :) What sort of services?
<slabity> Sorry if that message showed up twice. Room kept thinking I was unregistered
<slabity> Is there an option to enable KDE services without using the Plasma DE?

2018-10-17

<worldofpeace> slabity: make sure for ssh you are using `users.users.<username?>.openssh.authorizedKeys.keyFiles`
<slabity> I'm trying to figure out a good structure for handling all my workstations together
<slabity> Does anyone here use NixOps to deploy to their workstations/desktop machines?

2018-10-02

<slabity> Does anyone else have issues running steam? I recently started getting `glxChooseVisual failed` whenever I run it

2018-10-01

<slabity> Hey guys. Anyone else having issues with amdgpu and the /run/opengl-driver/lib/dri not being included properly?

2018-09-29

<slabity> Does anyone else get a 'glXChooseVisual failed' when trying to run steam?

2018-09-21

<samueldr> slabity: https://github.com/bennofs/nix-index#installation seems to install and work find
<slabity> No problem
<samueldr> be mindful, slabity, if you need to spam it a bunch do it in #bottest please :)
<slabity> Oh neat
<samueldr> but meanwhile, slabity, the bot here has some nix-locate functionalities
<samueldr> slabity: I think there was a PR merged recently fixing nix-index, not sure if usable yet when installing from their repo (checking)
<haslersn> slabity: you don't need the store path for packaging: patchelf --set-rpath "${lib.makeLibraryPath [ glib ] }" # I don't know about libgthread
<slabity> Yes
<haslersn> slabity: It's not necessarily the same on your system. Do you need it for packaging:
<slabity> Actually, can anyone nix-locate these two files: `libgthread-2.0.so.0` and `libglib-2.0.so.0`? I can't get `nix-index` working
<slabity> Is there a way to run something akin to a `nix-locate` without needing `nix-index`? It keeps failing for me

2018-09-20

<slabity> Hey guys, working on a derivation. I'm using autopatchelf here. It's telling me some libraries like `libdbus-1.so.3` are missing. What's the standard way to fix that?

2018-09-02

<slabity> Has anyone here got Plasma/KDE working with i3 in NixOS?

2018-08-24

<clever> slabity: ive seen it on a trelo
<slabity> Does anyone know when the NixCon program is going to be published?

2018-08-22

<slabity> But in case it isn't working, can you share your config in a gist?
<slabity> Yea, I hate it when my xserver is working too.

2018-08-20

<cocreature> slabity: builtins.functionArgs
<slabity> Like if I wanted to get all the attributes for the `derivation` builtin function?
<slabity> Any way to programmatically get all attributes of a Nix function?

2018-07-31

<slabity[m]> But it's definitely a good point to start looking
<slabity[m]> I wish I knew enough haskell to read this :P
<slabity[m]> Never heard of it. I'll check it out
<joepie91_to_go> slabity[m]: ah yes, there is nothing for that; you're best off reading the reference implementation of the parser as well as hnix
<mdash> slabity[m]: have you seen hnix?
<slabity[m]> Trying to make a parser
<slabity[m]> joepie91_to_go: That's why I'm hoping for a more formal description
<joepie91_to_go> slabity[m]: for learning the language, https://medium.com/@MrJamesFisher/nix-by-example-a0063a1a4c55 is a good start
<joepie91_to_go> slabity[m]: none that is up to date
<slabity[m]> Is there a formal description of the Nix language? Or do I need to extract information from the manuals?

2018-07-20

<infinisil> slabity[m]: I am going to NixCon but not talking :)
<srhb> slabity[m]: Call for participation is open through july, so I guess you'll have to wait a bit
<slabity[m]> I want to find out what the talks are about
<slabity[m]> I'm curious. Who here is going to NixCon this year?