Add basic flake

This commit is contained in:
Robert Hensing 2020-10-05 16:22:15 +02:00
parent 5ed7b893bd
commit 29599f529b
2 changed files with 52 additions and 0 deletions

25
flake.lock Normal file
View file

@ -0,0 +1,25 @@
{
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1601906239,
"narHash": "sha256-P1jBYbYeFswig/0FKbgh+BpVhh9iurD3m0T2ae4gdx8=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c2bb4af48d26ed091e5674394bacbf8d488c7939",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

27
flake.nix Normal file
View file

@ -0,0 +1,27 @@
{
description = "Arion - use Docker Compose via Nix";
outputs = { self, nixpkgs }:
let
lib = import (nixpkgs + "/lib");
systems = [
"aarch64-linux"
"x86_64-darwin"
"x86_64-linux"
];
in {
packages = lib.genAttrs systems (system:
let
pkgs = nixpkgs.legacyPackages.${system};
in
{
arion = import ./nix/arion.nix { inherit pkgs; };
});
defaultPackage = lib.genAttrs systems (system:
self.packages.${system}.arion
);
};
}