Skip to content

Statistics Channels

StatisticsChannelsBlock pydantic-model

Bases: BindBaseModel

Statistics channels configuration block for BIND.

Grammar:

statistics-channels {
    inet ( <ipv4_address> | <ipv6_address> | * )
          [ port ( <integer> | * ) ]
          [ allow { <address_match_element>; ... } ]; // may occur multiple times
}; // may occur multiple times

Show JSON schema:
{
  "$defs": {
    "InetChannel": {
      "description": "Single inet channel configuration for statistics-channels.\n\nGrammar:\n```\ninet ( <ipv4_address> | <ipv6_address> | * )\n      [ port ( <integer> | * ) ]\n      [ allow { <address_match_element>; ... } ];\n```",
      "properties": {
        "comment": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "description": "Optional comment for this block",
          "title": "Comment"
        },
        "address": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "format": "ipv4",
              "type": "string"
            },
            {
              "format": "ipv6",
              "type": "string"
            },
            {
              "enum": [
                "*",
                "::"
              ],
              "type": "string"
            }
          ],
          "description": "IP address to listen on (* for IPv4 wildcard, :: for IPv6 wildcard)",
          "title": "Address"
        },
        "port": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "description": "Port to listen on (default: 80)",
          "title": "Port"
        },
        "allow": {
          "anyOf": [
            {
              "items": {},
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "default": null,
          "description": "Access control list for this channel",
          "title": "Allow"
        }
      },
      "required": [
        "address"
      ],
      "title": "InetChannel",
      "type": "object"
    }
  },
  "description": "Statistics channels configuration block for BIND.\n\nGrammar:\n```\nstatistics-channels {\n    inet ( <ipv4_address> | <ipv6_address> | * )\n          [ port ( <integer> | * ) ]\n          [ allow { <address_match_element>; ... } ]; // may occur multiple times\n}; // may occur multiple times\n```",
  "properties": {
    "comment": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional comment for this block",
      "title": "Comment"
    },
    "channels": {
      "description": "List of inet channels",
      "items": {
        "$ref": "#/$defs/InetChannel"
      },
      "title": "Channels",
      "type": "array"
    }
  },
  "title": "StatisticsChannelsBlock",
  "type": "object"
}

Fields:

Validators:

channels pydantic-field

channels: list[InetChannel]

List of inet channels

validate_channels pydantic-validator

validate_channels() -> StatisticsChannelsBlock

Validate that at least one channel is specified.

InetChannel pydantic-model

Bases: BindBaseModel

Single inet channel configuration for statistics-channels.

Grammar:

inet ( <ipv4_address> | <ipv6_address> | * )
      [ port ( <integer> | * ) ]
      [ allow { <address_match_element>; ... } ];

Show JSON schema:
{
  "description": "Single inet channel configuration for statistics-channels.\n\nGrammar:\n```\ninet ( <ipv4_address> | <ipv6_address> | * )\n      [ port ( <integer> | * ) ]\n      [ allow { <address_match_element>; ... } ];\n```",
  "properties": {
    "comment": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Optional comment for this block",
      "title": "Comment"
    },
    "address": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "format": "ipv4",
          "type": "string"
        },
        {
          "format": "ipv6",
          "type": "string"
        },
        {
          "enum": [
            "*",
            "::"
          ],
          "type": "string"
        }
      ],
      "description": "IP address to listen on (* for IPv4 wildcard, :: for IPv6 wildcard)",
      "title": "Address"
    },
    "port": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Port to listen on (default: 80)",
      "title": "Port"
    },
    "allow": {
      "anyOf": [
        {
          "items": {},
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "description": "Access control list for this channel",
      "title": "Allow"
    }
  },
  "required": [
    "address"
  ],
  "title": "InetChannel",
  "type": "object"
}

Fields:

address pydantic-field

address: (
    ip_v4_address_BIND
    | ip_v6_address_BIND
    | Literal["*", "::"]
)

IP address to listen on (* for IPv4 wildcard, :: for IPv6 wildcard)

port pydantic-field

port: port_BIND | None = None

Port to listen on (default: 80)

allow pydantic-field

allow: address_match_list_BIND | None = None

Access control list for this channel