summary refs log tree commit diff
path: root/nixos/modules/services/monitoring/prometheus/default.nix
diff options
context:
space:
mode:
authorJörg Thalheim <joerg@thalheim.io>2021-11-11 11:41:13 +0100
committerJörg Thalheim <joerg@thalheim.io>2022-01-03 12:04:08 +0100
commitfd0a6311a7871e50a2728d17de490809df3227d8 (patch)
tree139d9cd71c7dc34ab16722e302ece3fd790dde9a /nixos/modules/services/monitoring/prometheus/default.nix
parent4e6a72bf730837a1d5cbe1b04f8e5bc71eb60342 (diff)
downloadnixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.tar
nixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.tar.gz
nixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.tar.bz2
nixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.tar.lz
nixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.tar.xz
nixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.tar.zst
nixpkgs-fd0a6311a7871e50a2728d17de490809df3227d8.zip
prometheus: add authorization section
Diffstat (limited to 'nixos/modules/services/monitoring/prometheus/default.nix')
-rw-r--r--nixos/modules/services/monitoring/prometheus/default.nix7
1 files changed, 7 insertions, 0 deletions
diff --git a/nixos/modules/services/monitoring/prometheus/default.nix b/nixos/modules/services/monitoring/prometheus/default.nix
index f20b8dde1ab..b36b5fd0650 100644
--- a/nixos/modules/services/monitoring/prometheus/default.nix
+++ b/nixos/modules/services/monitoring/prometheus/default.nix
@@ -251,6 +251,13 @@ let
 
   promTypes.scrape_config = types.submodule {
     options = {
+      authorization = mkOption {
+        type = types.attrs;
+        default = {};
+        description = ''
+          Sets the `Authorization` header on every scrape request with the configured credentials.
+        '';
+      };
       job_name = mkOption {
         type = types.str;
         description = ''