aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--default.nix1
-rw-r--r--flake.lock41
-rw-r--r--flake.nix13
-rw-r--r--pkgs/default.nix4
4 files changed, 56 insertions, 3 deletions
diff --git a/default.nix b/default.nix
deleted file mode 100644
index 26470b5..0000000
--- a/default.nix
+++ /dev/null
@@ -1 +0,0 @@
-import ./pkgs
diff --git a/flake.lock b/flake.lock
new file mode 100644
index 0000000..4777cb3
--- /dev/null
+++ b/flake.lock
@@ -0,0 +1,41 @@
+{
+ "nodes": {
+ "flake-utils": {
+ "locked": {
+ "lastModified": 1638122382,
+ "narHash": "sha256-sQzZzAbvKEqN9s0bzWuYmRaA03v40gaJ4+iL1LXjaeI=",
+ "owner": "numtide",
+ "repo": "flake-utils",
+ "rev": "74f7e4319258e287b0f9cb95426c9853b282730b",
+ "type": "github"
+ },
+ "original": {
+ "owner": "numtide",
+ "repo": "flake-utils",
+ "type": "github"
+ }
+ },
+ "nixpkgs": {
+ "locked": {
+ "lastModified": 1641076644,
+ "narHash": "sha256-4x90qQM4wOfPAzdMnN1BnzVp7eO6wle+F5NmVkJ48qM=",
+ "owner": "NixOS",
+ "repo": "nixpkgs",
+ "rev": "0fd74961da9fe2640ad2fbd960c3af08246e6749",
+ "type": "github"
+ },
+ "original": {
+ "id": "nixpkgs",
+ "type": "indirect"
+ }
+ },
+ "root": {
+ "inputs": {
+ "flake-utils": "flake-utils",
+ "nixpkgs": "nixpkgs"
+ }
+ }
+ },
+ "root": "root",
+ "version": 7
+}
diff --git a/flake.nix b/flake.nix
new file mode 100644
index 0000000..30f1a38
--- /dev/null
+++ b/flake.nix
@@ -0,0 +1,13 @@
+{
+ description = "Turris flake";
+
+ inputs.flake-utils.url = "github:numtide/flake-utils";
+
+ outputs = { self, nixpkgs, flake-utils }:
+ flake-utils.lib.eachSystem flake-utils.lib.allSystems (system: rec {
+ packages = import ./pkgs {
+ nixlib = nixpkgs.lib;
+ nixpkgs = nixpkgs.legacyPackages.${system};
+ };
+ });
+}
diff --git a/pkgs/default.nix b/pkgs/default.nix
index 576da5b..ea787f4 100644
--- a/pkgs/default.nix
+++ b/pkgs/default.nix
@@ -1,8 +1,8 @@
-{ nixpkgs ? import <nixpkgs> {}}:
+{ nixlib, nixpkgs }:
let
pkgs = nixpkgs // turrispkgs;
- callPackage = pkgs.lib.callPackageWith pkgs;
+ callPackage = nixlib.callPackageWith pkgs;
turrispkgs = with pkgs; {
bootstrapHook = callPackage (