anchor.diff:      };
     };
   
  +  promTypes.kubernetes_sd_config = mkSdConfigModule {
  +    api_server = mkOpt types.str ''
  +      The API server addresses. If left empty, Prometheus is assumed to run inside
  +      of the cluster and will discover API servers automatically and use the pod's
  +      CA certificate and bearer token file at /var/run/secrets/kubernetes.io/serviceaccount/.
  +    '';
  +
  +    role = mkOption {
  +      type = types.enum [ "endpoints" "service" "pod" "node" "ingress" ];
  +      description = ''
  +        The Kubernetes role of entities that should be discovered.
  +        One of endpoints, service, pod, node, or ingress.
  +      '';
  +    };
  +
  +    kubeconfig_file = mkOpt types.str ''
  +      Optional path to a kubeconfig file.
  +      Note that api_server and kube_config are mutually exclusive.
  +    '';
  +
  +    namespaces = mkOpt
  +      (
  +        types.submodule {
  +          options = {
  +            names = mkOpt (types.listOf types.str) ''
  +              Namespace name.
  +            '';
  +          };
  +        }
  +      ) ''
  +      Optional namespace discovery. If omitted, all namespaces are used.
  +    '';
  +
  +    selectors = mkOpt
  +      (
  +        types.listOf (
  +          types.submodule {
  +            options = {
  +              role = mkOption {
  +                type = types.str;
  +                description = ''
  +                  Selector role
  +                '';
  +              };
  +
  +              label = mkOpt types.str ''
  +                Selector label
  +              '';
  +
  +              field = mkOpt types.str ''
  +                Selector field
  +              '';
  +            };
  +          }
  +        )
  +      ) ''
  +      Optional label and field selectors to limit the discovery process to a subset of available resources.
  +      See https://kubernetes.io/docs/concepts/overview/working-with-objects/field-selectors/
  +      and https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ to learn more about the possible
  +      filters that can be used. Endpoints role supports pod, service and endpoints selectors, other roles
  +      only support selectors matching the role itself (e.g. node role can only contain node selectors).
  +
  +      Note: When making decision about using field/label selector make sure that this
  +      is the best approach - it will prevent Prometheus from reusing single list/watch
  +      for all scrape configs. This might result in a bigger load on the Kubernetes API,
  +      because per each selector combination there will be additional LIST/WATCH. On the other hand,
  +      if you just want to monitor small subset of pods in large cluster it's recommended to use selectors.
  +      Decision, if selectors should be used or not depends on the particular situation.
  +    '';
  +  };
  +
     promTypes.kuma_sd_config = mkSdConfigModule {
       server = mkOption {
         type = types.str;
  
positive.code:         List of AirBnB's Nerve service discovery configurations.
        '';
  
        # openstack_sd_configs
        # scaleway_sd_configs
  
        serverset_sd_configs = mkOpt (types.listOf promTypes.serverset_sd_config) ''
          List of Zookeeper Serverset service discovery configurations.
        '';
  
        # triton_sd_configs
  
        static_configs = mkOpt (types.listOf promTypes.static_config) ''
          List of labeled target groups for this job.
  
negative.code:     };
      systemd.services.prometheus = {
        wantedBy = [ "multi-user.target" ];
        after = [ "network.target" ];
        preStart = mkIf (!cfg.enableReload) ''
          ${lib.getBin pkgs.envsubst}/bin/envsubst -o "/run/prometheus/prometheus-substituted.yaml" \
                                                   -i "${prometheusYml}"
  