nix-cage icon indicating copy to clipboard operation
nix-cage copied to clipboard

nix pkgs.buildFHSUserEnv support

Open georgyo opened this issue 3 years ago • 1 comments

nix-shell has a pretty awesome ability to create a FHS compatible environment. However the shell hook current breaks nix-cage.

IE the following shell.nix:

# shell.nix
{ pkgs ? import <nixpkgs> {} }:

(pkgs.buildFHSUserEnv {
  name = "simple-x11-env";
  targetPkgs = pkgs: (with pkgs; [
    python3
  ]);
  multiPkgs = pkgs: (with pkgs; [
    python3
  ]);
  runScript = "bash";
}).env

georgyo avatar Sep 24 '21 23:09 georgyo

Thank you for the report. I don't know much about buildFHSUserEnv, but it looks like it creates some kind of chroot. Will try to dive more deeply into this

corpix avatar Sep 26 '21 21:09 corpix