nowfound

Dev tools · October 5, 2024

CN

Compose2nix – NixOS and Docker Compose made easy

Hi! compose2nix is a CLI tool that automatically converts your Docker Compose project into a NixOS configuration[1]. * Why does this even exist? Well, NixOS is a Linux distro that is configured using Nix (the language). However, Compose adds a configuration layer on top that is opaque to Nix, which means you lose out on some of the "magic" of NixOS. compose2nix solves this by "lifting" Compose functionality into native Nix/NixOS constructs, which results in a more native integration with NixOS. In addition, this tool unlocks two primary use-cases: 1. You can run existing non-trivial…

What it does

In the maker’s words, at launch

Hi! compose2nix is a CLI tool that automatically converts your Docker Compose project into a NixOS configuration[1]. * Why does this even exist? Well, NixOS is a Linux distro that is configured using Nix (the language). However, Compose adds a configuration layer on top that is opaque to Nix, which means you lose out on some of the "magic" of NixOS. compose2nix solves this by "lifting" Compose functionality into native Nix/NixOS constructs, which results in a more native integration with NixOS. In addition, this tool unlocks two primary use-cases: 1. You can run existing non-trivial applications - e.g., Immich - without worrying if they're natively packaged for NixOS. 2. You can bring your existing Compose stack over to NixOS and run it as-is without having to rewrite it in Nix. The auto-generated config can either act as a starting point, or you can keep your Compose file as the source of truth and re-generate it as you go. * How does it work? compose2nix maps Compose constructs into systemd services that run native Docker/Podman commands. Under the hood, the tool utilizes the same Compose library[2] used by the Docker CLI, so you also get Compose syntax checking "for free". In a way, it's a thin re-implementation of the Docker Compose CLI. One thing to point out is that compose2nix aims to natively support both Podman and Docker as container runtimes. The README has a bit more detail. There's also a (somewhat rambly) video that explains what the project is about and includes a short demo of the tool: https://www.youtube.com/watch?v=hCAFyzJ81Pg Oh, and please feel free to shoot me any questions or feedback (good or bad)! [1]: In case it's your first time hearing about NixOS, here is a good overview: https://zero-to-nix.com/concepts/nixos [2]: https://github.com/compose-spec/compose-go

Does the same job

all alternatives →

More dev tools this month

the category →
  • Dograh592

    The open source VAPI alternative

    Dev tools · 25d ago · dograh.com

  • Meridian530

    Don't let your work go unnoticed. Get promoted!

    Dev tools · 20d ago · meridiona.com

  • x1516

    Lovable for iPhone apps go from idea to App Store

    Dev tools · 11d ago · x1.new

  • Open-source GTM skills for technical founders

    Dev tools · 29d ago · gtmcofounder.com

  • OpenTrailPaper is open-source bike computer firmware for the LilyGO T5S3 4.7" E-Paper PRO. It supports offline maps, GPX routes, FIT recording and Bluetooth sensors.

    Dev tools · 1d ago · opentrailpaper.com

  • Nuphos380

    The AI-Native DevOps Workspace.

    Dev tools · 24d ago · nuphos.ai

Launched alongside, October 2024

the whole month →
  • buzzabout1,267

    Audience insights from 1B+ online discussions in 2 mins

    AI · 2024 · buzzabout.ai

  • bolt.new1,233

    Prompt, run, edit & deploy full-stack web apps

    AI · 2024 · bolt.new

  • Feta1,217

    Run smarter stand-ups, build better products

    AI · 2024 · feta.io

  • Trag955

    AI code review companion

    AI · 2024 · usetrag.com

  • Turn Notion databases into portals & apps with no code

    Dev tools · 2024 · softr.io

  • One inbox for all your work discussions

    Work · 2024 · generalcollaboration.com