From f9b211fd9f6c50b14c91684b783f39e100f7a1de Mon Sep 17 00:00:00 2001 From: Astro Date: Mon, 8 Mar 2021 23:11:40 +0100 Subject: [PATCH] flake.nix: init --- flake.lock | 25 +++++++++++++++++++++++++ flake.nix | 25 +++++++++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..c998484 --- /dev/null +++ b/flake.lock @@ -0,0 +1,25 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1615240472, + "narHash": "sha256-m7r5+yFuJr+Seoynd06jnfcV3UTHNcFLmsqK3jQGU8E=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "fab58377abea3fb53c5781cff510d908ea23e92c", + "type": "github" + }, + "original": { + "id": "nixpkgs", + "type": "indirect" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..759a049 --- /dev/null +++ b/flake.nix @@ -0,0 +1,25 @@ +{ + description = "Ticker calendar aggregator"; + + outputs = { self, nixpkgs }: + let + systems = [ "x86_64-linux" "i686-linux" "aarch64-linux" ]; + forSystems = nixpkgs.lib.genAttrs systems; + in { + packages = forSystems (system: + import ./default.nix { + pkgs = nixpkgs.legacyPackages.${system}; + } + ); + + defaultPackage = forSystems (system: + self.packages.${system}.ticker-serve + ); + + devShell = import ./shell.nix { + pkgs = nixpkgs.legacyPackages.x86_64-linux; + }; + + nixosModule = import ./nixos-module; + }; +}