nlewo/nix2container
View on GitHub ↗ ★ 941 Go
An archive-less dockerTools.buildImage implementation
16 mentions on Hacker News by 7 people: 0 stories, 16 comments · first 2022-04-19 · latest 2025-12-25
20082026
-
I think this is really close to the way nix2container works ( https://github.com/nlewo/nix2container ). nix2container generates metadata at build time and streams the required data at runtime. At build time, it generates a JSON file…
comment by lewo · 2025-12-25 · in A faster path to container images in Bazel -
…2: https://nix.dev/manual/nix/2.30/command-ref/new-cli/nix3-cop... 3: https://github.com/nlewo/nix2container 4: https://guix.gnu.org/blog/2020/grafts-continued/
comment by pxc · 2025-08-23 · in Closing the Nix gap: From environments to packaged applications for rust -
…a subset of the dependencies required by your image. An example is provided in this section: https://github.com/nlewo/nix2container?tab=readme-ov-file#is... For instance, if your images use bash, you can explicitly create a layer…
comment by lewo · 2025-06-07 · in Why We're Moving on from Nix -
…comes from them. And I actually landed a minor contribution to nix2container, which was nice to do: https://github.com/nlewo/nix2container/pull/77
comment by mikepurvis · 2025-06-03 · in How I like to install NixOS (declaratively) -
I mean if we're going full pie in the sky, fully declarative containers exist today: https://github.com/nlewo/nix2container#nix2container Dagger looks nifty, but it's too bad that it's still basically an imperative "start from thing, do…
comment by mikepurvis · 2025-03-27 · in Dagger: A shell for the container age -
No discussion about Nix-built containers is complete without mentioning nix2container: https://github.com/nlewo/nix2container It is truly magical for handling large, multi-layered containers. Instead of building the container archives…
comment by mikepurvis · 2024-03-15 · in Nix is a better Docker image builder than Docker's image builder -
…stream directly from the nix store into remote docker registries with something like nix2container! https://github.com/nlewo/nix2container
comment by jpetrucc · 2024-01-12 · in Ask HN: How can I make local dev with containers hurt less? -
Example of an actually-declarative container definition: https://github.com/nlewo/nix2container/blob/master/examples/... (disclosure: I have contributed to that repo)
comment by mikepurvis · 2023-08-31 · in Docker Is Four Things -
…that contain platform-specific binaries (such as esbuild). - Container images are built with https://github.com/nlewo/nix2container instead of Nix's built-in docker tools, because nix2container allows configuration of layers and thus makes…
comment by dindresto · 2023-05-19 · in Way to get NVM working in CI/CD systems -
…to assemble them, which can be a huge time savings for incremental building of these things: https://github.com/nlewo/nix2container
comment by mikepurvis · 2023-03-30 · in Building Containers with Nix and Gitlab CI -
…images. [1] https://hercules-ci.com/ [2] https://grahamc.com/blog/nix-and-layered-docker-images [3] https://github.com/nlewo/nix2container/blob/85670cab354f7df6...
comment by lewo · 2023-03-08 · in How we deploy faster with warm Docker containers -
…by basically skipping the tarball step: it directly streams non already pushed layers. [1] https://github.com/nlewo/nix2container
comment by lewo · 2023-02-22 · in Launch HN: Depot (YC W23) – Fast Docker Builds in the Cloud -
…such as crane https://github.com/ipetkov/crane ? And regarding OCI images, i built nix2container ( https://github.com/nlewo/nix2container ) to speed up image build and push times.
comment by lewo · 2023-02-07 · in Crafting container images without Dockerfiles -
For a more modern iteration of that idea, check out https://github.com/nlewo/nix2container It has all the benefits of OP but produces the images much faster, and with less on-disk usage.
comment by zimbatm · 2022-09-11 · in Optimising Docker Layers for Better Caching with Nix (2018) -
…removing that dependency? It shouldn't be necessary to create an OCI compliant image with Nix. [1]: https://github.com/nlewo/nix2container
comment by aliasxneo · 2022-08-18 · in Nixpacks takes a source directory and produces an OCI compliant image -
With https://github.com/nlewo/nix2container , I'm trying to make a more standalone tool. Basically, a Go binary takes a reference graph and produces a JSON file describing a container image. This JSON file is then ingested by a Skopeo fork…
comment by lewo · 2022-04-19 · in Nixery – Docker images on the fly with Nix