We provide nixos base configurations that install all necesarry things such as git, git ansible integration or dev tools.
There are three available configs:
- base: Tools needed for all teams (git, docker, etc.)
- devops: base + Tools and integrations for deployments (ansible, etc.)
- dev: base + Tools for development (go, etc.)
This method uses the special args method for convinience
inputs.mgit.url = "github:mgit-at/nixos-common/master";
inputs.mgit.inputs.nixpkgs.follows = "nixpkgs";
before:
{
outputs = { nixpkgs }: {
# your stuff...
};
}
after:
{
outputs = { self, nixpkgs, ... } @inputs: let # add self and @inputs, start a let
inherit (self) outputs; # add this
in # end the let
{
# your stuff...
};
}
before:
{
nixosConfigurations.my-machine = nixpkgs.lib.nixosSystem {
modules = [
# your stuff...
];
};
}
after:
{
nixosConfigurations.my-machine = nixpkgs.lib.nixosSystem {
specialArgs = {inherit inputs outputs;}; # add this
modules = [
# your stuff...
];
};
}
before:
{ config, pkgs, lib, ... }: {
imports = [
# your stuff...
];
nixpkgs.overlays = [
# your stuff...
];
# your stuff...
}
after:
{ inputs, config, pkgs, lib, ... }: { # add inputs here
imports = [
inputs.mgit.nixosModules.laptop.all # or devops, or dev
# your stuff...
];
nixpkgs.overlays = [
inputs.mgit.overlays.default
# your stuff...
];
# your stuff...
}