<WilliamHamilton[>
could you show me how do I set a cabal flag for a haskell package?
justan0theruser has joined #nixos
justanotheruser has quit [Ping timeout: 246 seconds]
<infinisil>
WilliamHamilton[: Gotta be a bit more specific than that
<WilliamHamilton[>
infinisil: right, I was grepping the nixpkgs and should have found something, so the question now is how I do this idiomatically: I want to do an override of a package setting --extra-lib-dirs because I think a dependency isn't picked up
<WilliamHamilton[>
the package in question is haskellPackages.z3
<WilliamHamilton[>
and I don't think it knows how to find the right z3
<infinisil>
How do you know that? What's the error?
<infinisil>
WilliamHamilton[: ^
jluttine has quit [Ping timeout: 240 seconds]
<WilliamHamilton[>
infinisil: I don't know that, expecially because in `hackage-packages.nix` it seems to be calling z3 in libraryHaskellDepends. The error I get is
o1lo01ol1o has quit [Remote host closed the connection]
<WilliamHamilton[>
Taneb suggested before that probably in the package there is an invocation for `z3` that should be patched to `${pkgs.z3}/bin/z3` like it's done for `sbv`, but I did not find yet that point in haskellPackages.z3 sources
fusion809 has quit [Ping timeout: 250 seconds]
<WilliamHamilton[>
srhb: no, the versions work for `sbv`, for example, and in haskellPackages.z3's readme it says that a z3 4.* release should work
<srhb>
WilliamHamilton[: Is it reproducible just by loading z3 in ghci?
<{^_^}>
Z3Prover/z3#1813 (by tddsg, 21 weeks ago, closed): Error when compiling a Haskell program using the Z3 library
<WilliamHamilton[>
infinisil: Indeed I don't think it's a haskell-z3 error. In the readme the author suggests `Otherwise use the --extra-lib-dirs and --extra-include-dirs Cabal flags when installing`
drakonis has quit [Quit: WeeChat 2.3]
<WilliamHamilton[>
infinisil: but his machine did have an old build of z3, we don't, and the z3 packaged up is pretty new I think (let me check)
<infinisil>
Yeah this issues solution is kinda unrealistic on Nix
<WilliamHamilton[>
yes, we have the latest z3 (4.8.4)
<srhb>
WilliamHamilton[: Do you want to open an issue for haskell-z3 or shall I?
<infinisil>
srhb: Isn't this an issue of z3?
<srhb>
infinisil: The issue with z3 is the out-of-date docs.
Widdershin has joined #nixos
<infinisil>
I don't see any reason this symbol should've been removed
<srhb>
They plain dropped that name.
<srhb>
Well, the commit appears to do it quite intentionally.
<WilliamHamilton[>
srhb: it's interesting that I was about to ask both questions, and yes it seems a z3 bug, at least because that symbol is still in the docs
<srhb>
The docs have not been regenerated since 4.8.x was released.
<srhb>
If you regenerate them by hand, they're correct.
<WilliamHamilton[>
please go ahead and open the bug, as you found it (I'll do it only if you prefer not)
<srhb>
Correct insofar as they don't claim that this symbol exists :-P
<Widdershin>
Hi all, I have a question about using Nix on dev teams. I've got a project I've created a default.nix for, but when I tried to get another member of my team to install it they ran into an error because they had a different version of Nix than I did. Is there a way to install a specific version of Nix?
<srhb>
I'll open the haskell-z3 one then.
<WilliamHamilton[>
so it would also work removing the ffi from haskell-z3? I'll try to do that in a fork (Thanks for the gist in the meantime!)
<infinisil>
srhb: But mention that we're not sure why it was removed, and maybe ping the person that removed it
<WilliamHamilton[>
srhb: perfect :)
<infinisil>
WilliamHamilton[: Remove the ffi? Not sure what you mean
<WilliamHamilton[>
infinisil: sorry, I mean they must be using that symbol in haskell-z3, right? Otherwise I wouldn't trigger the error (for example, sbv doesn't)
<infinisil>
Yeah exactly
<srhb>
Yes, that would also work.
<infinisil>
I mean, either they remove that function from haskell-z3, or z3 adds it again, those are the 2 ways to resolve this afaik
<infinisil>
And because the former breaks backwards-compatibility, I'd hope the latter is used
<WilliamHamilton[>
thank you very much for the help srhb infinisil !
<{^_^}>
[nixpkgs] @vbgl merged pull request #55043 → coqPackages_8_9: disable a few packages that do not build → https://git.io/fhyxk
<{^_^}>
[nixpkgs] @vbgl pushed to master « coqPackages_8_9: disable a few packages that do not build »: https://git.io/fhHqg
<infinisil>
WilliamHamilton[: Notes for the future: If you have problem X (the error), don't ask for Y (how to pass cabal flags). This is known as the XY-problem
<infinisil>
WilliamHamilton[: And: Always show the commands you ran, and what error you got, so people can reproduce it
<infinisil>
Those things will make helping you much easier
<WilliamHamilton[>
infinisil: right, I'll improve this aspect, thanks!
<infinisil>
(and anybody asking questions in all technical topics really)
<WilliamHamilton[>
you are able to override the `src` attribute, but entering the `mkDerivation` function
thc202 has quit [Ping timeout: 250 seconds]
<srhb>
WilliamHamilton[: Actually, I'm overriding the resultant attribute set
<WilliamHamilton[>
srhb: how can I see the resultant attribute set?
<srhb>
WilliamHamilton[: The easiest way is to explore it with the repl
<srhb>
nix repl '<nixpkgs>' -- then pkgs.z3.<TAB>
<WilliamHamilton[>
oh, in nix repl, `z3.<TAB>`
<srhb>
Right
DrLambda has joined #nixos
<WilliamHamilton[>
and for example src points to a drv, is there a way to see that in a comprehensible form?
<WilliamHamilton[>
because even `less` is not much useful
<srhb>
nix show-derivation
<srhb>
That's pretty much as close as you can get.
trcm has quit [Quit: WeeChat 2.2]
<WilliamHamilton[>
but in `nix show-derivation /nix/store/9jxxxphffsirqi5b69zr4hvcgxm70wkj-source.drv | less` there is no `src` anymore
<srhb>
(we can't "unapply" fetchFromGitHub)
<WilliamHamilton[>
ooh, so that derivation is how src is built?
<srhb>
Yes
gagbo has quit [Quit: I'm out !]
<WilliamHamilton[>
srhb: I get it now, thanks again
<srhb>
WilliamHamilton[: Welcome!
rcshm has quit [Ping timeout: 250 seconds]
fusion809 has joined #nixos
Rusty1 has joined #nixos
mmlb has joined #nixos
<{^_^}>
[nixpkgs] @peti pushed to haskell-updates « hackage-packages.nix: automatic Haskell package set update »: https://git.io/fhHqQ
doyougnu has quit [Ping timeout: 246 seconds]
Guest96086 has quit [Ping timeout: 268 seconds]
o1lo01ol1o has joined #nixos
eadwu has quit [Quit: WeeChat 2.3]
schjetne has joined #nixos
maximiliantagher has quit [Ping timeout: 246 seconds]
schjetne has quit [Ping timeout: 245 seconds]
eadwu has joined #nixos
wolke has joined #nixos
<pie___>
infinisil, the problem with the xy problem is when you think trying to get someone to solve your original problem will make them not care anymore
<gchristensen>
yes
<gchristensen>
sometimes you have to lie about your X
rcshm has joined #nixos
drakonis has quit [Quit: WeeChat 2.3]
<pie___>
it feels more likely that someone can/will help solve a smaller thing ;~;
<colemickens>
can I check if a closure is held by a gc root? and/or if I build a system configuration by hand but run `result/bin/switch-to-configuration switch` does it get a root?
freeman42x has quit [Ping timeout: 252 seconds]
<clever>
colemickens: nix-store --query --roots
<clever>
colemickens: the result link itself is a root, and switch/test will update /run/current-system, which is another root
<colemickens>
thanks x2
DrLambda has quit [Ping timeout: 240 seconds]
slack1256 has quit [Remote host closed the connection]
iqubic` has quit [Remote host closed the connection]
<teto>
I have a src = builtins.fetchGit { url ; ref } and I just pusehd an update. I've tried to call nix-build -A myPackage ~/nixpkgs --option tarball-ttl 0 to force a refetch but nothing happens. is that expected ?
iqubic has quit [Ping timeout: 240 seconds]
<slack1256>
Are you passing the correct revision to fetchGit?
<tilpner>
teto: You can wipe ~/.cache/nix/tarballs instead of tarball-ttl, but I don't see how fetchGit would tarballs
slack1256 has quit [Remote host closed the connection]
<tilpner>
teto: Are you passing ref, or rev? I think it would be named rev, but I haven't used builtins.fetchGit much
<teto>
I am passing ref = "trunk"
<teto>
I thought tarball-ttl was a more global setting used even by fetchGit
<tilpner>
Try with rev
<tilpner>
And you might be right, tests/fetchGit.sh uses tarball-ttl too
<teto>
thing is I don't want to specify a rev, I just want to use the branch name and fetch the last version. I find it easier to pass tarball-ttl 0 than updating the rev everytime
maximiliantagher has quit [Ping timeout: 240 seconds]
<jomik>
I need to install virtualbox. I'd actually prefer to have it in a nix-shell, but it seems I need to enable it as a service, eh? `virtualisation.virtualbox.host.enable`. Or should it be enough to just load the virtualbox package?
<jomik>
Assuming that my user is in the group vboxusers, of course.
<jomik>
I am leaning towards the `virtualbox.host` being whether to enable network and usb interfaces in the box?
<Mic92>
johnw_: thanks! I was hoping that they have it by accident. Does python -c 'import locale; locale.setlocale(locale.LC_ALL, "en_US.UTF-8")' just works? Ideally this would be tested in a nix-shell --pure -p python2
erictapen has joined #nixos
filterfish has joined #nixos
goibhniu has joined #nixos
<johnw_>
yeah, that works in that nix-shell
<Mic92>
johnw_: I suppose on macOS we read from /usr/share/locale/ ?
<johnw_>
i have no idea
ryantm has quit [Ping timeout: 268 seconds]
wigust- has joined #nixos
<Mic92>
I can check if I find an answer in nixpkgs itself
<tilpner>
It does a little more than usb and network, and I don't know if it's able to function without these
<Mic92>
johnw_: do you have a $PATH_LOCALE environment set in nix-shell?
Tucky has quit [Ping timeout: 246 seconds]
<johnw_>
yes, the value is /nix/store/vlm27xdg3x6wz7bghnwjfpmb2f3vhm2q-adv_cmds-osx-10.5.8-locale/share/locale
<jomik>
tilpner: Does it? It looks like it sets up udev rules for usb and netctl?
<Mic92>
johnw_: great. That could be the solution!
DrLambda has quit [Ping timeout: 250 seconds]
<tilpner>
jomik: It adds the kernel modules too. Maybe it can load those without the module, if you give it root
ikwildrpepper has quit [Ping timeout: 246 seconds]
wigust has quit [Ping timeout: 272 seconds]
ikwildrpepper has joined #nixos
<Mic92>
I really need a better macOS VM!
<tilpner>
jomik: And the suid wrappers might help you to not have to run it as root. I don't know really know, just try it?
Tucky has joined #nixos
<jomik>
Oh, it does :joy:
<jomik>
Thank you.
<Mic92>
LnL: do you know if non-nixos programs respect PATH_LOCAL on macOS? I want to introduce a C.utf-8 in nixpkgs. On linux we already have it in staging for glibc and now we could add it to adv_cmds for macOS as well.
<jomik>
Ah, back to lecture. Thanks for clearing it up tilpner :)
jomik has quit [Quit: WeeChat 2.2]
<{^_^}>
[nixos-homepage] @balsoft closed pull request #262 → Add a Telegram support group → https://git.io/fhSFg
thc202 has joined #nixos
Makaveli7 has quit [Ping timeout: 252 seconds]
Makaveli7 has joined #nixos
Jetien_ has quit [Ping timeout: 245 seconds]
kvda has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
DrLambda has joined #nixos
phreedom_ has joined #nixos
phreedom has quit [Ping timeout: 256 seconds]
<Taneb>
I've got an error running "nix-store --optimize":
<Taneb>
"error: cannot link '/nix/store/.tmp-link-29450-1398403467' to '/nix/store/.links/16ixs5l71x42vrsknxx9gbmhy783js34x736rxk5bqz94q047qzz': File exists"
<Taneb>
Any idea how to resolve this?
Jetien_ has joined #nixos
<clever>
Taneb: stat /nix/store/.links/16ixs5l71x42vrsknxx9gbmhy783js34x736rxk5bqz94q047qzz
<siers>
Hello those that use nix on darwin! Do you imperatively change your user env or do you have it be made somehow declaratively?
<tilpner>
Taneb: What filesystem is /nix/store on?
<tilpner>
A
<tilpner>
(Oops)
<Taneb>
tilpner: it's on the root file system
<tilpner>
And what filesystem is your /?
simukis has joined #nixos
<tilpner>
(e.g. ext4, zfs, btrfs)
<Taneb>
...good question
<Taneb>
I think it's lvm-encrypted ext-something
<tilpner>
lsblk -f
<Taneb>
ext4
<tilpner>
I have no idea if nix-store --verify cares about .links, but it won't hurt to run
<{^_^}>
[nixpkgs] @ilikeavocadoes opened pull request #55434 → excelCompare: init at 0.6.1 → https://git.io/fhHG3
<tilpner>
I guess the next step is strace-ing the --optimise
<tilpner>
Ehh, the daemon will do all of the work, so that's not going to help
<kyren>
Taneb: I experience exactly the same bug with nix on macos, do you also use home-manager by chance? I can't imagine why that has anything to do with it but it seemed to be a commonality
<kyren>
I've just been removing the links files :/
orivej has quit [Quit: No Ping reply in 180 seconds.]
<{^_^}>
[nixpkgs] @andir pushed to release-18.09 « Revert "linux: Adds patch for fixing wifi on raspberry pi" »: https://git.io/fhHGn
rfold has joined #nixos
<Taneb>
kyren: no, I don't use home-manager, but it's a shared computer (this is nix on Ubuntu)
<Taneb>
...it succeeded with strace
<Taneb>
Maybe the --verify rejigged it
orivej has joined #nixos
<kyren>
oh, interesting, never mind then I mixed up conversations, might be totally unrelated
<Taneb>
tilpner: clever: kyren: thanks for the help
<LnL>
Mic92: no, what's that?
<Mic92>
LnL: we use in darwin stdenv to set the directory where locales can be found
<Mic92>
as an alternative to /usr/share/locales
simukis has quit [Quit: simukis]
mcnesium has quit [Quit: WeeChat 2.3]
<kyren>
out of curiosity, I went to see if I could trigger the .links/xxxxx `File exists` bug again by doing a darwin-rebuild, and I can, and nix-store --verify does not change anything
<Mic92>
I was hoping we can do export LANG=C.UTF-8 for all stdenv implementations
<LnL>
Mic92: ah, I assume that works for everything
<{^_^}>
[nixpkgs] @layus opened pull request #55436 → Nixos manual: error out on missing IDs → https://git.io/fhHGr
<kyren>
I have auto-optimize on, and this bug is super super annoying (assuming it's the same bug)
<Mic92>
LnL: could you maybe check if with dtruss if the system python picks it up, when you do /usr/bin/python -c 'import locale; locale.setlocale(locale.LC_ALL, "en_US.UTF-8")' in a nix shell.
ryantm has joined #nixos
<Mic92>
it should then load something like /nix/store/vlm27xdg3x6wz7bghnwjfpmb2f3vhm2q-adv_cmds-osx-10.5.8-locale/share/locale
<Mic92>
and I try to set up my macOS vm again to check If I can patch this package to have a C.UTF-8 version
DrLambda has quit [Quit: Leaving.]
DrLambda has joined #nixos
<LnL>
don't see anything locale related
<Mic92>
weired.
<Mic92>
weird
<Mic92>
Anyway I can check this later I guess.
<{^_^}>
[nixpkgs] @Mic92 merged pull request #55412 → hunspell-dicts: add support for Hungarian dictionary → https://git.io/fhHk0
<Mic92>
LnL: let's say we do `LANG=C.UTF-8` then we get a problem if someone runs a non-nixpkgs application from a nix-shell because the locale would be only valid our programs.
Guanin has quit [Remote host closed the connection]
Guanin has joined #nixos
Tucky has quit [Ping timeout: 245 seconds]
jacereda has joined #nixos
<jacereda>
hi... is it ok to submit a PR to release-18.09? or should it always go to master?
<etu>
Normally you want it to go to master
<etu>
But if it couses big rebuilds it should go to staging
<etu>
And PR's to release-18.09 is okay if it needs to be backported to stable
<jacereda>
etu: it's a problem with ffmpeg-full that triggers an assertion unnecesarily and I can't override that. I'd like to stick to 18.09 if possible and have cached builds of that package because it takes ages to rebuild.
Tucky has joined #nixos
wolke has quit [Remote host closed the connection]
<{^_^}>
Found in packages: glib, ibus, evince, brasero, empathy, liferea, deja-dup, glib.bin, xfce.gvfs, gnome3.eog, gnome3.gcr, notify-osd, gnome2.gvfs, gnome3.ghex, gnome3.gvfs, gnome3.folks, gnome3.gedit, gnome3.totem, sound-juicer, deepin.go-lib, gnome3.mutter, gnome3.vinagre, pulseaudioFull, pulseaudioLight, brasero-original, gnome3.evolution, gnome3.mutter328, ibus-with-plugins, gnome3.gnome-shell, gnome3.libgnomekbd, deepin.deepin-mutter, and 13 more
<ar>
,locate bin/gsettings
<{^_^}>
Found in packages: glib.bin
_kwstas has joined #nixos
_kwstas has quit [Remote host closed the connection]
_kwstas has joined #nixos
_kwstas has quit [Client Quit]
<tilpner>
ar: {^_^} will also respond in a private query
DrLambda has quit [Ping timeout: 240 seconds]
_kwstas has joined #nixos
_kwstas has quit [Client Quit]
petrkr has joined #nixos
cswl has quit [Quit: Connection closed for inactivity]
<Guanin>
Hi, yesterday I opened an issue because I have a problem with amdgpu. Can someone have a look if there is any information missing? https://github.com/NixOS/nixpkgs/issues/55407
<{^_^}>
#55407 (by Amarandus, 17 hours ago, open): Black screen with amdgpu - AMD Radeon Pro WX3100
<ottidmes>
Guanin: when dealing with hardware issues like you have I also always try other distros to rule out whether it is due to how things are packages/configured on NixOS, did you already try that?
<Guanin>
Yes, I tried the ubuntu live system - everything works there (except that I did not try binding the 1080 to vfio-pci)
<petrkr>
Again thanks for yesterday {^_^} and infinisil
<tilpner>
So nice of you to thank bots too, just don't expect {^_^} to reply :)
<ottidmes>
Guanin: its very difficult to help with these kind of setup specfic issues. I guess all you can do is go through the standard debugging steps, like does the AMD GPU work normally, without passthrough?
<Guanin>
It is confusing because the amdgpu kernel module attaches to the GPU without any problems
nD5Xjz has quit [Ping timeout: 240 seconds]
<Guanin>
Oh, and I noticed that i can use "nomodeset" to get an output, but only at a bad resolution, and everything crashes then when attaching the 1080 to a virtual machine
<infinisil>
Taneb: ripgrep for 'substitute\(\)'
<clefru>
petrkr: that's awesome, I have a trezor laying around here, and had the same intention. except that craming the trezor SDK into the initrd takes a whole lot of space because of python. I am the original author of LUKS btw ;)
erictapen has quit [Ping timeout: 268 seconds]
cmacrae has quit [Remote host closed the connection]
cmacrae has joined #nixos
cmacrae` has joined #nixos
<siers>
is it possible to have a package that'd only install on linux?
<siers>
uhm, darwin that is
<tilpner>
Something like meta.platforms = lib.platforms.darwin;
<clever>
siers: just set meta.platforms correctly, examples should be in nixpkgs
<siers>
then it will refuse to install it?
<clever>
it will refuse to even evaluate the expression
<pie_>
I'm not sure if this idea even makes sense, but has anyone tried / thought about "configuration packages", which is like....packages but for configuration variables
renais has quit [Remote host closed the connection]
renais has joined #nixos
<symphorien>
I think you can share nixos modules via nur
<pie_>
are modules the equivalent of packages for configuration?
<pie_>
the biggest problem with this question is i dont actually have a defined meaning for "packages but for configuration", I guess I mean sets of config options? :I
* pie_
ponders
o1lo01ol1o has joined #nixos
<Taneb>
pie_: a module can do things like setting files in /etc and describing systemd services
<siers>
it is taking a while with all the tests :)
barrel has joined #nixos
<srhb>
I've restarted it, but it'll probably only get to it after chewing through a bunch of staging.
<srhb>
Nevermind, it's building now. :)
<siers>
woo!
<pie_>
\o/
agander_ is now known as agander
<{^_^}>
[nixpkgs] @Izorkin opened pull request #55445 → haskellPackages.insert-ordered-containers: fix test phase → https://git.io/fhHcg
renais has quit [Ping timeout: 246 seconds]
simukis has quit [Quit: simukis]
cmacrae` has joined #nixos
jacereda has quit [Ping timeout: 250 seconds]
simukis has joined #nixos
o1lo01ol1o has joined #nixos
Makaveli7 has quit [Quit: Leaving]
psy3497 has joined #nixos
renais has joined #nixos
<laas>
does anyone here know if there is any syntax highlighting plugin for nix for kakoune?
NightTrain has quit [Quit: Lost terminal]
<psy3497>
Anyone knows if cabal's ghc extensions section is reflected in the nix expression?
cmacrae` has quit [Ping timeout: 250 seconds]
<psy3497>
I do not see it in the nix expression and I get compilation errors about not specifying GHC extensions which were specified in the cabal file to be enabled on every source file
<pie_>
laas: any luck with the lutris stuff?
<laas>
pie_: I came to the conclusion that I shouldn't be using Lutris anyway
<laas>
I will just make nix expressions for each game
<laas>
much more logical
<pie_>
laas: lol, ok
<laas>
unfortunately no UI or easy configuration though
<pie_>
laas: i was wanting to make something for configuring WINE stuff but i havent made much progress yet
<{^_^}>
[nixpkgs] @tilpner opened pull request #55446 → slirp4netns: init at v0.3.0-alpha.2 → https://git.io/fhHcX
<ottidmes>
psy3497: I have only done that in a project I am working on right now that I have only worked on via nix-shell / cabal new-repl, I will try and build it and see what happens
<psy3497>
thanks ottidmes
cmacrae` has joined #nixos
<psy3497>
ottidmes: I am not sure if it matters, but are you using sandbox builds?
cmacrae` has quit [Remote host closed the connection]
<psy3497>
I did not have this problem at work (sandbox mode is disabled) and at home sandbox mode is enabled and I ahve this problem
<psy3497>
And this is when I all of a sudden realized that the extensions do not appear in the nix expression.
<ottidmes>
psy3497: sandbox is enabled
<psy3497>
Cool
<psy3497>
careful of the .ghc.environment file, it interferes with nix-build causing it to fail
baum has joined #nixos
<ottidmes>
psy3497: I just changed one of my Haskell project to have the extensions defined in the cabal file rather than per file, and it does build
orivej has quit [Ping timeout: 264 seconds]
<psy3497>
You're right! I just got it working right now!
<psy3497>
The problem was that in the cabal file the field was 'other-extensions' and not 'default-extensions'
<baum>
hi, are there naming conventions for nixpkgs? are names like "zathura-with-plugins" intented?
<psy3497>
And it indeed does not appear in the nix expression.
<ottidmes>
psy3497: BTW if I have both library and executable defined in my cabal file, is there any way to share config between them (I could probably search this myself, but if you happened to know)?
<psy3497>
Share config?
<psy3497>
As in extensions? or build-depends?
<ottidmes>
psy3497: the default-extensions list
<psy3497>
ah
<psy3497>
Yes there is.
<psy3497>
It's called hpack :)
<psy3497>
But that generates the cabal file for you.
<symphorien>
baum: it's not unusual
<ottidmes>
psy3497: ah ok, thanks, guess I will just stick with copy pasting for now
<psy3497>
ottidmes: hehe sorry
<symphorien>
Especially the derivation names (as opposed to attribute names) are sometimes, say, unexpected
ghostyy has quit [Read error: Connection reset by peer]
ghostyy has joined #nixos
<baum>
symphorien: imo it's kinda strange that you install it with "nix-env -i zathura-with-plugins" yet you run a shell with "nix-shell -p zathura"
<symphorien>
Let's say that nix-env -i without -A is legacy and should be avoided
<ottidmes>
psy3497: they should have introduced a Haskell2018 or something by now where all extensions are in it, except those you want to be explicit about anyway (TemplateHaskell, UndecidableInstances, etc.)
<{^_^}>
[nixpkgs] @globin pushed commit from @r-ryantm to master « flow: 0.91.0 -> 0.92.0 »: https://git.io/fhHcN
<psy3497>
ottidmes: I see your point, but then the haskell standard will be too big for other compilers to ever be developed, although Haskell is not Haskell without GHC anymore indeed ;)
o1lo01ol_ has joined #nixos
<ottidmes>
psy3497: or I guess GHC2018, since its GHC specific
<{^_^}>
[nixpkgs] @globin pushed commit from @etu to release-18.09 « php71: 7.1.25 -> 7.1.26 »: https://git.io/fhHcj
reivilibre has joined #nixos
NickHu has joined #nixos
<Mateon1>
Hi, I'm not sure where to report this, but `nix-env -u` keeps breaking my openjdk. I installed openjdk 8 via nixos.openjdk, but `nix-env -u` tries to update the jdk to 11, which breaks a lot of my applications.
<baum>
gchristensen: nice, thanks!
<Mateon1>
The fix/workaround is `nix-env -e openjdk; nix-env -iA nixos.openjdk`
<pie_>
does nix escape strings during substitution with ${someexpr}
<ottidmes>
Mateon1: in that case, just install openjdk8 rather than openjdk, which is pinned to remain at version 8
<symphorien>
(Yes it's online but, well)
<Mateon1>
ottidmes: There is no openjdk8, just opendjk and openjdk11
Synthetica has joined #nixos
<Synthetica>
Spotify doesn't respond to mouse input on my 2x scaled display under Wayland
<Synthetica>
Anyone else ever see a similar issue?
<ottidmes>
Mateon1: on what channel are you, I checked its existance before suggesting it, so I have it in my Nixpkgs checkout
<baum>
symphorien: thanks, but till now i just used "nix-env -qa | fzf | xargs nix-env -iA", guess i'll have to rewrite it to use json instead
<symphorien>
by the way, use -qaP for attribute names
<Mateon1>
ottidmes: for my user 19.03 and unstable
<Mateon1>
`nixos` is 19.03
<ottidmes>
Mateon1: its surprising that they would remove version 8, since its still being used by many things, but I am on 18.09 where it still exists
<Mateon1>
Note that unstable.openjdk is still opendjk-8u202
<Mateon1>
jdk* ugh, for some reason I can't type that
zfnmxt has joined #nixos
<baum>
symphorien: alright, this answers my first question, thanks!
<tilpner>
If I have to use foo.bin instead of foo, is something wrong with the foo expression?
edcragg has joined #nixos
<tilpner>
(I don't remember a lot of .bin in nixpkgs, but I also wasn't looking for it)
barrel has quit [Ping timeout: 250 seconds]
<mikky>
hi, I'm confused with Xfce versioning. services.xserver.desktopManager.xfce installs pretty outdated v 4.12 derivations but newer 4.13 are available and if installed explicitly, they're not used. I just get a bunch of conflicts.
<tilpner>
There's a bunch of getBin, so it might be fine
<symphorien>
tilpner: iirc ${foo} defaults to the first output in the output list
<tilpner>
symphorien: Ah! So if $out is nearly empty, I should switch them around
<symphorien>
usually it is bin, but sometimes it is lib for some libs
<tilpner>
If all $out contains is nix-support/propagated-build-inputs (which mentions $bin), should I even have $out?
<ottidmes>
Mateon1: just know that openjdk8 exists on unstable just as well
<ottidmes>
> with import "channels:nixos-unstable" { }; with lib; filter (hasPrefix "openjdk") (attrNames pkgs)
Tucky has joined #nixos
<{^_^}>
[ "openjdk" "openjdk11" "openjdk8" ]
<tilpner>
I don't think that did anything
<tilpner>
You want import (builtins.fetchTarball "channel:nixos-unstable") {}, but the bot wouldn't fetch anything
<tilpner>
infinisil: Maybe add allowed-uris = channels: to your nix.conf
<ottidmes>
tilpner: hmm, either way, with my local nixos-unstable checkout it gives me the same results, so my example might me wrong, but the answer remains the same
<tilpner>
Right, it uses some version of master IIRC
<ottidmes>
nix eval '(with (import <nixpkgs> { }).unstable; with lib; filter (hasPrefix "openjdk") (attrNames pkgs))' gives me [ "openjdk" "openjdk11" "openjdk8" ] (checkout is few days old)
<tilpner>
mikky: How are you installing them?
<mikky>
tilpner: environment.systemPackages, all of them mentioned specifically
<jw358>
really basic question about expectations of nix-env -i, should i be able to keep nix and my user-profile if i run nix-store --collect-garbage?
<jw358>
currently nix-env and nix-store and such also get wiped out
<srhb>
jw358: Yes, you should.
<srhb>
jw358: your profile etc should have a garbage collection root, preventing it from being collected.
<symphorien>
past nix versions could corrupt your profile this way
<Mateon1>
ottidmes: Sorry, just saw that response - wow, I've been using `nox openjdk`, which did not list openjdk8
<jw358>
srhb: where should i look to troubleshoot this?
<symphorien>
the issue has been fixed since then
<srhb>
jw358: I'd update nix first, then try again from fresh
<Mateon1>
But that attribute IS in fact defined
<yayforj>
what's the "right" way to enable profiling? in manual it says that you just override everylittle thing with enableWhateverProfiling
<Mateon1>
I must be misunderstanding what nox searches through
<yayforj>
is that the way to go?
<jw358>
srhb: symphorien i have nix 2.2.1, and i haven't had any nix version released after october 2018 on this machine
<yayforj>
that's for haskellPackages i mean
<ottidmes>
Mateon1: I have seen it mentioned at the PR checklist, but I never used nox myself, `nix search` and nix-locate are probably the best tools for searching at the moment
<ottidmes>
Mateon1: and a grep/search through nixpkgs itself also can be very useful to get more definite answers
<Mateon1>
Hm, I think I have a clone of nixpkgs laying around
<Mateon1>
Not sure if I can pull because I've messed with some packages locally
<tilpner>
You can always use the current channel checkout
<tilpner>
cd $(nix-instantiate --find-file nixpkgs)
<jw358>
so i have like `~/.nix-profile` pointing to `~/.nix-profile-62-link`
<jw358>
`~/.nix-profile-62-link` points to `/nix/store/somehash-user-environment`
reinhardt has quit [Ping timeout: 272 seconds]
<jw358>
if i look at the contents of `/nix/var/nix/profiles/per-user/$(whoami)` there isn't any `profile`, only `profile-1-link` and so on
<symphorien>
you should have ~/.nix-profile pointing to /nix/var/nix/profiles/per-user/$(whoami)/profile
petrkr has joined #nixos
renais has quit [Ping timeout: 244 seconds]
<clefru>
petrkr: that's awesome, I have a trezor laying around here, and had the same intention. except that craming the trezor SDK into the initrd takes a whole lot of space because of python. I am the original author of LUKS btw ;)
<symphorien>
and /nix/var/nix/profiles/per-user/$(whoami)/profile pointing to /nix/store/somehash-user-environment
<jw358>
how should i fix my nix installation to do that correctly?
Tucky has quit [Ping timeout: 246 seconds]
<jw358>
nix and nix-env versions report 2.2.1
<sphalerite>
make a symlink ~/.nix-profile -> /nix/var/nix/profiles/per-user/$USER/profile
nD5Xjz has joined #nixos
<petrkr>
clefru, I using Go implementation from xaionaro, but forked for some usage in Nix and so
<jw358>
sphalerite: but then nix-store --gc doesn't work
<petrkr>
as long I do not have NixOs and it's quite new for me. I do not know how that implementation will be accepted by community, but I can release it as proof-of-concept and idea, then someone can make it "that nice way"
<symphorien>
jw358: is it a single user install ? if so, easiest way is to wipe and reinstall nix
<jw358>
how does "wipe" work?
<clefru>
petrkr: do you use this "encrypt_keyvalue" feature?
<symphorien>
jw358: remove /nix and ~/.nix-profile
<jw358>
i have had nix destroy itself and used the installation script on the website
<jw358>
yes, i've done that
<petrkr>
clefru, I saw some implementation of yubikey, and I am already littlebit familiar with "includes" so I thinking there could be good point how to make separated files for trezor and/or yubikey and make it as includes
<sphalerite>
jw358: how does it not work?
<symphorien>
jw358: when ? because you are at the 73th generation so it looks like an "old" installation
o1lo01ol_ has quit [Remote host closed the connection]
lfish has joined #nixos
nD5Xjz has quit [Ping timeout: 272 seconds]
Tucky has joined #nixos
nD5Xjz has joined #nixos
fearlessKim[m] has joined #nixos
<lfish>
How do I search for the name of a package? I'm looking for bootstrap, it's in the twitter-bootstrap in nixpkgs, but that name fails in a .nix, and looking for it with `nix-env -qa ...` takes forever
<mikky>
symphorien: that's true, but 4.12 packages in nixpkgs are way outdated :/
<symphorien>
you should use -qaP for attribute names, lfish
reinhardt has joined #nixos
<clefru>
petrkr: trezor.cipher is some kind of dummy value?
<wedens>
lfish: another option is to use tab completion in `nix-repl "<nixpkgs>"`
<jw358>
symphorien: sphalerite: what can i say? it just doesn't work, and i do rm -rf /nix and rm ~/.nix-profile and rm ~/.nix-profile*
<clefru>
petrkr: what do you need -p $out/bin/trezor-askpass for? is this a helper script to output this PIN layout grid?
<petrkr>
clefru, since it's used that encrypt value feature, you have two ways... Cipher is that string, which being encrypted
<clefru>
petrkr: ah forget about my last question. i forgot how the trezor flow works
<petrkr>
clefru, yes, it is external command used for read stdin for PIN and passphrase. it is how xaionaro did that tool in Go
<symphorien>
jw358: can you redo it once,logout, login, and then tell us where ~/.nix-profile points to and the output of nix-env --list-generations ?
<clefru>
petrkr: but this encrypted value is a static random public thing, right? I thought about using the device UUID for that
<petrkr>
clefru, it can be done whole in Go, without external tools, but I just use already did stuff than programming mine
<petrkr>
there are 2 things
<petrkr>
1) value which being encrypted 2) key which will be used
<petrkr>
value and key must be same in order to get same encrypted value
<jw358>
symphorien okay, i'll try one more time again
<sphalerite>
jw358: what do you expect to happen when you nix-store --gc? What actually happens?
<jw358>
everything is destroyed
<jw358>
nix-env is also gone
<petrkr>
and also if you want decrypt that "value" you must use same key
<jw358>
nix the binary is gone
<jw358>
i thought that it would keep whatever is in my latest user profile
<petrkr>
here value and key can be constants, since encrypted value is different for different trezor seed
<jw358>
maybe this premise is just misunderstood
<petrkr>
but always same with same trezor
agander has quit [Ping timeout: 245 seconds]
<clefru>
petrkr: thanks :) I know how this feature works
<sphalerite>
jw358: when the symlink is in /nix/var/nix/profiles/per-user/ ?
<clefru>
petrkr: I just wonder about your design choice wrt value chosen for encryption.
<jw358>
Whatever way the default nix installation works
<sphalerite>
jw358: so you have ~/.nix-profile -> /nix/var/nix/profiles/per-user/$USER/profile, and /nix/var/nix/profiles/per-user/$USER/profile -> profile-$n-link ?
<petrkr>
clefru, here that Value is used as "entropy" but that entropy must be same, that is why it's in config. and length of that entropy make length of encrpyted value
petrkr has quit [Remote host closed the connection]
<petrkr>
so even if someone know your value, it's useless, because actual key on LUKS is that encrypted HEX value (like double sized in hex) and it's generated by trezor by EC curves
<jw358>
No, the nix per user profile is not created
petrkr has joined #nixos
<petrkr>
I tought about use that "key" for different devices, because it's used on trezor's screen.. but in case you will change your hard-drive, you will change UUID/devicename then you must use old one
<clefru>
petrkr: my choice would have been the device UUID, not entropy. simply because if you burn your nixconf (and your initrds) you have lost access to your hard disk. with using the UUID, then the required unlocking information stays with the luks device itself, and all you need is a trezor device (or its recovery seed)
<petrkr>
clefru, that is why it's variable, everyone can use what they wants
<petrkr>
only condition is it must be same everytime you wanna access your LUKS device
renais has joined #nixos
<clefru>
petrkr: yeah the drawback is that re-keying doesn't really work nicely. I thought about using the "salt" of a key slot, so rekeying is possible, but the cryptsetup API doesn't allow for setting a salt for new passwords
<{^_^}>
[nixpkgs] @globin pushed 2 commits to release-18.09: https://git.io/fhHWI
<petrkr>
for example before at linux mint I wanted do device name (as sda6) but then I changed SSD to NVMe, and sda6 changed to nvme0n1p6
<petrkr>
and then I had to by hand decrypt from Live and add key with nvme0n1p6 value
<petrkr>
but I am programmer / administrator, so I can repair it myself... Lot's of peooples are not such advanced users
<clefru>
petrkr: I was talking about the UUID information in the LUKS header. Don't use plain linux device names. They are not stable. Always use /dev/disk/by-uuid/
<petrkr>
then I know, that is why to use UUID instead
<tilpner>
clefru: by-uuid can very be annoying if you replace a disk that's part of a raid
<petrkr>
clefru, that could be also option. As I wrote before. THis is proof-of-concept and everyone can contribute
<petrkr>
tilpner, but that raid itself (and LUKS) will have still same UUID
Guanin has quit [Remote host closed the connection]
<petrkr>
he probably ment this UUID:[petrkr@pkdell ~]$ sudo cryptsetup luksDump /dev/nvme0n1p6 |grep UUID
<tilpner>
petrkr: Specifically, I had two luks devices, and one of the uuids changed
<yayforj>
is there bincached version of haskellPackages which profiling enabled?
<clefru>
tilpner: I have no experience with raids, so I can't comment. Happy ZFS user here (10years+)
<tilpner>
clefru: This was with LUKS+zfs mirror
<jw358>
sphalerite: okay, fresh install, nix 2.2.1, ~/.nix-profile points to ~/.nix-profile-1-link which points to /nix/store/hash-user-environment, with one generation for 2019-02-08 16:29 for nix-env --list-generations
<tilpner>
I'm now using by-partlabel, because that's just the right amount of stability
makefu has quit [Ping timeout: 268 seconds]
<sphalerite>
jw358: that's weird, maybe the installer is broken
<clefru>
tilpner: if one disk fails don't you have to zpool replace failing-luks-uuid new-luks-uuid?
<petrkr>
btw NixOs can use somehow btrfs for generations instead symlinks ?
<jw358>
there is nothing in /nix/var/nix/profiles/per-user/$(whoami) other than channels now
<petrkr>
same like docker can use btrfs instead overlay2
<tilpner>
clefru: I temporarily reduced the mirror to a single dis
<sphalerite>
petrkr: it could porbably in principle, but what benefit would there be?
<symphorien>
jw358: I would open an issue, this looks like a bug
<symphorien>
can you paste the output of nix doctor ?
<petrkr>
sphalerite, that is also my question :) That is why I do only like proof-of-concept and working protoypes
<sphalerite>
symphorien: that's a thing??
<symphorien>
iirc it was merge recently
<sphalerite>
symphorien: it's not in my nix version
<symphorien>
but this is the very latest version
<sphalerite>
is that related to nix-info?
<clefru>
tilpner: I am still confused what's wrong with UUID in this setting. do you copy your LUKS header around to the new disk and therefore get conflicting UUIDs?
<symphorien>
let me check
<jw358>
i have some useless output anyway, it just says 'not an absolute path: ./ node_modules'
<symphorien>
wut ?
psy3497 has quit [Quit: WeeChat 2.3]
<symphorien>
sphalerite: yes I can confirm it exists as a nix builtin command in latest nix
<tilpner>
clefru: A new disk will have new UUIDs, so if the initrd tries to open luks partitions by specific UUIDs it'll fail
<petrkr>
tilpner, even in LUKS partition?
<clefru>
tilpner: Ah got it. My initrd is set up to ignore failures here
<petrkr>
tilpner, do not talk about hard-drive uuid, or partition uuid, but about luks uuid
<symphorien>
jw358: you say `nix doctor` outputs `not an absolute path: ./ node_modules` ?
<jw358>
yes
<symphorien>
something is terribly wrong
<jw358>
`Store uri: local error: not an absolute path: './node_modules'`
<tilpner>
petrkr: I was talking about partition uuids
<symphorien>
can you paste: env | grep -i nix
<petrkr>
clefru, tilpner anyway I think uuid is too short for enough entropy... but in other it's maybe much longer than user's passphrase
<clefru>
petrkr: It should be safe to encrypt "0" as all the entrophy comes from trezor
<petrkr>
but if you will encypt "0" output will be like just 8 bytes
<jw358>
but basically my workflow now is that i run nix-store --gc every three months nad have to have the installer script ready and give up 15 minutes
<symphorien>
does home manager create its own gc-roots ?
<jw358>
which isn't that horrible but it's whatever
<jw358>
not so nice
<symphorien>
if so it could be an alternative
<petrkr>
clefru, so 16 bytes
<jw358>
then i'd have to struggle with home manager isues?
<symphorien>
what do you mean ?
<jw358>
if i used it i mean
<symphorien>
the thing is: its internals are quite independent from nix-env and profiles
<symphorien>
so it could work even with a borked profile
<symphorien>
but I agree that your situation is not great, to the very least
nD5Xjz has quit [Ping timeout: 240 seconds]
<symphorien>
,home-manager
<{^_^}>
home-manager allows you to manage your per-user configuration similarly to NixOS' configuration.nix: https://nixos.wiki/wiki/Home_Manager
<symphorien>
the url if you are interested
tdbgamer has joined #nixos
<sphalerite>
,home-manager = home-manager allows you to manage your per-user configuration similarly to NixOS's configuration.nix: https://nixos.wiki/wiki/Home_Manager
<{^_^}>
home-manager redefined, was defined as home-manager allows you to manage your per-user configuration similarly to NixOS' configuration.nix: https://nixos.wiki/wiki/Home_Manager
<symphorien>
hum I would have expected an url to upstream, but, well, it works :)
o1lo01ol1o has quit [Ping timeout: 240 seconds]
neminis has quit [Quit: leaving]
<sphalerite>
feel free to change it to point to upstream ;)
_kwstas has joined #nixos
_kwstas has quit [Remote host closed the connection]
edcragg has quit [Remote host closed the connection]
_kwstas has joined #nixos
_kwstas has quit [Remote host closed the connection]
edcragg has joined #nixos
_kwstas has joined #nixos
_kwstas has quit [Remote host closed the connection]
<simpson>
Yes. A custom overlay is code, often in a repository, shareable. A custom channel is user-local configuration.
endformationage has joined #nixos
<slabity>
So you can't share custom channels?
<tilpner>
slabity: You can create your own channels, and share them with others
<simpson>
But sharing a channel is a matter of sharing instructions on how to establish some local configuration, whereas sharing an overlay is a matter of publishing code.
<simpson>
I shouldn't have implied that channels can't be shared. I suppose that we should back up: What do you want to share?
acarrico has quit [Ping timeout: 268 seconds]
rauno has quit [Remote host closed the connection]
simukis has joined #nixos
hydropyrum has joined #nixos
<infinisil>
sphalerite: ,home-manager was right previously I think, if a noun ends with "s", its possessive form is only an "'" added without an additional "s"
<attente[m]>
hi, how do you enable `luaSupport` for `weechat` in a home-manager configuration?
<tilpner>
It should default to true
<attente[m]>
tilpner: oh, you're right, sorry. i'm getting a different kind of error message
<sb0>
when adding a git checkout input to hydra, I want it to keep the .git folder - how to do that?
<attente[m]>
there's a particular plugin that i want to add as an override dependency to weechat though
<attente[m]>
because a lua script i want to use depends on it: lua cjson
<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>
NUR looks like it uses packageoverrides. Not a channel or overlay.
<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>
Unless that would be useful contribution to nixpkgs, but I'm not sure that is the best place for it
peacememories has joined #nixos
<simpson>
I think that some particular FLOSS software's upstreams do prefer Snaps or AppImages for some strange reason, and I wouldn't be surprised if nixpkgs maintainers would like to provide those as options.
<attente[m]>
how do you explicitly add a runtime dependency to a nix package derivation?
<simpson>
slabity: Note that `dockerTools.pullImage` is *already* in nixpkgs!
<simpson>
attente[m]: You can do something nasty like putting the dependency in PATH via wrapper.
<simpson>
,runtimedeps
<{^_^}>
simpson: Did you mean runtimeDeps?
<{^_^}>
In order of preference: Patch source OR ((if it uses PATH -> wrap with new $PATH) AND (if it uses dlopen, (patchelf --set-rpath in postFixup OR wrap with new LD_LIBRARY_PATH)))
<tilpner>
(And appimageTools will be in nixpkgs as soon someone can be found to press that merge button)
seku has quit [Remote host closed the connection]
<attente[m]>
simpson: can you recommend the cleanest way for me to do this? i'm trying to run weechat with a script, but the script requires lua cjson. but i don't know if it's appropriate to always run weechat in a nix-shell for this or if it's better to add lua cjson as a dependency to weechat, overridden by overlay
<simpson>
slabity: Hopefully, though, you have at least one specific package in mind.
<simpson>
attente[m]: Patch the source. sed that script.
<slabity>
simpson: Sort of? I'd like to try and package up some VMs first.
<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
acarrico has joined #nixos
Tucky has quit [Quit: WeeChat 2.2]
<slabity>
Hell I'd like to eventually make a Windows VM derivation for easy setup
<simpson>
Well, go for it, I guess. It'd be nice to see nixos-container be more useful, too. And yeah, surely this all can fit in nixpkgs; half of your desired tools are already there.
<ottidmes>
Guanin: glad to see you solved your issue, maybe naive from me, but could it be that Ubuntu has some extra udev rules responsible for this autodetect (is the GPU even handled by udev?)
seku has joined #nixos
nD5Xjz has joined #nixos
Ariakenom has quit [Ping timeout: 250 seconds]
<Guanin>
ottidmes, that might be a pretty good explanation - I'll have a look into that :)
hyper_ch2 has quit [Quit: Page closed]
Guanin has quit [Remote host closed the connection]
<Taneb>
There doesn't seem to be a NixOS option for jupyterhub?
<apaul1729>
weird question - are there any open-source conferences at which nix devs regularly give keynotes/plan for ongoing development? i'd like to get more involved in the community and check out some conferences
<Taneb>
apaul1729: the obvious one is NixCon
<apaul1729>
checked that out, seemed like it had a pretty small maximum of people. wondering if there were any others
<Church->
Could always do a video conference
<Church->
The amount of nix people ain't that high
<Church->
Some decent software for large scale conferencing these days
o1lo01ol_ has quit [Remote host closed the connection]
<goibhniu>
hi apaul1729: there are some active groups too, where are you based?
<{^_^}>
[nixpkgs] @aanderse opened pull request #55453 → cron: fix error when running crontab as sudo (issue #54827) → https://git.io/fhHBw
o1lo01ol1o has joined #nixos
marsam has joined #nixos
freedan42x has joined #nixos
<freedan42x>
has someone moved from NixOS to Windows?
<cswl>
How do I upgrade nix itself.. using multi user systemd :3
Ariakenom has joined #nixos
erictapen has quit [Ping timeout: 250 seconds]
<symphorien>
cat you paste the content of systemctl cat nix-daemon ?
<apaul1729>
goibhniu i'm in northeast america
lopsided98 has quit [Quit: Disconnected]
<{^_^}>
[nixpkgs] @alyssais merged pull request #55453 → cron: fix error when running crontab as sudo (issue #54827) → https://git.io/fhHBw
<slabity>
I have a simple derivation; `{ pkgs }: pkgs.buildFHSUserEnv { name = "newenv"; }`
<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?
civodul has quit [Quit: ERC (IRC client for Emacs 26.1)]
rcshm has quit [Ping timeout: 250 seconds]
lopsided98 has joined #nixos
maximiliantagher has joined #nixos
maximiliantagher has quit [Remote host closed the connection]
ryantrinkle has joined #nixos
seku has quit [Remote host closed the connection]
shibboleth has quit [Quit: shibboleth]
gagbo has joined #nixos
<{^_^}>
[nixpkgs] @alyssais pushed commit from @aanderse to release-18.09 « cron: fix error when running crontab as sudo (issue #54827) »: https://git.io/fhHRs
makefu has joined #nixos
<slabity>
`nix build '({ pkgs ? import <nixpkgs> { } }: pkgs.buildFHSUserEnv { name = "newenv"; })' && ./result/bin/newenv` does not drop me in an FHS chroot
maximiliantagher has joined #nixos
pointfourone has quit [Quit: Leaving]
<slabity>
It just ends up running bash in whichever directory I'm in
justan0theruser is now known as justanotheruser
ddellacosta has joined #nixos
pointfourone has joined #nixos
freedan42x has quit [Ping timeout: 240 seconds]
reinhardt has joined #nixos
reinhardt has quit [Client Quit]
johnw has joined #nixos
maximiliantagher has quit [Ping timeout: 268 seconds]
__monty__ has quit [Quit: leaving]
ddellacosta has quit [Ping timeout: 268 seconds]
johnw_ has quit [Ping timeout: 252 seconds]
ddellacosta has joined #nixos
halfbit has joined #nixos
simukis has joined #nixos
simukis has quit [Remote host closed the connection]
<jluttine>
Is it possible to define environment variables for a package derivation in such a way that when the package is "installed", the environment variables are set? I'd like to create a derivation for one Python package so that whenever it is "installed", one env var is defined so that `os.environ["FOO"]` will give "bar" in Python. Is this possible?
dermetfan has joined #nixos
<symphorien>
Wrap the executables, or patch the source to hardcode "bar"
<jluttine>
they're python packages, not executables.. i wouldn't want to wrap Python..
<symphorien>
Then patch the source
<jluttine>
source of what..? i don't quite understand.. what source do i need to patch so that the env vars would be defined in python repl.. :/
pointfourone has left #nixos ["Leaving"]
<apaul1729>
patch the source code of the python module
devalot has joined #nixos
<apaul1729>
possibly just define that variable in the __init__.py (?) of the module before you `python setup.py install` it or whatever
<symphorien>
Replace all occurences of os.environ["foo"] by "bar"
<jluttine>
symphorien: ok. gotta see if it doesn't cause too huge patches for a large number of packages that assume the existence of the environment variable
<jluttine>
but probably that'd be the best solution
<jluttine>
thanks
<srhb>
jluttine: The alternative answer is "no, it's not possible" at least. :) Packages don't have that kind of power.
<jluttine>
srhb: yep, that's what i thought. thanks for confirming!
<tg>
getting kernel panic when using the minimal install cd shortly after starting systemd-udevd.. any idea what boot options to try other than nomodeset that's in the boot menu and didn't help?
orivej has quit [Ping timeout: 250 seconds]
<symphorien>
Does it complain about not finding / ?
<tg>
nope
sigmundv has quit [Ping timeout: 246 seconds]
<tg>
panic mentions 'handle_mm_fault' and 'do_syscall_64'
<tg>
this was with 18.09 but also with 18.03 is the same result
<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.
<symphorien>
tg: iirc there is also an iso with the most recent kernel, you could try it
silver_hook has quit [Quit: ZNC 1.6.5+deb1+deb9u1 - http://znc.in]
<samueldr>
the current iso, unstable included, are built with the 4.14 LTS
<samueldr>
while new_kernel AFAIK should be built with 4.20 right now
<samueldr>
looks like it is 4.19
<goibhniu>
apaul1729: FWIW, I know there are a few NixOS people around New York, but I'm not aware of a regular meetup. It's not really what you were asking about anyway.
<{^_^}>
[nixpkgs] @veprbl opened pull request #55455 → pythonPackages.pyslurm: remove version check → https://git.io/fhHR5
<srhb>
ghostyy: Ah, each stable version is a dead end branch.
<srhb>
ghostyy: It stops receiving updates (mostly) once the new stable channel is released.
<symphorien>
ghostyy: are you on a single-user install ?
<ghostyy>
ahhh, i see
<ghostyy>
symphorien, i'
<srhb>
ghostyy: If you see nix-channel --list, you'll see it's referencing 18.03 directly
<matthewbauer[m]>
I do think we should try to support older NixOS versions as much as possible. Lots of users aren't going to be so quick to update.
<ghostyy>
m not sure what that means exactly, i have a nixos desktop and a nixos server
<matthewbauer[m]>
Maybe we need a nixos-stable channel?
<matthewbauer[m]>
Someone requested that a while back
<symphorien>
ah ok never mind then
<srhb>
matthewbauer[m]: I'd be wary of splitting our resources like that currently.
<srhb>
matthewbauer[m]: But yes, it's obviously desirable for many people.
<ghostyy>
installing from the unstable channel worked great, thank you
<ghostyy>
ill try to update nixos proper at some point
<gchristensen>
matthewbauer[m]: we do support them a bit longer now, but it is hard hard work.
<gchristensen>
matthewbauer[m]: nixos-stable is interesting, but could cause problems with not reading release notes :/
Judson has joined #nixos
<ghostyy>
im more used to eg arch with rolling releases
<srhb>
matthewbauer[m]: gchristensen By "nixos-stable" you mean a rolling release stable?
Judson is now known as Guest52244
<hodapp>
Arch is what got me to NixOS :|
<symphorien>
nixos-unstable is a rolling release
<tilpner>
You can run your system from nixos-unstable, it's only sometimes annoying
<matthewbauer[m]>
Yeah you can do rolling releases with the nixos-unstable channel
<symphorien>
but it is unstable :)
<gchristensen>
right
<ghostyy>
tilpner, have you experienced any significant problems doing that?
<samueldr>
here unstable is more often related to "might upgrade your things whenever" than "might eat your lunch"
<samueldr>
but still sometimes eyes your lunch
<srhb>
Eh, I've had lunch-eating happen on unstable for sure.
<gchristensen>
one thing we talked about was adding warnings to a channel after it is no longer supported
<srhb>
Willingly and happily.
* tilpner
switches back to stable every once in a while, only to then need things from unstable and be stuck on it
<srhb>
tilpner: You should try running on master for the True Experience. :-P
<gchristensen>
nononono
<srhb>
(Indeed, no) :P
<tilpner>
I do want to switch to auto-upgrades to throttled master at some point
Guanin has quit [Remote host closed the connection]
<gchristensen>
eh?
<tilpner>
But throttled via a server that runs only the tests I care about, and checks if only the packages I care about are cached
<tilpner>
So still faster than perpetually stuck unstable, while not quite as laundry-eating as actual master
<srhb>
We should make a hydra endpoint that is master at the last point tests foo,bar,baz and quux (used defined) succeeded.
yayforj has quit [Ping timeout: 246 seconds]
<srhb>
Personalized channels!
<tilpner>
Yes, that's what I want
<ghostyy>
does hydra automatically run tests for packages it builds?
<tilpner>
Might become a support nightmare if everyone does it though
<srhb>
ghostyy: Yes.
<slabity>
Is anyone familiar with how to use buildFHSUserEnv properly? It doesn't seem to be creating any type of isolated environment for me.
<ghostyy>
whoa thats really cool
agander has joined #nixos
<tilpner>
slabity: Yes, what's your question/error
<srhb>
ghostyy: The channel is bumped once certain tests set pass. You can read about it on http://howoldis.herokuapp.com -- the boxes at the top.
<tilpner>
ghostyy: Yes, sometimes it has problems. But whenever I'm on unstable I really need its features, so there's no alternative
<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
ng0 has joined #nixos
<ghostyy>
ahhh i see
<ghostyy>
i use stable with occasional unstable packages
<tilpner>
slabity: How are you trying to run that? That should error in multiple ways
<tilpner>
slabity: That works though, what did you expect?
<slabity>
tilpner: I expect to be dropped in an isolated chroot
<tilpner>
That's not what it does
<tilpner>
What isolation are you looking for, I might have something
silver_hook has joined #nixos
<tilpner>
(And API-compatible buildFHSUserEnv clone on bubblewrap that isolates /host away)
<slabity>
What does it do? The manual says it should create an isolated root environment.
<tilpner>
It builds an FHS-compliant tree, where binaries that don't about Nix can be ran in
<tilpner>
And then it uses namespaces to run a process in that tree
<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
<tilpner>
But it also puts your root filesystem in there, so you can't use it for containing anything
<tilpner>
Can you describe your end goal?
<samueldr>
tg: make sure to add linuxPackages_latest (or a specific one) when you install, otherwise it may not boot either since it will default to the same 4.14 LTS
<samueldr>
tg: (if you need more details ask)
npmccallum has quit [Quit: npmccallum]
<slabity>
tilpner: My endgoal is to create a bootstrapped environment that can be used as a base for other packages.
<slabity>
Bootstrap Debian into a derivation and use that as a base for installing debian packages for example
<symphorien>
slabity: there is runInLinuxVm or something like that
<symphorien>
it uses debian images iirc
<slabity>
I have a tarball that can be used to bootstrap Arch Linux for example. But it sounds like buildFHSUserEnv won't do that?
<tilpner>
Are you sure? I didn't think it does
<tilpner>
No, buildFUE is not what you want
maximiliantagher has joined #nixos
<tilpner>
symphorien was speaking of runInLinuxImage
<tilpner>
Look at build-support/vm for more
<yorick>
colemickens: it seems that wmfocus isn't actually a wayland thing
knupfer has joined #nixos
<slabity>
I don't want a virtual machine. More of a container
<slabity>
It looks like build-support/vm is all kvm stuff
<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
Edes has joined #nixos
clr_ has quit [Remote host closed the connection]
asymmetric has quit [Ping timeout: 240 seconds]
<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
sheyll has joined #nixos
<Edes>
Is there any way to run nixos-rebuild switch while offline or do it on another computer which has the disk mounted? The computer with no internet is a raspberry pi so there's the caveat that I can't chroot into it, at least in an obvious way.
<clever>
Edes: ive chroot'd into an rpi before
o1lo01ol1o has quit [Remote host closed the connection]
<clever>
Edes: git clone this, then add /path/to/nixos-configs/qemu.nix to your imports list on an x86 nixos host
<Edes>
I forgot about that
<clever>
Edes: that will magically allow you to run arm binaries on an x86 kernel, without having to emulate an entire arm system
<clever>
then....
mojjo has quit [Ping timeout: 264 seconds]
<Edes>
I install the wifi drivers on it I guess
<Edes>
that makes sense
<clever>
you need a special command to build it for arm
<Edes>
ok
<clever>
finding it...
<clever>
2019-01-31 15:45:04< clever> NIX_REMOTE=local?root=/mnt/img/ nix-env --profile /mnt/img/nix/var/nix/profiles/system --set -f '<nixpkgs/nixos>' -A system -I nixos-config=/mnt/img/etc/nixos/configuration.nix --option system aarch64-linux
[Leary] has quit [Remote host closed the connection]
<sheyll>
what could be the reason why neither /etc/resolve.conf, nor /etc/resolvconf.conf gets updates by /etc/nixos/configuration.nix by any of the networking.{dnsSingleRequest, extraResolvconfConf, resolvconfOption} options?
<clever>
Edes: this will act on the FS mounted to /mnt/img/, update the system profile, to the result of building configuration.nix, for aarch64-linux (you may want to change it to armv6 or v7, depending on your OS
maximiliantagher has quit [Ping timeout: 250 seconds]
<clever>
Edes: then, after booting the rpi again from that, you can just run `/nix/store/foo/bin/switch-to-configuration switch`, on the storepath it created
freeman42x has joined #nixos
<Edes>
I'll try it out, thanks
mojjo has joined #nixos
Lears has joined #nixos
<tilpner>
How do I install file-rename so that it overrides the util-linux rename, without imperative configuration?
<mojjo>
I'm not sure if this reached the channel (as the other client closed the connection), so I post it again:
<mojjo>
hi! I'm trying to patch a binary to make it work with nixos. Concretely it's this util: https://github.com/stoeffel/elmi-to-json . It's a binary compiled from Haskell and then distributed via NPM (yes that's possible). So usually you'd "just" `npm install elmi-to-json` and then run `node_modules/elmi-to-json/unpacked_bin/elmi-to-json` (or the shortcut `npx elmi-to-json`) from your npm project. However, this gives me "No such file or d
<symphorien>
tilpner: there is a function overrideMeta to change meta.priority
<mojjo>
en NixOS tries to run an unclean binary. I guess there'd be some `patchelf` magic envolved.. But I dont't know where to start. Does someone have some hints for me?
<mojjo>
* by unclean I mean that it probably points to some absolute paths which are usually present on linux systems but not on NixOs
<mojjo>
:)
<tilpner>
symphorien: I tried setting meta.priority on the buildEnv, but that didn't help
<symphorien>
not on the buildenv, on utillinux or file-rename, at your option
<clever>
either mkBefore, or mkAfter, will put your custom thing at a higher priority, and overwrite util-linux's
<tilpner>
clever: mkBefore on util-linux or file-rename?
<clever>
tilpner: file-rename
<clever>
you want to force it to come before the util-linux your not altering
<tilpner>
That's what I figured, but there also was the "mkBefore a remove-but-not-globally-overlayed util-linux" interpretation
<NemesisD>
infinisil: hello
<tilpner>
(Removing rename)
<infinisil>
NemesisD: Hello there
<clever>
tilpner: if you override util-linux, it can mass-rebuild, because a lot of things use those utils at build time
<infinisil>
NemesisD: Maybe repeat your question for everybody here
o1lo01ol1o has quit [Remote host closed the connection]
<tilpner>
clever: I know, but you could install an overridden-but-not-overlayed util-linux
<clever>
tilpner: then you have 2 util, and one still gives rename
o1lo01ol1o has joined #nixos
o1lo01ol1o has quit [Read error: Connection reset by peer]
o1lo01ol1o has joined #nixos
<clever>
adding a second util-linux to systemPackages will just install both sets of files, and ignore collisions
<NemesisD>
well let me back up. at work we've used stack for some time on haskell projects and its worked well. the problem is we have devs that use different OSes, builds that have non-haskell dependencies. the least disruptive approach seems go partway into nix: use nix-shell to load dependencies, stack inside of there to build the project.
<tilpner>
Huh, that still doesn't work
<clever>
tilpner: try mkAfter instead?
<tilpner>
Nope
<NemesisD>
it seems like using nix itself to build haskell dependencies kind of sucks because it rebuilds unnecessarily and by default runs dependency tests. our builds take long enough as is
<tilpner>
The pragmatic thing would be to rename the "rename" executable
<infinisil>
NemesisD: Yeah, I can't recommend only stack with nix because of that
<tilpner>
But now I'm curious if this is possible
<NemesisD>
infinisil: also, i've hit a blocking bug on every one of projects and even on your soph project where running stack inside of a nix-shell fails to compile optparse-applicative with: librt.so: symbol __close_nocancel, version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
<infinisil>
NemesisD: Huh, checking it out..
<NemesisD>
infinisil: i get it by running nix-shell and then running stack build inside (or stack build optparse-applicative-0.14.3.0 to save you some time)
<symphorien>
what version of glibc is your system using ?
abaiste^ has quit []
<infinisil>
NemesisD: Works for me, try clearing (or moving) ~/.stack
<infinisil>
Ah
<infinisil>
symphorien: How can one check that?
<NemesisD>
i've done that dozens of times today :(
<symphorien>
and what version of glibc do nix executable use ? (run ldd on any of them, you will see)
<symphorien>
infinisil: I guess it is distro specific
<NemesisD>
it kind of seems like a bad idea for stack to get installed in ~/.stack when you're trying to have an isolated env for the project
<NemesisD>
it also sort of seems like a bad idea to me to use nix-shell without --pure if you're trying to have reproducible builds
<infinisil>
NemesisD: Yeah, that's why I prefer Nix to handle the dependencies and compile with cabal (then you still have project local caches, but those aren't as bad)g
hph^ has joined #nixos
<infinisil>
I guess cabal new-build has a cache in ~/.cabal, but those caches are as reproducible and pure as Nix, so that shouldn't be a problem
<NemesisD>
infinisil: looks like on debian you can do `sudo apt show libc6`, symphorien: i'm on 2.24-11+deb9u3
<infinisil>
NemesisD: Ah, I'm on 2.27, and the nixpkgs version used in soph is also quite recent
yayforj has joined #nixos
<symphorien>
so the thing is: nix libs are built with 2.27
<NemesisD>
infinisil: when you say nix to handle the dependencies, you mean only the system dependencies right? any system libraries + cabal itself? you're not using nix to request haskell packages
<NemesisD>
yikes
<infinisil>
NemesisD: Yes I am
<symphorien>
so if you use nix libs, you must *only* use nix libs which come with the latest glibc
<infinisil>
Nix handles all haskell and system dependencies, everything really
<NemesisD>
is dynamic linking a punishment for our sins?
<NemesisD>
symphorien: i don't really understand. shouldn't i be able to set up a project environment such that it doesn't depend on my system's older libc? i thought that was the point
<symphorien>
I don't know how stack works
<symphorien>
but if stack uses the system linker, you will end up depending on the system gcc
<symphorien>
and nix-provided libs will complain of the old glibc
<symphorien>
so the question is: how do I tell stack to no use system libs at all
<symphorien>
and here I let stack users answer this question :þ
<NemesisD>
symphorien: i'm kind of out of my depth on linker things, but i wonder if there's a way to vendor a nix-supplied linker such that when stack reaches out for the linker, it gets a nix one and not a system one
* tilpner
can't manage to install file-rename, goes back to zmv
<infinisil>
NemesisD: Are you using the nix stack?
<infinisil>
Like, stack installed with Nix?
<NemesisD>
infinisil: i've tried that, yeah, right now i'm booted into a `nix-shell --pure` in my project which has a build input that includes haskellPackages.stack, and i confirm that `which stack` points to a nix location
Thra11 has joined #nixos
<symphorien>
NemesisD: do you have nix: true in your stack.yaml ?
_kwstas has joined #nixos
_kwstas has quit [Remote host closed the connection]
<NemesisD>
infinisil: i also can try to trick stack into not breaking out of the dir to install ghc by in my nix expression setting STACK_ROOT to "${builtins.getEnv "PWD"}/.stack"
<NemesisD>
symphorien: i've tried with and without. the problem with it enabled is that you can't seem to run stack from within a nix-shell if you enable it. it seems like enabling nix in stack makes it so that you call stack *not* in a nix shell and it internally sets up a pure nix shell for its own use
agander has quit [Read error: Connection reset by peer]
<NemesisD>
which is fine if you're trying to hide the fact that you're using nix, but not if you're gonna need nix for other dependencies. so when you try to run with nix enabled inside of a nix-shell, it tries to start *another* nix shell
<infinisil>
NemesisD: Yeah that's indeed the case
<symphorien>
also, are you using a ghc which was built before your nix experiments ?
o1lo01ol1o has quit [Remote host closed the connection]
yayforj has quit [Ping timeout: 245 seconds]
hph^ has quit []
o1lo01ol1o has joined #nixos
<infinisil>
NemesisD: You can add additional packages with `nix: packages: [ zlib openssl ... ]`
<NemesisD>
it seems to be installing the ghc locally to .stack (which i've redirected to be in this project's dir to try avoid cross-project poisoning)
<symphorien>
if you run ldd on this ghc, does it have debian deps of nix deps ?
<NemesisD>
infinisil: but how can i boot into the nix shell that stack is using to build? i'm going to have shell scripts that call typescript compilers and things like that. i'd have to do that all through stack exec i guess? it seems bad
Guest63655 has joined #nixos
<infinisil>
NemesisD: Hmm.. yeah, I'm not a big fan of the stack integration myself, this seems a bit problematic
<infinisil>
NemesisD: How about just not using stack, might be more trouble than it's worth
<infinisil>
Ah, but I guess you have the non-nix devs in your team
<infinisil>
I honestly don't even know how you'd use cabal without nix installing the dependencies xD
<NemesisD>
i could convince them if i come up with something workable or have it be a per-project thing
<infinisil>
NemesisD: Well nix-shell + cabal is flawless
orivej has joined #nixos
<infinisil>
(okay everything has flaws, but that's a very solid and tested option)
<NemesisD>
infinisil: here's my problem though. i see stack giving me 2 things: 1) reliable setup of different ghc versions for projects. easy to replace with nix 2) stackage's versioned resolver which give me a base set of versions that are all compatible with eachother. when we were using cabal years ago i'd lose hours and hours trying to get a large project's dependency graph to a solution. i cannot go back to that
<infinisil>
NemesisD: Ah that's no problem with Nix
<infinisil>
NemesisD: nixpkgs uses stack's versions for haskell packages
<infinisil>
Always the more or less latest lts set
<NemesisD>
there's minor gripes with cabal, it seems to have a really imperative API where i have to tell it to set up sandboxing, configure, etc. i do like how you can just tell stack to build and it will figure out what to do. i don't know if that's improved since the bad old days
<NemesisD>
infinisil: some of my projects aren't compatible with the latest ltses. what's the equivalent of stack.yaml's resolver: lts-whatever
<infinisil>
NemesisD: cabal new-build has you covered with that
<infinisil>
NemesisD: Pinning nixpkgs to a specific version, can be as old as you want
Thra11 has quit [Ping timeout: 246 seconds]
<infinisil>
There could be a convenience script to get a nixpkgs commit for an lts version too
<NemesisD>
infinisil: interesting. ok, so where does nix's responsibilities leave off and cabal's begin? when you're building with cabal, how is it finding all these packages that nix got for you?
maximiliantagher has joined #nixos
fusion809 has quit [Remote host closed the connection]
<infinisil>
NemesisD: That's a good question. I think the dependencies are known to the `ghc` binary directly, but also cabal would need to know about them somehow, not sure how that works
<infinisil>
Could check how it's implemented in nixpkgs
<infinisil>
I think cabal probably just calls back into ghc as well
<dmj`>
error: 'mkOption' at /home/travis/.nix-defexpr/channels/nixpkgs/lib/options.nix:30:5 called with unexpected argument 'options', at /nix/store/wx002fsyr868x5lwh9zh86hky5y8nc90-nixops-1.6.1pre2706_d5ad09c/share/nix/nixops/gce.nix:382:19
<infinisil>
NemesisD: There is even a function `pkgs.haskellPackages.ghcWithPackages (p: [ p.aeson ])` you can use to get a ghc with specific packages available, you'd have to check how this function is implemented
<NemesisD>
i've got a small-ish project i'm willing to try de-stackifying that seems to span a lot of the problems that stack solves well so this will be a good test. its got a somewhat deep dependency graph, its got submoduled, non-nixified, unpublished package dependencies that i need to tell nix about
<tilpner>
That's how you fix it, if you used that argument, dmj
<dmj`>
tilpner: I still don't get what is the actual error
<tilpner>
dmj`: Are you not passing "options" to mkOption?
<infinisil>
NemesisD: Cool, wanna try yourself first? I can help if you are stuck or need guidance
_kwstas has quit [Remote host closed the connection]
<dmj`>
tilpner: let me check my modules
<NemesisD>
infinisil: i'm definitely going to need guidance if you don't mind :) but yeah i've got the project open now and i'm going to give it a go. should we do this over private message or just in here? i don't want to flood
<dmj`>
tilpner: the weird part is that this is not a problem for my my local machines, and we're all pinned to the same nixpkgs version
<tilpner>
dmj`: Ahh, your nixops doesn't include nixops#1088
<dmj`>
tilpner: but the nixops is pinned though :/
<tilpner>
dmj`: But no on Travis, it seems
<tilpner>
*not
<clever>
dmj`: nixpkgs isnt
<clever>
dmj`: your nixpkgs is too new
<dmj`>
clever: I've pinned to a newer nixpkgs yes, but that nixpkgs has a nixops that works locally, but not on travis
<infinisil>
NemesisD: Hmm, I don't mind it being here, there's no more appropriate channel, we just gotta ping each other for replying
<clever>
dmj`: is the pinned nixpkgs in NIX_PATH?
<infinisil>
NemesisD: (I'd rather not PM for troubleshooting)
<dmj`>
clever: I'm building a script with writeScriptBin, adding nixopsUnstable/bin/nixops to the export PATH in the script, and executing it
<dmj`>
clever: I've ssh'd into the travis machine, and can confirm no other nixops exists locally
<tilpner>
dmj`: Not nixops. nixpkgs is too new
<dmj`>
tilpner: nixops is in nixpkgs
<NemesisD>
infinisil: totally get it. okay, so the first thing: i've got a package.yaml which generates a cabal file. i see in soph you're using a function to convert a cabal file to a nix expression so you don't need to keep a release.nix or whatever. i'd like to see if there's a hpack equivalent. where do you go to browse the available functions like self.cabal2nix?
Ralith_ has quit [Read error: Connection reset by peer]
<clever>
dmj`: how did you pin nixpkgs?
<clever>
dmj`: can you gist that nix expression?
<dmj`>
clever: have a nixpkgs.json that I readFile on call fromJSON on, then call builtins.fetchTarball
<dmj`>
clever: sure one sec
knupfer has quit [Ping timeout: 264 seconds]
<clever>
2019-02-08 14:29:19 < DHE> the search thing is kinda important when your pool is made of 122 hard drives. :)
<clever>
2019-02-08 14:36:16 < malwar3hun73r> i have 2... lol
<clever>
oops, wrong button
<clever>
2019-02-08 14:38:10 < DHE> yeah, well, my company has a 1/2 petabyte (roughly) array... so there's that.
<clever>
dmj`: and do you update NIX_PATH?
<dmj`>
clever: not on travis
<infinisil>
NemesisD: You might wanna start with a default.nix like `with import <nixpkgs> {}; haskellPackages.callCabal2nix "foo" ./. {}`
<clever>
dmj`: thats your problem
<clever>
dmj`: nixops uses NIX_PATH to find nixpkgs
<clever>
dmj`: the nixpkgs its finding is too new
<dmj`>
clever: so the fix is to export NIX_PATH=${pkgs} in my script?
<NemesisD>
infinisil: backing up, i'd like to freeze to a particular set of packages like you did so the build is reproducible. i noticed though the last release on the nixpkgs github is from october 2018, 18.09
<dmj`>
before executing nixops deploy --include mybox
<NemesisD>
infinisil: is it a bad idea to just point to the current master's revision? and how do you like to get the SHA for that? just downloading the tarball and running sha256sum on it?
<infinisil>
NemesisD: Yeah, then something like `with import (fetchTarball { url = https://github.com/nixpkgs/NixOS/archive/<revision>.tar.gz; sha256 = "..."; }) {}; ...` can be used
<infinisil>
NemesisD: Yeah I wouldn't recommend master, maybe latest nixos-unstable
<clever>
,tofu NemesisD
<{^_^}>
NemesisD: To get a sha256 hash of a new source, you can use the Trust On First Use model: use probably-wrong hash (for example: 0000000000000000000000000000000000000000000000000000) then replace it with the correct hash Nix expected.
<dmj`>
clever: trying now, stay tuned
<NemesisD>
hehe nice
mobile_c has joined #nixos
<mobile_c>
how do i boot nixos
<infinisil>
NemesisD: master doesn't really hurt haskell packages though, so it probably doesn't matter
<clever>
NemesisD: i typically just pick whatever rev my system is currently on, and if it works, i stay on that
<mpickering>
Does anyone know the cause of "Could not find suitable distribution for Requirement.parse('pytest-runner')" when trying to build a python package?
<NemesisD>
clever: how do you find that out?
<mpickering>
the really weird thing is that the nixpkgs is pinned and it works on CI but not locally
<clever>
NemesisD: the part starting at 6141 is the git rev
<mobile_c>
as i get
<attente[m]>
has anyone managed to install firefox nightly using nixpkgs-mozilla?
<mobile_c>
mount: mointing /dev/root on /mnt-root/iso failed: No such file or directory
<mobile_c>
mounting*
<samueldr>
mobile_c: did you use unetbootin to burn the iso?
maximiliantagher has quit [Ping timeout: 268 seconds]
<clever>
mobile_c: how did you copy the iso file to the usb stick?
<samueldr>
(unetbootin cannot be used to burn the iso)
<samueldr>
(at least, not without care and preparation)
<dmj`>
clever: so what happened is that travis picked up a newer nixpkgs that broke my nixops invocation, despite the fact my nixops was pinned to use my pinned nixpkgs
<clever>
dmj`: nixops itself was pinned, but not nixpkgs
<dmj`>
clever: shouldn't a pinned nixops use a pinned nixpkgs, this means somewhere in nixops code it is looking at NIX_PATH
<clever>
dmj`: you simply failed to pin nixpkgs, and travis has likely been upgrading the machine randomly, every time the channel updated
<mobile_c>
menuentry "[loopback] $ISO_STYLISED_NAME ($ISO_FILE)" { set ISO_FILE=${ISO_DIRECTORY}nixos.iso loopback loop $ISO_PARTITION$ISO_FILE linux (loop)/boot/bzImage initrd (loop)/boot/initrd }
<clever>
dmj`: it might have even been using nixpkgs-unstable, which can brick nixos machines sometimes
<dmj`>
clever: oh my heavens
<samueldr>
mobile_c: the way the nixos iso is built will not work with most "multi boot" type of bootable usb frameworks
<clever>
dmj`: you must only use revs that the nixos channels have been pointing to
<samueldr>
mobile_c: (I'm assuming this is that kind of setup from the menuentry you shared)
<clever>
dmj`: check the channels.nix.gsc.io link the bot just posted, that shows the history for every channel
<mobile_c>
yes (i think?)
<mobile_c>
this is my grub.cfg
<sicklorkin>
I just added antoher disk to my machine to give more space to /nix on my multiuser system. I wasn't thinking and did sudo mv /nix.bak /nix and now I lost the premissions.. What are the correct permission for multi-user nix?
<clever>
mobile_c: the nix script will insert the right path as it builds the file
<mobile_c>
._.
<mobile_c>
is there an ISO file specifically pre-built for multi-boot USB support
<clever>
not that i know of
<mobile_c>
so i dont need to rebuild the ENTIRE iso file
ikitat has joined #nixos
<simpson>
mobile_c: How will you be using Nix once you're up and running? Do you want a persistent NixOS that you can reuse? Do you want Nix alongside your existing Linux/etc. on your root disk? Where do you want your /nix/store to live?
<clever>
mobile_c: do you not have a spare USB stick you can put the original nixos ISO on, as the only thing?
<mobile_c>
neon@neon-X555BA:/ISO_FILES/ISO$ ls /mnt/nix-store
<mobile_c>
ls: cannot access '/mnt/nix-store': No such file or directory
maximiliantagher has quit [Ping timeout: 246 seconds]
<mobile_c>
neon@neon-X555BA:/ISO_FILES/ISO$ ls /mnt/nix/
<mobile_c>
ls: cannot access '/mnt/nix/': No such file or directory
<clever>
the squashfs gets mounted to /nix/store/ by the initrd scripts
ddellacosta has quit [Ping timeout: 250 seconds]
<mobile_c>
ok
<mobile_c>
linux (loop)/boot/bzImage init=/niz/store/428vzpvqsfs3m4c5033y1sx1v4hqnvpk-nixos-system-nixos-17.09.1547.2231575a7d/init
<mobile_c>
would that be correct
<dmj`>
clever: is nixos-unstable as safe as nixos-18.09 lets say?
<mobile_c>
niz*
<mobile_c>
nix*
<dmj`>
clever: is 18.09 considered an old nixos-unstable
<clever>
mobile_c: maybe, but i suspect it to fail, because the initrd is expecting to find the squashfs on an iso9660 FS
<clever>
dmj`: 18.09 was forked off a version of master, on 2018-09, and then has had fixes cherry-picked into it to make it more stable
<mobile_c>
and would that be at /dev/root ?
<mobile_c>
also what exactly IS /dev/root
<clever>
mobile_c: /dev/root is a symlink, based on the root= param passed to the kernel
<gchristensen>
I have a python requirements.txt, what is The Way to get a shell for it?
Glider_IRC_ has joined #nixos
<mobile_c>
as in... for example... linux (loop)/boot/bzImage root=/blah ?
<clever>
yeah
<mdash>
gchristensen: 'pypi2nix -r requirements.txt -V2.7; nix-shell requirements.nix -A interpreter'
<dmj`>
clever: has nixos-unstable updating ever caused machines not to boot
<mobile_c>
and what paramater is normally passed to root
<gchristensen>
thanks, mdash!
<clever>
dmj`: thats what the tests on hydra prevent
<dmj`>
clever: right, has something ever gotten through? Would it be worth it to be on an even older version of nixos is what I'm asking
<clever>
dmj`: not that i'm aware of
<mobile_c>
like would it be something like root=/nix-store.squashfs
Glider_IRC__ has quit [Ping timeout: 246 seconds]
<clever>
mobile_c: it would be the uuid or label of the filesystem on the usb stick
<gchristensen>
mdash: what do I do if a dep doesn't provide a source (zip/tar.bz) distribution?
sheyll has quit [Ping timeout: 256 seconds]
<mobile_c>
so.... this?
<mobile_c>
set ISO_FILE=${ISO_DIRECTORY}nixos.iso
<mobile_c>
loopback loop $ISO_PARTITION$ISO_FILE
<mobile_c>
linux (loop)/boot/bzImage root=$ISO_FILE
<clever>
mobile_c: the nixos initrd doesnt understand that, so you need to copy the squashfs out of the iso, and then give it the label of your real fs
<mobile_c>
wish nixOS came with its own grub.cfg ;-;
<symphorien>
gchristensen: if it is packaged by debian/some other distribution, you can use their own mirror
<clever>
mobile_c: the file i linked earlier generates one
<mobile_c>
why doesnt it include one by default
<dmj`>
clever: thanks again
<gchristensen>
symphorien: not sure I understand
<simpson>
mobile_c: It seems very strange to want NixOS on a multiboot basis; most folks decide to convert entirely after a few weeks, and you're going through a lot of trouble for a very brittle bespoke setup.
<simpson>
mobile_c: The typical usage of NixOS boot media is to install NixOS. If one wants some other distro instead, then one typically uses single-user Nix with that distro.
<symphorien>
ah I had not seen it was related to python, sorry
<mobile_c>
what version of NIXOS does that guide aply to
rfold has quit [Quit: leaving]
<mobile_c>
apply*
<mobile_c>
as it obviously doesnt apply to the current version
mounty has quit [Ping timeout: 272 seconds]
<mobile_c>
as i only have r) and *)
justanotheruser has quit [Ping timeout: 244 seconds]
<clever>
mobile_c: you must add boot.allow_shell to the kernel cmdline
<NemesisD>
the FAQ tells you how to do it globally or in an environment variable. i'm following https://github.com/Infinisil/soph/blob/master/default.nix as a template but i'm not seeing where in there i could merge in the config
<mobile_c>
ok
<srhb>
NemesisD: import nixpkgs { config = { ...
<srhb>
NemesisD: That config is what we refer to as the "nixpkgs config"
<srhb>
NemesisD: Note that doing this will overwrite the settings in your environment.
<srhb>
NemesisD: (all of them, not just the ones you touch)
<NemesisD>
srhb: in that template it seems to be fetching a tarball of a specific nixpkgs and then defaulting it to nixpkgs
<srhb>
NemesisD: The { pkgs ? import nixpkgs ... } line is the one that calls nixpkgs (and thus creates pkgs)
<srhb>
NemesisD: Right now, the empty set is passed to that function -- {}
<srhb>
NemesisD: However, you can fill in attributes in that set, among others config, which will allow you to enable unfree.
<NemesisD>
i'm getting a syntax error from pkgs ? import nixpkgs { config = { allowUnfree = true }}
<srhb>
NemesisD: Needs more ; :)
<srhb>
NemesisD: Attributes are set like: { foo = bar; }
petrkr has joined #nixos
<NemesisD>
oh!
zupo has quit [Read error: Connection reset by peer]
_kwstas has joined #nixos
_kwstas has quit [Remote host closed the connection]
<clever>
sicklorkin: basically, you just add ./rescue-boot.nix to your imports section, nixos-rebuild (and pray you have ~300mb free on /boot/), and then you can run the installer from grub at any time
<clever>
sicklorkin: after that, its just a matter of pre-doing `nixos-rebuild boot` with new cfg that expects /nix to have been moved, then rebooting, and moving it
<{^_^}>
[nixpkgs] @aanderse opened pull request #55460 → nixos/php: init new php module for command line usage → https://git.io/fhHzX
<symphorien>
In this very case, having busybox somewhere seems enough
o1lo01ol1o has quit [Remote host closed the connection]
o1lo01ol1o has joined #nixos
<sicklorkin>
clever: pre-doing `nixos-rebuild boot` what is pre-doing?
<sicklorkin>
type?
<clever>
sicklorkin: adjust your configuration.nix so it expects /nix to be at the new place, and nixos-rebuild boot, so it doesnt break after you move it
monotux has joined #nixos
<dmj`>
tilpner: did these nixops changes affect mkEnableOption
<tilpner>
I don't know of any nixops changes
<tilpner>
(And I don't know if the nixpkgs change affected mkEnableOption)
<dmj`>
tilpner: the one you recommended me, 1088, which is HEAD of nixops right now
<{^_^}>
[nixpkgs] @jabranham opened pull request #55462 → Update R package set → https://git.io/fhHzb
<tilpner>
That's just a fix for the nixpkgs change
o1lo01ol1o has quit [Remote host closed the connection]
<dmj`>
tilpner: overriding it at the latest hash
<dmj`>
tilpner: I wasn't using it, ugh
<dmj`>
tilpner: my bad
hamishmack has joined #nixos
<NemesisD>
infinisil: i'm progressing along pretty well but i hit another snag: i need to add a local package in a subdirectory (i've vendored the gogol package with a submodule), but it doesn't seem to understand the directory structure
erasmas has quit [Quit: leaving]
o1lo01ol1o has joined #nixos
<NemesisD>
gogol-core = (self.callCabal2nix "gogol-core" "${builtins.getEnv "PWD"}/deps/gogol/core" {}); results in "do not know how to unpack source archive /home/michael/src/soostone/napkin-container/deps/gogol/core"
<clever>
paths like that, are relative to the file the path is within
balsoft has joined #nixos
<clever>
i think the problem, is that you gave it a string with no context
<clever>
so nix didnt copy the path into the sandbox
<clever>
and then the path just doesnt exist at build time
<NemesisD>
clever: i thought i couldn't do relative paths because i initially used double quotes and cabal2nix complained about not accepting relative paths. so if i don't double quote the path, nix expands it?
<clever>
quoting paths disables all of the magic that makes them work
<clever>
> "${ ./. }"
<{^_^}>
access to path '/var/lib/nixbot/state/nixpkgs' is forbidden in restricted mode
<clever>
ah, but the bot has too many safeties
knupfer has joined #nixos
<clever>
NemesisD: open up `nix repl` and then try to evaluate: "${./deps/gogol/core}"
<clever>
including the outer quotes
<NemesisD>
clever: ohh i see. it gives me a reference to the store
<NemesisD>
what if i had to interpolate part of the path?
<clever>
./deps + "/gogol/core"
<clever>
unquoted paths are a special type, and it will copy the smallest subtree it can, when you treat it as a string
<clever>
"${./deps}/gogol/core" will copy all of deps
mobile_c has joined #nixos
<clever>
"${./deps | "/gogol/core"}" will copy just core
<clever>
if that | was a +
<clever>
but those outer quotes are just to force it to copy, for demo purposes
<clever>
in general, i try to keep it as a path type as long as possible, so just (./deps + "/gogol/core")
<NemesisD>
clever: the path type is the unquoted part right? so if i could get away with it, (./deps/gogol + "core") would be preferable to (./deps + "/gogol/core"), or the other way around?
<rodarmor>
Is there a nix builtin that will return some random bytes? A service I'm running needs an API token stored in a file, and I'd like to generate it when rebuilding my system. Ideally I could use `environment.etc` to put it somewhere in etc, with permissions that I specify.
<clever>
NemesisD: when you use + to combine a path and a string, the new value is also a path
<mobile_c>
it wont boot ;-;
<clever>
NemesisD: also, (./deps/gogol + "core") is identical to ./deps/gogolcore, you need a / inside the string
<mobile_c>
even after i manually mount the squashfs to /mnt-root/iso/.ro.nix-store it just kernel panics
<clever>
mobile_c: did you try copying the squashfs to the main fs, like i said?
<infinisil>
rodarmor: You can use `builtins.currentTime` for that
<infinisil>
> builtins.currentTime
<{^_^}>
1549663300
<infinisil>
> builtins.currentTime
<{^_^}>
1549663304
<mobile_c>
no
<clever>
mobile_c: try doing that
<rodarmor>
@infinisil Sweet, that works :)
<rodarmor>
@infinisil Thank you!
<infinisil>
rodarmor: But are you really sure you need that? impurities aren't really something you usually want
<gchristensen>
currentTime will cause two evaluations to never produce the same result
<gchristensen>
currentTime is also not an adequate source of random bytes
<infinisil>
gchristensen: Unless you're fast enough
<rodarmor>
@infinisil Actually, yeah, it's not very random, someone could guess it.
<infinisil>
It's only second-resolution
kvda has joined #nixos
<infinisil>
Ah, I just thought you'd need something that keeps changing
<infinisil>
rodarmor: Wait can you be a bit more specific on why you need this?
<clever>
rodarmor: you could use something like pkgs.runCommand, and just hexdump /dev/random
<mobile_c>
i just did (in short) mount /dev/sda3 /sda2 ; chroot sda2 ... mount sda6 /ISO_FILES ; exit ... mount /sda2/ISO_FILES/ISO/nixos.iso /ISO ; mount /ISO/nix-store.squashfs /mnt-root//nix/.ro-store
<NemesisD>
infinisil: i'm moving along, i think i have the project building my submoduled packages. but now derive has a compile error. its trying to install 2.6.4, so i'm trying to use 2.6.5: derive = self.callHackage "derive" "2.6.5" {};
<clever>
rodarmor: but if it needs to be constant for the life of the machine, just ask the user to fill it in on the config, or things will randomly "break"
<infinisil>
rodarmor: I don't wanna suggest something like clever just did without knowing whether there's a better solution to your actual problem
<infinisil>
Yeah what clever just said sounds much more reasonable :P
<NemesisD>
infinisil: but it errors out with: tar: */derive/2.6.5/derive.json: Not found in archive \n tar: */derive/2.6.5/derive.cabal: Not found in archive
<clever>
NemesisD: 2.6.5 isnt in the all-cabal-hashes.tar.gz file
<buckley310>
I have a multi-user Nix install on centos. the original version of nix is "2.2.1", however when i run "nix-env -i nix", it installs version "2.2". is this expected? why the downgrade?
<clever>
NemesisD: so you must run cabal2nix on it manually, and load the result with callPackage
<rodarmor>
A service I'm running exposes an API, and its config takes a path to a file containing a secret, and it requires access to the API to auth using that secret. So I'd like to put it somewhere on my system where it's accessible to both the service and the consumers of the API
<infinisil>
clever: NemesisD: Hold on, you don't need to do what clever just said
<symphorien>
buckley310: because you installed the latest version and <nixpkgs> does not contain it yet
<NemesisD>
clever: weird, the package was uploaded jan 22nd
<rodarmor>
My configuration.nix can't contain secrets, unfortunately
<clever>
NemesisD: nix-build '<nixpkgs>' -A all-cabal-hashes -o all-cabal-hashes.tar.gz && tar -tvf all-cabal-hashes.tar.gz | grep derive
<{^_^}>
#52848 (by mightybyte, 6 weeks ago, merged): Add a callHackage variant that doesn't require all-cabal-hashes
<clever>
NemesisD: only goes up to 2.6.4 on my nixpkgs, what about yours?
<buckley310>
symphorien, okay. i thought i was clever and found a shortcut lol :) so just updating the channels and "-iA nixpkgs.nix" is the correct way to keep up-to-date going forward?
<clever>
infinisil: oh, nice, thats perfect
<symphorien>
yes
<buckley310>
awesome, thanks. guess its just a quirk of the installer script
<clever>
rodarmor: you could have a preStart script on its systemd unit, that will generate the random token, if it doesnt exist yet
<symphorien>
the installer is independent of <nixpkgs>, and somewhat more bleeding edge
<rodarmor>
@clever That sounds like a good idea
<buckley310>
<3 bleeding edge
<clever>
rodarmor: that also lets you fully control who can read the secret, by just using chmod and chown correctly
<clever>
rodarmor: anything done with a derivation becomes world-readable, since all of /nix/store can be read
<NemesisD>
clever: i don't know if i can do that. i pinned to fetchTarball with a commit as of a few hours ago, 0879595c607b66a990693972a55a27fa54eccd79 infinisil: which is why i'm confused that it can't find self.callHackageDirect
<rodarmor>
@clever Which user does the prestart command run under?
_kwstas has quit [Quit: _kwstas]
<clever>
rodarmor: normally, the User= you specified in your unit
mmlb3 has joined #nixos
<ikitat>
I'm stuck trying to work out how to overlay add a new python package (not yet in nix) and add it as a new dependency in an existing python application (in nixpkgs but currently 6 versions behind)
<clever>
rodarmor: but there is an extra flag to make prestart run as root instead
Thra11 has quit [Quit: WeeChat 1.9.1]
_kwstas has joined #nixos
<ikitat>
Adding the package seemed to work, but unsure about how to reference it in the propagatedBuildInputs of the application
<NemesisD>
infinisil: nevermind, looks like it found the function, but im using it wrong.. these type errors are not terribly helpful "value is a string while a set was expected"
mmlb has quit [Ping timeout: 246 seconds]
<clever>
rodarmor: PermissionsStartOnly makes the User= only apply to ExecStart, so pre-start runs as root
<clever>
rodarmor: `man systemd.service` for more info on it
<NemesisD>
hmm, callHackageDirect = {pkg, ver, sha256}@args: is a function that takes 1 arg with a set with keys pkg, ver, and sha256, right?
<clever>
NemesisD: yeah
<clever>
,tofu
<{^_^}>
To get a sha256 hash of a new source, you can use the Trust On First Use model: use probably-wrong hash (for example: 0000000000000000000000000000000000000000000000000000) then replace it with the correct hash Nix expected.
<clever>
NemesisD: so i would start with super.callHackageDirect { pkg = "derive"; ver = "2.6.5"; sha256 = "0000000000000000000000000000000000000000000000000000"; };
<clever>
the error will then tell you the right hash
<clever>
and i think it may also need another {} at the end, like all callpackage based things
<ikitat>
hm... just realizing that I likely need to do this in a 2nd overlay
<{^_^}>
[nixpkgs] @matthewbauer pushed 2 commits to master: https://git.io/fhHgQ
sheyll has joined #nixos
<musicmatze>
Is there a Mastodon nixos service?
<{^_^}>
[nixpkgs] @matthewbauer pushed 4 commits to master: https://git.io/fhHg5
<{^_^}>
[nixpkgs] @matthewbauer merged pull request #55324 → crawl: A few improvements → https://git.io/fh92y
maximiliantagher has quit [Ping timeout: 272 seconds]
ryantrinkle has quit [Ping timeout: 246 seconds]
<NemesisD>
how difficult is it to statically link haskell binaries with nix?
<NemesisD>
i see you can build docker containers with haskell executables but it seems like it'd also have to ensure that the system libraries matched up with those used in the build or it wouldn't run
<mikky>
hi, I'm trying to get grml-zsh-config to work but I'm not sure what to do - the ${pkg}/etc/zsh/zshrc just isn't linked to /etc and if I try to include it via programs.zsh.interactiveShellInit, I get a permission denied since (probably) he file isn't +x
<{^_^}>
[nixpkgs] @matthewbauer pushed 2 commits to master: https://git.io/fhH22
<NemesisD>
symphorien: oh. i guess some of the functions i'm using take a final attr set argument and delegate it then? (self.callHackageDirect {pkg = "derive"; ver = "2.6.5"; sha256 = "0rcvkcv99bns7l0zxk7sv5027i40cdwv0cl0vsvcqi6zbziag5df";} {})
<{^_^}>
[nixpkgs] @matthewbauer pushed 2 commits to master: https://git.io/fhH2r
<{^_^}>
[nixpkgs] @matthewbauer closed pull request #52629 → licenses.nasa13: mark as free → https://git.io/fhf8g
isidore has quit [Client Quit]
balsoft has quit [Quit: Konversation terminated!]
<dckc>
@NemesisD, yes, it turns out I was doing `with import <nixpkgs>;` rather than `with import <nixpkgs> {};`. But what if I had thousands of lines of code? How would I find that issue?
balsoft has joined #nixos
<symphorien>
there is --show-trace, but it usually only moderately helpful.
fusion809 has quit [Quit: Leaving]
Melkor333 has joined #nixos
maximiliantagher has quit [Ping timeout: 245 seconds]
o1lo01ol1o has quit [Ping timeout: 240 seconds]
<NemesisD>
is there a way to uniformly not build haddocks and tests in haskell packages?
<dckc>
How does java web app (.war file) deployment fit with nix?
ckauhaus has quit [Quit: WeeChat 2.2]
* dckc
asks the web...
<symphorien>
compiling java is not trivial
<symphorien>
usually jars are just downloaded as such
<dckc>
well, the compile step was just `ant clean dist`. seems kinda trivial
<symphorien>
does it download from the internet ?
<dckc>
but... now what? the `ant deploy` step did:
<dckc>
[copy] Copying 16 files to /opt/wildfly-10.0.0.Final/standalone/deployments/i2b2.war/WEB-INF/lib
<symphorien>
the problem is usually that maven and friends download deps themselves and the sandbox blocks this
Melkor333 has quit [Quit: WeeChat 2.3]
<dckc>
I'm actually trying to upgrade our i2b2 server with a process other than "ssh in and run these commands"
<dckc>
no maven here
Melkor333 has joined #nixos
Melkor333 has quit [Client Quit]
<dckc>
our i2b2 installation is connected to about 5 other services
Melkor333 has joined #nixos
_kwstas has quit [Quit: _kwstas]
<dckc>
I like the idea of building systemd unit files and symlinking them (I don't get to use nixos)... though the target might not be running systemd so I might have to use ... umm...
shibboleth has quit [Quit: shibboleth]
<dckc>
supervisord seems to work
<NemesisD>
infinisil: in your setup in soph, how would you pin a different version of ghc, say if your dependencies didn't build against the latest?
<symphorien>
there is a ling to logs in the topic if you want
<symphorien>
*link
<NemesisD>
also, i keep seeing expressions like `packages = p: [...]`, what is the p: part?
<symphorien>
NemesisD: it's a function
<symphorien>
> { a = foo: foo+1 ; }.a 2
<{^_^}>
3
<dckc>
if you're a python programmer, read: lambda p: ...
<NemesisD>
so its an unused argument?
<symphorien>
depends on the ellipsis :þ
Edes has joined #nixos
<NemesisD>
this stuff is so hard to follow. i have to go look up where its used in the haskell build tool stuff and see that p is self, who knows what that is
<NemesisD>
i wonder if nix needs something like a traceShowId which evaluates an expression but also pretty prints it on evaluation
<symphorien>
when you see self and super, it usually involves fix points, and there I stop trying to understand
<qyliss>
NemesisD: isn't that lib.traceVal?
<simpson>
NemesisD: By your own admission, you are very new at reading Nix. Do not worry; it gets easier with practice.
ingenieroariel has quit [Quit: Page closed]
Dagger has quit [Excess Flood]
simukis has quit [Quit: simukis]
<NemesisD>
qyliss: nice, it is!
<NemesisD>
although i think it is a fix point. my fan got really loud and nothing was printed, lol
Dagger has joined #nixos
<NemesisD>
i'm trying to use this project as a template for mine (https://github.com/Infinisil/soph/blob/master/default.nix), but i'm not seeing how i'd bring in a different ghc, e.g. haskel.compiler.ghc822, or other system deps needed to build. packages is only referenced in that project's shell.nix
<symphorien>
there is a pkgs.haskellPackages822 iirc
<dckc>
so... in wildfly, one unpacks the distribution and then uses directories inside there for mutable state. how would one do this in nix? (looking at the jboss expr...)
rcshm_ has quit [Remote host closed the connection]
<symphorien>
mutable state is usually created in the execStartPre of the systemd service
rcshm has joined #nixos
<symphorien>
something like: if the mutable state does not exist yet, create it, and otherwise, let it be
<dckc>
so how do I put it inside the wildfly file space? some sort of symlink?