flake: add testing target with localhost as url
This commit is contained in:
parent
b15b3c9ebf
commit
fa5dd946de
15
flake.nix
15
flake.nix
@ -13,12 +13,12 @@
|
||||
supportedSystems = ["x86_64-linux" "aarch64-linux"];
|
||||
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
|
||||
pkgs = forAllSystems (system: nixpkgs.legacyPackages.${system});
|
||||
url = "https://project-cloud.net";
|
||||
url_deploy = "https://project-cloud.net";
|
||||
url_local = "http://localhost:8080";
|
||||
name = "project-cloud";
|
||||
theme = theme_anemone;
|
||||
in {
|
||||
packages = forAllSystems (system: {
|
||||
default = pkgs.${system}.stdenv.mkDerivation {
|
||||
package = system: url:
|
||||
pkgs.${system}.stdenv.mkDerivation {
|
||||
inherit name;
|
||||
nativeBuildInputs = with pkgs.${system}; [zola];
|
||||
|
||||
@ -35,11 +35,16 @@
|
||||
cp -r public/ $out/
|
||||
'';
|
||||
};
|
||||
in {
|
||||
packages = forAllSystems (system: rec {
|
||||
project-cloud = package system url_deploy;
|
||||
test = package system url_local;
|
||||
default = project-cloud;
|
||||
});
|
||||
|
||||
devShells = forAllSystems (system: {
|
||||
default = pkgs.${system}.mkShellNoCC {
|
||||
packages = with pkgs.${system}; [zola];
|
||||
packages = with pkgs.${system}; [zola caddy];
|
||||
};
|
||||
});
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user