Skip to content

nixos/virtualisation.incus: PATH for truenas_incus_ctl not defined #451914

@p-revo

Description

@p-revo

Nixpkgs version

  • Unstable (25.11)

Describe the bug

Incus version > 6.16 introduced the TrueNAS storage driver.

For the driver to work, the truenas_incus_ctl cmdline program and the openiscsi package must be installed on the host system. Where "openiscsi" is directly available in nixpkgs, the truenas_incus_ctl program is not.

However, "truenas_incus_ctl" is a Go program and it is easy enough to install it on a NixOS system. For example with:

{ pkgs, ... } { nixpkgs.overlays = [ (final: prev: { truenas-incus-ctl = pkgs.buildGoModule rec { pname = "truenas_incus_ctl"; version = "0.7.4"; src = pkgs.fetchFromGitHub { owner = "truenas"; repo = "truenas_incus_ctl"; rev = "v${version}"; sha256 = "sha256-2AlLyU46I4gy7X4sdk/635Ru+8bcbELG1nvQKhDsQD8="; }; vendorHash = "sha256-4mm28T6nWTe3UvwGJ1S7s09ZSRZjm6TGcTD13vazUa4="; }; }) ]; }

The problem is that even when "truenas_incus_ctl" program is then made available on the system, the incus daemon will not recognize it (not in PATH).

Steps to reproduce

Already the partial command:
incus storage create testpool truenas

Results in the following error:
Error: Required tool 'truenas_incus_ctl' is missing

Expected behaviour

Incus should recognize the truenas_incus_ctl installation PATH

Screenshots

No response

Relevant log output

Additional context

No response

System metadata

  • system: "x86_64-linux"
  • host os: Linux 6.12.51, NixOS, 25.05 (Warbler), 25.05.20251010.7e297dd
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.28.5
  • nixpkgs: /nix/store/7wf5s8skd51jfiym9j6mahxdk6b4ka9b-source

Notify maintainers

@aanderse @adamcstephens @megheaiulian @mkg20001


Note for maintainers: Please tag this issue in your pull request description. (i.e. Resolves #ISSUE.)

I assert that this issue is relevant for Nixpkgs

Is this issue important to you?

Add a 👍 reaction to issues you find important.

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: enhancementAdd something new or improve an existing system.6.topic: nixosIssues or PRs affecting NixOS modules, or package usability issues specific to NixOS

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions