added netdata
This commit is contained in:
parent
54c81c7ccf
commit
e16ccb1ac1
4 changed files with 31 additions and 3 deletions
|
@ -2,9 +2,10 @@
|
|||
conf = {
|
||||
ssh.enable = true;
|
||||
nginx.enable = true;
|
||||
netdata.enable = true;
|
||||
mail.enable = false; # broken
|
||||
website.enable = true;
|
||||
fedi.enable = true; # broken
|
||||
fedi.enable = true;
|
||||
matrix.enable = true;
|
||||
git.enable = true;
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@ in {
|
|||
./layout
|
||||
./mail
|
||||
./matrix
|
||||
./netdata
|
||||
./networking
|
||||
./nginx
|
||||
./niri
|
||||
|
|
25
modules/netdata/default.nix
Normal file
25
modules/netdata/default.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{ lib, pkgs, config, ... }: let
|
||||
inherit (lib) mkIf;
|
||||
inherit (config) conf;
|
||||
in mkIf conf.netdata.enable {
|
||||
services.nginx = {
|
||||
virtualHosts = {
|
||||
"netdata.twoneis.site" = {
|
||||
useACMEHost = "twoneis.site";
|
||||
forceSSL = true;
|
||||
locations."/".proxyPass = "http://localhost:19999";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
services.netdata = {
|
||||
enable = true;
|
||||
package = pkgs.netdata.override { withCloudUI = true; };
|
||||
config = {
|
||||
global = {
|
||||
"memory mode" = "ram";
|
||||
"error log" = "syslog";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -17,9 +17,10 @@ in {
|
|||
|
||||
# Generally server options
|
||||
ssh.enable = mkEnableOption "Install my public key to allow accessing this machine via ssh.";
|
||||
nginx.enable = mkEnableOption "Enable nginx.";
|
||||
nginx.enable = mkEnableOption "Enable nginx. All the following options expect this to be enabled.";
|
||||
netdata.enable = mkEnableOption "Enable netdata metrics tool.";
|
||||
mail.enable = mkEnableOption "Enable mail server.";
|
||||
website.enable = mkEnableOption "Serve website through nginx. Nginx must be enabled to work correctly.";
|
||||
website.enable = mkEnableOption "Serve website through nginx.";
|
||||
fedi.enable = mkEnableOption "Host a fedi server on this machine.";
|
||||
matrix.enable = mkEnableOption "Host a matrix server on this machine.";
|
||||
git.enable = mkEnableOption "Host a git server on this machine.";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue