Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to specify nixpkgs path or channel #31

Closed
davidak opened this issue Aug 19, 2019 · 3 comments
Closed

Add option to specify nixpkgs path or channel #31

davidak opened this issue Aug 19, 2019 · 3 comments

Comments

@davidak
Copy link
Contributor

davidak commented Aug 19, 2019

I need nixpkgs with a patch, so this feature whould be useful!

Or can i already use an env var? Then, please document it.

Currently, i use nix-build like this:
[davidak@ethmoid:~/code/nixpkgs/nixos]$ time nix-build /home/davidak/code/nixpkgs/nixos -A config.system.build.isoImage -I nixos-config=/home/davidak/code/nixos-config-greenbone/machines/targets-image/configuration.nix default.nix

@zimbatm
Copy link
Member

zimbatm commented Aug 19, 2019

Fixed in e657889. You can now pass -I nixpkgs=/path/to/nixpkgs like on a nix-build command.

@zimbatm zimbatm closed this as completed Aug 19, 2019
@zimbatm
Copy link
Member

zimbatm commented Aug 19, 2019

before that you could already do that with NIX_PATH=nixpkgs=/path/to/nixpkgs nixos-generate ...

@davidak
Copy link
Contributor Author

davidak commented Aug 26, 2019

Perfect. Thanks for the fast fix!

Now i can just specify my unmerged PR branch to build the image:

nixos-generate -I nixpkgs=https://api.github.com/repos/davidak/nixpkgs/tarball/backport_nixos-containers-TimeoutStartSec -c /home/davidak/code/nixos-config-greenbone/machines/targets-image/configuration.nix -f iso

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants