Re: [Nix-dev] Build a derivation using sbt
I haven't used it, but there is [sbtix][1]. [1]: https://github.com/teozkr/Sbtix -- Utku Demir m...@utdemir.com On Sat, May 6, 2017, at 10:14 AM, Volth wrote: > Hello > > Anyone tried to build a derivation using sbt ? > I found no one such project in nixpkgs. > > sbt feels very bad running under "nixbld1", it needs to create ~/.sbt > ~/.ivy and to download tons of jars there... > ___ > nix-dev mailing list > nix-dev@lists.science.uu.nl > https://mailman.science.uu.nl/mailman/listinfo/nix-dev ___ nix-dev mailing list nix-dev@lists.science.uu.nl https://mailman.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] nix on the corporate world (no direct internet access)
On our company, we're dealing a lot with nasty corp network environments, and using nix only with minor hiccups. We have the exact same problem (Corporate firewalls); but a slightly different use case, our only objective is to install a specific derivation. We first generate a binary cache and serve that `$cache_dir` with a simple static web server: $ nix-push --dest $cache_dir /nix/store/00-myPackage And on the client, we just install nix and run: $ nix-store --option extra-binary-caches https://our-server/our-path --realise /nix/store/00-myPackage $ nix-env -i /nix/store/00-myPackage We iterated a while trying different options (`nix-install-package` etc.) and found this to be most robust way. Some problems we got: * Some security devices can block big files (> 100mb), we had to split some of our larger derivations to smaller ones * nix can make hundreds of HTTP requests to the cache when realising a derivation. DOS prevention devices can interfere with that * We could only use HTTPS web servers with self-signed certificates (bec. they have no domain), but our version of nix didn't have an option to disable certificate control. We had to patch nix's source to allow that. Feel free to ask if you have more questions. Utku On Fri, 8 Jul 2016 at 13:56 Azul wrote: > Hey all, > > So I am using nix on one of those nasty corp network environments, where > not even DNS works and everything needs to go through the corporate proxy. > > The proxy is slow, a lot of URLs are blocked down as 'gambling' (just try > to download a jenkins plugin !!) and using tooling like cntlm is hard, as > it hangs more often than not on load. > > in my production environment, I won't have internet access so I need to > install nix packages from a on-premises repository. > > > So we're looking into caching the nix packages we consume through a remote > repository in artifactory (which can get much friendlier 'red tape' in > accessing the outside world). > > My question, is has anyone done this ? > would a silly url like http://artifactory/remote_nix/file_paths > invalidate the hydra cache and force all packages to be built locally ? > > -azul > > ___ > nix-dev mailing list > nix-dev@lists.science.uu.nl > http://lists.science.uu.nl/mailman/listinfo/nix-dev > ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] Basic string functions in nixops
I usually check .nix files in " https://github.com/NixOS/nixpkgs/tree/master/lib"; folder when searching for basic functions. String manipulation functions are in "strings.nix". On your case, this should work: nix-repl> with (import ); concatStrings (take 16 (stringToCharacters "0123456789abcdefghijklmnop")) "0123456789abcdef" On Mon, 25 Jan 2016 at 18:16 4levels <4lev...@gmail.com> wrote: > Dear Nix Devs, > > I'm currently looking (again) for the basic string functions. > Use case: I need to limit a parametric string's length to maximum 16 > characters (indeed, MySql usernames cannot be longer than 16 characters). > > Any hints in the right direction to substring a string in case it is > longer than 16 chars are greatly appreciated ;-) > > Kind regards, > > Erik aka 4levels > ___ > nix-dev mailing list > nix-dev@lists.science.uu.nl > http://lists.science.uu.nl/mailman/listinfo/nix-dev > ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev
Re: [Nix-dev] nixpkgs haskell system got into inconsistent state broken
Also, there is a slightly faster way to recover from that bug mentioned in Nixpkgs Manual[1], which is to just rebuild the problematic package and its dependencies. [1] http://nixos.org/nixpkgs/manual/#how-to-recover-from-ghcs-infamous-non-deterministic-library-id-bug On Mon, 21 Sep 2015 at 14:19 Thomas Hunger wrote: > It's possible you hit the infamous non-deterministic package hash > generation [1] for which Peter collected data recently [2]. AFAICT the only > solution is to remove and rebuild or refetch all haskell packages. > > This bug has high priority for GHC 8 so I hope it'll eventually go away. > > > > [1] > https://ghc.haskell.org/trac/ghc/ticket/4012 > > [2] > http://lists.science.uu.nl/pipermail/nix-dev/2015-June/017405.html > > On 21 September 2015 at 10:41, Miguel Negrão < > miguel.negrao-li...@friendlyvirus.org> wrote: > >> Hi >> >> This week I encountered a situation where when I tried to build one of my >> own packages which was working fine before, it would fail claiming that >> every single Haskell package it needed was missing: >> >> http://pastebin.com/agqw9dn2 >> http://pastebin.com/Vyqc5U3e >> >> I had not changed anything or installed anything in nix for quite a while, >> the only thing I can think that could have caused this was that my >> filesystem had died (btrfs) and I had to restore from backup the whole of >> /. >> I have not used binary cache to build any of the haskell packages, they >> were >> built from source. >> >> Is it possible that the restore of / via rsync could have caused this ? >> >> In the meantime I had did a rm -r /nix and installed everything again and >> my >> system is working again, exactly as before this issue (I had everything >> specified in my config.nix), which is a testament to how easy it is to >> rebuild a system with nix if you have a declarative description of your >> packages. >> >> Thanks, >> Miguel >> >> ___ >> nix-dev mailing list >> nix-dev@lists.science.uu.nl >> http://lists.science.uu.nl/mailman/listinfo/nix-dev >> > > ___ > nix-dev mailing list > nix-dev@lists.science.uu.nl > http://lists.science.uu.nl/mailman/listinfo/nix-dev > ___ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev