Compare commits
No commits in common. "main" and "cleanup" have entirely different histories.
|
@ -4,11 +4,8 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
flake = "git+https://git.pvv.ntnu.no/Drift/pvv-nixos-config.git";
|
flake = "git+https://git.pvv.ntnu.no/Drift/pvv-nixos-config.git";
|
||||||
flags = [
|
flags = [
|
||||||
# --update-input is deprecated since nix 2.22, and removed in lix 2.90
|
"--update-input" "nixpkgs"
|
||||||
# https://git.lix.systems/lix-project/lix/issues/400
|
"--update-input" "nixpkgs-unstable"
|
||||||
"--refresh"
|
|
||||||
"--override-input" "nixpkgs" "github:nixos/nixpkgs/nixos-24.05-small"
|
|
||||||
"--override-input" "nixpkgs-unstable" "github:nixos/nixpkgs/nixos-unstable-small"
|
|
||||||
"--no-write-lock-file"
|
"--no-write-lock-file"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
10
flake.lock
10
flake.lock
|
@ -166,10 +166,9 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "NixOS",
|
"id": "nixpkgs",
|
||||||
"ref": "nixos-24.05-small",
|
"ref": "nixos-24.05-small",
|
||||||
"repo": "nixpkgs",
|
"type": "indirect"
|
||||||
"type": "github"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs-stable": {
|
"nixpkgs-stable": {
|
||||||
|
@ -198,10 +197,9 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "NixOS",
|
"id": "nixpkgs",
|
||||||
"ref": "nixos-unstable-small",
|
"ref": "nixos-unstable-small",
|
||||||
"repo": "nixpkgs",
|
"type": "indirect"
|
||||||
"type": "github"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"pvv-calendar-bot": {
|
"pvv-calendar-bot": {
|
||||||
|
|
|
@ -2,8 +2,8 @@
|
||||||
description = "PVV System flake";
|
description = "PVV System flake";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05-small"; # remember to also update the url in base/services/auto-upgrade.nix
|
nixpkgs.url = "nixpkgs/nixos-24.05-small";
|
||||||
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable-small";
|
nixpkgs-unstable.url = "nixpkgs/nixos-unstable-small";
|
||||||
|
|
||||||
sops-nix.url = "github:Mic92/sops-nix";
|
sops-nix.url = "github:Mic92/sops-nix";
|
||||||
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
|
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
|
|
@ -55,11 +55,6 @@ in {
|
||||||
USER = "gitea@pvv.ntnu.no";
|
USER = "gitea@pvv.ntnu.no";
|
||||||
SUBJECT_PREFIX = "[pvv-git]";
|
SUBJECT_PREFIX = "[pvv-git]";
|
||||||
};
|
};
|
||||||
metrics = {
|
|
||||||
ENABLED = true;
|
|
||||||
ENABLED_ISSUE_BY_LABEL = true;
|
|
||||||
ENABLED_ISSUE_BY_REPOSITORY = true;
|
|
||||||
};
|
|
||||||
indexer.REPO_INDEXER_ENABLED = true;
|
indexer.REPO_INDEXER_ENABLED = true;
|
||||||
service = {
|
service = {
|
||||||
DISABLE_REGISTRATION = true;
|
DISABLE_REGISTRATION = true;
|
||||||
|
@ -114,20 +109,11 @@ in {
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
kTLS = true;
|
kTLS = true;
|
||||||
locations = {
|
locations."/" = {
|
||||||
"/" = {
|
proxyPass = "http://unix:${cfg.settings.server.HTTP_ADDR}";
|
||||||
proxyPass = "http://unix:${cfg.settings.server.HTTP_ADDR}";
|
extraConfig = ''
|
||||||
extraConfig = ''
|
client_max_body_size 512M;
|
||||||
client_max_body_size 512M;
|
'';
|
||||||
'';
|
|
||||||
};
|
|
||||||
"/metrics" = {
|
|
||||||
proxyPass = "http://unix:${cfg.settings.server.HTTP_ADDR}";
|
|
||||||
extraConfig = ''
|
|
||||||
allow ${values.hosts.ildkule.ipv4}/32;
|
|
||||||
deny all;
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -75,12 +75,6 @@ in {
|
||||||
url = "https://grafana.com/api/dashboards/240/revisions/3/download";
|
url = "https://grafana.com/api/dashboards/240/revisions/3/download";
|
||||||
options.path = dashboards/go-processes.json;
|
options.path = dashboards/go-processes.json;
|
||||||
}
|
}
|
||||||
{
|
|
||||||
name = "Gitea Dashbaord";
|
|
||||||
type = "file";
|
|
||||||
url = "https://grafana.com/api/dashboards/17802/revisions/3/download";
|
|
||||||
options.path = dashboards/gitea-dashbaord.json;
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{ config, ... }: {
|
{ config, ... }: {
|
||||||
imports = [
|
imports = [
|
||||||
./gitea.nix
|
./gogs.nix
|
||||||
./matrix-synapse.nix
|
./matrix-synapse.nix
|
||||||
# TODO: enable once https://github.com/NixOS/nixpkgs/pull/242365 gets merged
|
# TODO: enable once https://github.com/NixOS/nixpkgs/pull/242365 gets merged
|
||||||
# ./mysqld.nix
|
# ./mysqld.nix
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
services.prometheus.scrapeConfigs = [{
|
|
||||||
job_name = "gitea";
|
|
||||||
scrape_interval = "60s";
|
|
||||||
scheme = "https";
|
|
||||||
|
|
||||||
static_configs = [
|
|
||||||
{
|
|
||||||
targets = [
|
|
||||||
"git.pvv.ntnu.no:443"
|
|
||||||
];
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}];
|
|
||||||
}
|
|
|
@ -0,0 +1,16 @@
|
||||||
|
{ config, ... }: let
|
||||||
|
cfg = config.services.prometheus;
|
||||||
|
in {
|
||||||
|
services.prometheus.scrapeConfigs = [{
|
||||||
|
job_name = "git-gogs";
|
||||||
|
scheme = "https";
|
||||||
|
metrics_path = "/-/metrics";
|
||||||
|
static_configs = [
|
||||||
|
{
|
||||||
|
targets = [
|
||||||
|
"essendrop.pvv.ntnu.no:443"
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}];
|
||||||
|
}
|
Loading…
Reference in New Issue