[Nix-dev] Override virtualbox
Vladimír Čunát
vcunat at gmail.com
Wed Aug 24 21:29:54 CEST 2016
On 08/24/2016 08:59 PM, Daniel Hlynskyi wrote:
> I know about nixpkgs.config.packageOverrides, but I cannot override
> virtualbox with it. Given
>
> nixpkgs.config.packageOverrides = sup_: {
> linuxPackages.virtualbox =
> sup_.linuxPackages.virtualbox.override { headless = true; };
> };
> virtualisation.virtualbox.host.enable = true;
>
> I get error in nixops deploy:
>
> error: attribute ‘kernel’ missing, at
> /home/danbst/nixpkgs/nixos/modules/services/logging/klogd.nix:12:42
> (use ‘--show-trace’ to show detailed location information)
>
> Without override it evaluates OK.
>
> What am I doing wrong?
The problem is that your code replaces *whole* `linuxPackages` by this
`linuxPackages.virtualbox`. It should work to have
linuxPackages = sup_.linuxPackages // {
virtualbox = sup_.linuxPackages.virtualbox.override {
headless = true
};
};
--Vladimir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3771 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.science.uu.nl/pipermail/nix-dev/attachments/20160824/c881ecc3/attachment.p7s>
More information about the nix-dev
mailing list