News for hackers. Stuff that matters.
Re:Modus: A language for building Docker/OCI container images by OJFord on Wednesday August 03, 2022 @12:45PM (#32334026)
I hadn't realised you could use Nix for building images, or at least not standalone. An article: https://thewagner.net/blog/2021/02/25/building-container-ima...
Re:Modus: A language for building Docker/OCI container images by yewenjie on Wednesday August 03, 2022 @01:27PM (#32334560)
There is also https://nixery.dev/ which lets you get Docker images with arbitrary Nix packages - useful for quick hacking.
Re:Modus: A language for building Docker/OCI container images by MuffinFlavored on Wednesday August 03, 2022 @04:59PM (#32336605)
Kind of confusing. NixOS vs Nix the language...

You use Nix the language to build Docker images and avoid the NixOS CLI tools/runtime?

Re:Modus: A language for building Docker/OCI container images by k__ on Wednesday August 03, 2022 @06:09PM (#32337147)
Nix the package manager.

Nix the language.

NixOS the Linux built with Nix as it's default package manager that uses the Nix language.

Re:Modus: A language for building Docker/OCI container images by MuffinFlavored on Wednesday August 03, 2022 @06:58PM (#32337474)
Nix the language can compile OCI (Open Container Initiative) format images that can be deployed/ran/executed via Docker or k8s?

Or is that Nix the package manager? Does Nix the package manager compile Nix the language images?

Re:Modus: A language for building Docker/OCI container images by piperswe on Wednesday August 03, 2022 @07:16PM (#32337573)
[nixpkgs the package collection] (which is used by [Nix the package manager], and also contains the [Nix the programming language] expressions that define [NixOS the operating system]) has expressions for easily building OCI images: https://nixos.org/manual/nixpkgs/stable/#sec-pkgs-dockerTool...
Re:Modus: A language for building Docker/OCI container images by MuffinFlavored on Wednesday August 03, 2022 @10:27PM (#32338647)
Do you have to be on NixOS to use the OCI images outputtable by nixpks/nix package manager or can you build OCI images using Nix from Mac/Windows/other non NixOS Linux?
Re:Modus: A language for building Docker/OCI container images by elikoga on Thursday August 04, 2022 @11:16AM (#32344025)
> Do you have to be on NixOS to use the OCI images outputtable by nixpks/nix package manager

No

> can you build OCI images using Nix from Mac/Windows/other non NixOS Linux?

Non NixOS Unix, not Windows yet, unless you use WSL or a VM

Re:Modus: A language for building Docker/OCI container images by piperswe on Saturday August 06, 2022 @07:29PM (#32372534)
They're just normal OCI images, so they can be run by any OCI-compatible container runtime. You can build images from any system running Nix, though you might encounter trouble on non-Linux systems because you may need to cross-compile the packages you use. The build process is exactly the same on any Linux distro (including NixOS and anything else) though.
Re:Modus: A language for building Docker/OCI container images by rmorey on Wednesday August 03, 2022 @03:21PM (#32335743)
woah - this is great, thanks