-
Notifications
You must be signed in to change notification settings - Fork 269
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Current Behavior (bug)
if I have a flake.nix that uses an insecure package, it shows an error.
flake.nix
{
description =
"This flake outputs a modified version of Yarn that uses NodeJS 20";
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
# Use the flake-utils lib to easily create a multi-system flake
flake-utils.lib.eachDefaultSystem (system:
let
# You can define overlays as functions using the example below
# This overlay will modify yarn to use nodejs-16_x
overlay = (final: prev: rec {
nodejs = prev.nodejs_14;
yarn = prev.yarn.override { nodejs = nodejs; };
});
#
pkgs =
import nixpkgs {
inherit system;
# Add your overlays to the list below. Note that they will be applied in order
overlays = [ overlay ];
};
in rec {
# For our outputs, we'll return the modified Yarn package from our overridden nixpkgs.
packages = {
yarn = pkgs.yarn;
nodejs = pkgs.nodejs;
};
}
);
}
add the flake with devbox:
devbox add "path:overlay#nodejs" --allow-insecure
# or
devbox add "path:overlay#yarn" --allow-insecure
it shows an error:
Error: Package Package ‘nodejs-14.21.3’ is insecure.
To override use `devbox add <pkg> --allow-insecure`
Expected Behavior (fix)
The flake with an insecure package is installed when using --allow-insecure
Additional context
Please include the output of devbox version -v
and
a copy of your devbox.json
file.
devbox version (latestnhost x!?)
0.5.7
{
"packages": [
],
"shell": {
"init_hook": "yarn"
},
"nixpkgs": {
"commit": "f80ac848e3d6f0c12c52758c0f25c10c97ca3b62"
}
}
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working