News for hackers. Stuff that matters.
Re:The Flox Open Beta by ptannor on Tuesday February 07, 2023 @01:35PM (#34696977)
I know that this has been asked in past threads but I would love to understand how Nix compares to containers and on top of that what does flox provide in it's comparison to containers?
Re:The Flox Open Beta by hatross on Tuesday February 07, 2023 @02:23PM (#34697847)
Nix and flox will give you:

1. A more reproducible environment thanks to nix determinism 2. A more widely re-usable base approach in the form of environments vs containers

with flox, you can develop software in a development environment that matches the way the software will be packaged. Then, you can distribute this software so that someone can just run "flox install" on Mac, Linux, Windos WSL2, or it can be loaded into a docker container image and deployed that way.

Re:The Flox Open Beta by tomberek on Tuesday February 07, 2023 @02:23PM (#34697854)
hypothetical Dockerfile:

    FROM python
    FROM nodejs
    RUN sh -c 'python ... | node ...'
Imagine this Dockerfile being valid. We want to express the idea of composing these two images into one and using binaries from both. Consider that those might have conflicting /usr/lib contents?! This is easy with flox+nix because that conflict doesn't happen.

There are other benefits such as: - minimal containers - automatic extraction of artifacts and their runtime-dependencies - no more pushing your compilers into prod - no cleaning steps (apt-cache clean) - declarative - reproducible - more fun!