This Docker image implements Nix and uses the shell.nix file at the root of the project to load all the dependencies needed.
This aims only Gitlab CI as it is a pain to use nix-shell with the current CI configuration.
In Gitlab, create a CI yaml file and use it like following.
image: nicolasguilloux/gitlab-nix-shell:20.09
test:
script:
- something
It will load the shell.nix file at the root of your project. Here is an example to use the hugo software from the unstable branch and the asciidoctor from the stable branch.
{ pkgs ? import <nixpkgs> {}, unstable ? import <nixpkgs-unstable> {} }:
pkgs.mkShell {
buildInputs = [
unstable.hugo
pkgs.asciidoctor
];
}
There are 2 channels available for now:
nixpkgs: uses the 20.09 channelnixpkgs-unstable: uses the unstable channelContent type
Image
Digest
Size
329.9 MB
Last updated
over 5 years ago
docker pull nicolasguilloux/gitlab-nix-shell:20.09