This repository has been archived by the owner on Oct 7, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
52 lines (44 loc) · 1.72 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{
description = "waasabi flake";
inputs.nixpkgs.url = "nixpkgs/nixos-unstable-small";
inputs.flake-utils.url = "github:numtide/flake-utils";
inputs.napalm.url = "github:nix-community/napalm";
inputs.napalm.inputs.nixpkgs.follows = "nixpkgs";
inputs.strapi-src.url = "github:strapi/strapi/v3.6.8";
inputs.strapi-src.flake = false;
inputs.template-src.url = "github:baytechc/strapi-template-waasabi";
inputs.template-src.flake = false;
inputs.frontend-src.url = "github:baytechc/waasabi-live";
inputs.frontend-src.flake = false;
outputs = { self, nixpkgs, flake-utils, napalm, strapi-src, template-src, frontend-src }:
flake-utils.lib.eachDefaultSystem
(system:
let
pkgs = import nixpkgs { inherit system; overlays = [ napalm.overlay self.overlay ]; };
in
{
packages = {
inherit (pkgs) create-strapi-app waasabi-backend waasabi-backend-pin waasabi-live;
};
})
// {
overlay = final: prev:
let
strapiWorkspace = final.callPackage ./packages/strapi { inherit strapi-src; };
in
{
esbuild-0_12_9 = final.callPackage ./packages/esbuild-0.12.9 { };
inherit (strapiWorkspace) create-strapi-app;
waasabi-backend = final.callPackage ./packages/waasabi-backend { inherit template-src; };
waasabi-backend-pin = final.callPackage ./packages/waasabi-backend-pin { inherit template-src; };
waasabi-live = final.callPackage ./packages/waasabi-live { inherit frontend-src; };
} // (napalm.overlay final prev);
nixosModule = { ... }:
{
imports = builtins.attrValues self.nixosModules;
};
nixosModules = {
waasabi-live = import ./modules/waasabi-live.nix;
};
};
}