The Quay build system has implemented caching. The builder preemptively calculates the hashes of Dockerfile commands and then sends them to an API endpoint that finds the tag for the most similar tree of command hashes in a given repository. This tag is pulled before ever attempting to build the Dockerfile.
Google's solution seems far more general than just building Dockerfiles. I'm glad they're pushing for more innovation in this space.
Bazel is a general purpose build system that focuses on reproducibility (same build inputs -> same build outputs) and strict dependency specification (at various levels: file, subsystem, external package fetching etc.) enforced by sandboxing which allows for fast incremental builds. Bazel is the open-source version of Google's internal build-system.
More info here: https://bazel.build/
How external resources are handled: https://bazel.build/versions/master/docs/external.html
Obviously Bazel requires some buy-in which may be unappealing (at least for existing projects: migration/supporting multiple build systems.) There are, however, serious benefits (and a larger, but nascent, ecosystem of related open-source tooling.) The biggest gap at the moment is supported languages/etc.
(I don't work for Google, I just like Bazel.)
It has some major speed benefits. But it's not turnkey. Setting it up is hard. Its dep management in Go isn't compatible with lint, vet, etc. We never got node modules installing with Bazel.
Googling for this issue I found out that if you fail and try you might even be blocked (from the servers) for trying to fetch too many dependencies and the solution was to "try later"...
Yarn works the same.
Use different semantics if you must, but please use some existing syntax for your DSL.
I'm so tired of learning a pointless new variety of almost the same thing, only with slightly different syntax, maybe some awkward string quoting, and some rather pointless syntactic sugar.
I'm not saying NixOS is the worst offender, but innovating in (mostly) superficial syntax, or using obscure syntax is almost certainly not well spent time except for a few very narrow niches/contexts. Especially not for prospective users.
I get it, it's fun inventing both languages and tools, I love doing it myself!
However, and in general: Don't invent a language when you need a tool, and vice versa.
It does not excuse Nix to have such a braindamaged^W esoteric syntax.
I don't think the immutability is actually important. Only derivations (which are basically language agnostic) need to be immutable/hashable.
> It does not excuse Nix to have such a braindamaged^W esoteric syntax.
What's so bad about it? The main pain point I've found with it is the lack of documentation for builtin functions. The syntax seems fine to me.
Much of our container building includes fetching dependencies from various package managers which rarely changes across builds, yet takes up the majority of the build time. Most of the time thats good enough, but for cases where we want to immediately deploy a fix, it can be quite frustrating to having to spend all this time seemingly unncessarily.
Edit: Docker 1.13 has the new --cache-from option so it seems relatively straight-forward to do I guess?