mirror of
https://github.com/anotherhadi/nixy.git
synced 2026-04-02 11:12:09 +02:00
testing eleakxir prod
Signed-off-by: Hadi <112569860+anotherhadi@users.noreply.github.com>
This commit is contained in:
@@ -34,6 +34,10 @@
|
|||||||
url = "github:abenz1267/walker";
|
url = "github:abenz1267/walker";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
eleakxir = {
|
||||||
|
url = "github:anotherhadi/eleakxir-temp";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs @ {nixpkgs, ...}: {
|
outputs = inputs @ {nixpkgs, ...}: {
|
||||||
@@ -61,6 +65,7 @@
|
|||||||
inputs.sops-nix.nixosModules.sops
|
inputs.sops-nix.nixosModules.sops
|
||||||
inputs.nixarr.nixosModules.default
|
inputs.nixarr.nixosModules.default
|
||||||
inputs.search-nixos-api.nixosModules.search-nixos-api
|
inputs.search-nixos-api.nixosModules.search-nixos-api
|
||||||
|
inputs.eleakxir.nixosModules.eleakxir-backend
|
||||||
./hosts/server/configuration.nix
|
./hosts/server/configuration.nix
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -31,6 +31,7 @@
|
|||||||
just
|
just
|
||||||
pnpm
|
pnpm
|
||||||
wireguard-tools
|
wireguard-tools
|
||||||
|
duckdb
|
||||||
|
|
||||||
# Utils
|
# Utils
|
||||||
zip
|
zip
|
||||||
|
|||||||
37
server-modules/eleakxir.nix
Normal file
37
server-modules/eleakxir.nix
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
{
|
||||||
|
inputs,
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
services.eleakxir-backend = {
|
||||||
|
enable = true;
|
||||||
|
port = 8080;
|
||||||
|
leakPath = "/mnt/ssd/leaks";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx = {
|
||||||
|
virtualHosts."eleakxir.hadi.diy" = {
|
||||||
|
useACMEHost = "hadi.diy";
|
||||||
|
forceSSL = true;
|
||||||
|
|
||||||
|
root = "${
|
||||||
|
inputs.socme.packages.${pkgs.system}.eleakxir-frontend
|
||||||
|
}/eleakxir-frontend";
|
||||||
|
|
||||||
|
locations."/api/" = {
|
||||||
|
proxyPass = "http://127.0.0.1:${toString config.services.eleakxir-backend.port}/";
|
||||||
|
recommendedProxySettings = true;
|
||||||
|
extraConfig = ''
|
||||||
|
rewrite ^/api/(.*) /$1 break;
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
locations."/" = {
|
||||||
|
extraConfig = ''
|
||||||
|
try_files $uri $uri/ /index.html =404; # Fallback vers index.html pour les routes SPA
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user