<clever>
noonien: /usr/bin/env is missing in the nix sandbox
<clever>
evanjs: you may also want to look at my kexec test stuff too
<clever>
evanjs: what happens if you boot without -nographic?
<clever>
evanjs: got a link?
<clever>
evanjs: with qemu, you can just use -kernel and -initrd to load both
<clever>
evanjs: i implemented proper initrd support in my firmware, just to avoid using it
<clever>
evanjs: i find that INITRAMFS_SOURCE is a pain to deal within, within nix, because you have to rebuild the entire kernel every time you change something
<clever>
nixlanguagestuff: so you want `import ./coresimple.nix {}`
<clever>
nixlanguagestuff: the `{}` says that it accepts a set, that must have exectly nothing in it
<clever>
nixlanguagestuff: can you link an example file?
<clever>
what you did, is basically: let logAdapterRev = 123456789abcd12345678; in ...
<clever>
ilya_g: 123456789abcd12345678 is not a valid nix expression, you want --argstr there
<clever>
it will parse the 2nd part as nix, so strings have to be quoted, and then quoted again to stop bash from parsing it, like --arg foo '"bar"', or use --argstr foo bar, to make nix treat it directly as a string
<clever>
ilya_g: --arg can set those params, --arg paramname nixexpr
<clever>
WinchellsM: wrapProgram and prepend to PATH
<clever>
it does also support ssh agent
<clever>
(note, somebody deleted it from nixpkgs)
<clever>
evanjs: you want pkgs.fetchgitprivate, if you want private submodules
<clever>
evanjs: the function also works in nix-shell
<clever>
dashkal: and after single-stepping thru linux for .... 40 minutes? linux has finished decompressing itself, lol
<clever>
Uncompressing Linux... done, booting the kernel.
<clever>
then changes i make to the usb stick will persist
<clever>
rather then using the iso image
<clever>
i like doing nixos-install against a usb stick
<clever>
ah, yeah
<clever>
dashkal: my yak shaving involves single-stepping thru the linux decompressor, on an rpi2
2020-02-04
<clever>
,paste
<clever>
,pastebin drew__b
<clever>
drew__b: i try to ensure stack is never in ~/.nix-profile/bin/
<clever>
drew__b: why is ~/.nix-profile being in PATH a problem?
<clever>
drew__b: also, nix-shell runs bash
<clever>
drew__b: what does it do then?
<clever>
what does .zshrc do?
<clever>
yep
<clever>
and nix wont work without those, thats how nix itself gets into PATH
<clever>
nix.sh
<clever>
root's profile is a default fallback for all users
<clever>
drew__b: ~/.nix-profile is for the current user, profiles/default/bin is roots profile
<clever>
drew__b: what is installed into that dir, that is causing problems?
<clever>
tester123: what does the default.nix in the root of the repo contain?
<clever>
tester123: you need to do something like run callPackage on the return value of fetchFromGitHub
<clever>
AmandaC: you get what you pay for!
<clever>
infinisil: the demo.nix profile?
<clever>
enless you use the home-manager nixos module
<clever>
wild_buffalo: thats what home-manager does
<clever>
yeah
<clever>
that sounds like a configuration.nix only option
<clever>
wild_buffalo: configuration.nix is for nixos options, which are used to build /run/current-system/
<clever>
wild_buffalo: config.nix is only for nixpkgs level flags
<clever>
wild_buffalo: and how did you define that in config.nix?
<clever>
wild_buffalo: what are you trying to do?
<clever>
wild_buffalo: each time you run a nix command, it re-reads it
<clever>
monadplus: other way around
<clever>
monadplus: if nixops is being ran on darwin, it cant build linux things, so it will try to configure the remote machine as a build machine, automatically
<clever>
monadplus: if the machine running nixops is linux, it will build it locally, but also obey any build machines configured in /etc/nix/machines
<clever>
monadplus: nixops always compiles it locally
<clever>
kvda: then you can just add it to the buildInputs of anything else within that nixpkgs dir, and it should just work like any other package
<clever>
kvda: you need to build it with nix-build, thats the only way that another package can then depend on it
<clever>
dashkal: what command do you need to run when bumblebee is active?
<clever>
then you have 2 different scripts, that both do basically the same thing, and nixos installs the right one
<clever>
dashkal: you could also just make a shell script, that does the right thing, and choose which shell script to install, based on hardware.bumblebee.enable
<clever>
dashkal: so you need to either look for the side-effects that hardware.bumblebee.enable causes, or just make your own side-effect that is obvious (the above example)
<clever>
dashkal: nixos doesnt keep the configuration.nix around after it builds
<clever>
dashkal: but if your config generates an answer in /etc, that answer will always match your current state
<clever>
dashkal: if you edit configuration.nix and dont nixos-rebuild, then querying configuration.nix gives you the wrong answer, and everything breaks
<clever>
dashkal: the reason i say to make a file like this, is state vs config
<clever>
dashkal: environment.etc.whatever.text = if config.hardware.bumblebee.enable then "bumblee on" else "wheres the bee";
<clever>
might want to use if though, toString does weird things with bools
<clever>
dashkal: if you add that to your nixos config, it will generate a /etc/whatever file, that contains the bool
<clever>
jared-w: that only works for fixed-output derivations, and wont actually let you connect to the unix socket
<clever>
brano543: yeah
<clever>
brano543: so everything is already working perfectly
<clever>
brano543: if you read the .service file in result, where is it getting the postgresql binary from?
<clever>
das_j: and if you use ssh://big-fat-host, that host wont know what hydra has done recently, and what to keep, so any GC will potentially delete recent things
<clever>
das_j: the s3 based hydra has zero garbage collection
<clever>
das_j: and then your hydra will push everything to another machine
<clever>
das_j: in theory, ssh://big-fat-host could also be used, where s3://bucket was
<clever>
das_j: if the build machine has aws secrets, you can also use s3://bucket to keep things private
<clever>
das_j: that configures hydra to upload everything to an S3 bucket, then you can just use https://bucket.awssomething.com as your cache
<clever>
brano543: that will work even outside of nixos, you just have to combine `import <nixpkgs/nixos> { configuration = ./configuration.nix; }` and the eval.config.systemd.units."postgresql.service".unit your already doing
<clever>
brano543: now try deleting everything thats under systemd.services.postgresql and see if it still builds
<clever>
brano543: services and systemd.services are 2 different things
<clever>
brano543: i said services.postgresql.extraPlugins not systemd.services.postgresql.extraPlugins
<clever>
brano543: the same place you set services.postgresql.enable
<clever>
brano543: now try setting services.postgresql.extraPlugins and build again
<clever>
brano543: comment that line out in your config, and build again
<clever>
brano543: what happens if you set services.postgresql.enable = true; and then use https://pastebin.com/4fqJ2sbc again?
<clever>
brano543: you might save yourself a lot of work, if you just set options within services.postgresql
<clever>
brano543: ahh, your entirely skipping the postgresql module
<clever>
brano543: can you pastebin your current code?
<clever>
systemd.services.postgresql the nixos module for systemd, it will then use those options, to auto-generate a postgresql.service file
<clever>
brano543: services.postgresql is a nixos module, that defines postgresql options, it will then set systemd.services.postgresql options for you
<clever>
brano543: no, it should be inside services.postgresql
<clever>
and what problem its having
<clever>
brano543: can you pastebin the code your using, when you try to use services.postgresql.extraPlugins ?
<clever>
brano543: the postgresql module calls .withPackages for you, so stacking it like that may fail
<clever>
brano543: .withPackages will then create a new derivation, that symlinks all of the chosen extensions together, and tells postgresql to look there
<clever>
brano543: that will automatically call pkgs.postgresql.withPackages, and give it a list of plugins
<clever>
brano543: you use the services.postgresql.extraPlugins option in nixos
<clever>
brano543: you dont
<clever>
brano543: you can only ever create files in $out, not your inputs
<clever>
evanjs: thats from the platform set, passed to crossSystem i think
<clever>
pkgsCross.musl64
<clever>
evanjs: there is also the musl "cross compile" target
<clever>
evanjs: this adds the vc4 binutils/gcc/newlib
<clever>
evanjs: you can use nix-build to compile fragments of a configuration.nix as well
<clever>
evanjs: and you can use `boot.kernelPackages = pkgs.linuxPackages.extend (self: super: { foo = self.callPackage ./foo.nix {}; });` to add a new thing in
<clever>
evanjs: you want boot.kernelPackages and boot.initrd.availableKernelModules
<clever>
m15k: you want either pkgs.fetchgitprivate (which was deleted) or builtins.fetchGit
<clever>
virus_dave: you want to split it into 2 pieces, the fixed-output half that works on any platform, and then a non-fixed half that is platform specific
<clever>
virus_dave: anything with a runtime dependency (such as on a shell) must not be fixed-output
<clever>
if the bool is false, it will use "" instead of the string you gave it
<clever>
i077: then you have to get ugly, and use LD_LIBRARY_PATH
<clever>
i077: if its dynamically loading it using dlopen, it will never obey the RPATH
<clever>
yep
<clever>
not sure
<clever>
that would definitely explain the error
<clever>
ah
<clever>
i077: though, it could also be resources.pak? not sure entirely
<clever>
i077: thats a special type of compressed archive that electron uses
<clever>
i077: i think app.asar is the target you want
<clever>
i077: what files are in that directory?
<clever>
i077: try giving electron that dir anyways, and see what happens
<clever>
if no args are given, it defaults to that dir
<clever>
i077: its usually the same directory the original ELF binary was in
<clever>
i077: and pass it that
<clever>
i077: find the directory with the package.json file
<clever>
i077: reusing the pre-compiled js in the .deb is sometimes simpler
<clever>
javascript aint as simple as it used to be, lol
<clever>
i077: if your using the github source, you may need to "compile" it first
<clever>
xavierzwirtz[m]: lib.cleanSourceWith
<clever>
but that register is also overwritten by any other thing you call
<clever>
kandinski: and behind the scenes c sort of does that, the return value is just whatever was last put into a given register, which can lead to fun bugs if you forget the return statement
<clever>
kandinski: haskell sort of does that, though it looks more like a function called return, which sets it
<clever>
you can do the same with cat
<clever>
writeScriptBin is a helper to create a "package" with only a $out/bin/daedalus-frontend
<clever>
${rawapp}/share/daedalus is a directory with a package.json file