ResourceList#

pydantic model phalanx.models.kubernetes.ResourceList#

A list of resources returned from a kubectl command.

Parameters:

data (Any)

Show JSON schema
{
   "title": "ResourceList",
   "description": "A list of resources returned from a kubectl command.",
   "type": "object",
   "properties": {
      "items": {
         "items": {
            "$ref": "#/$defs/Resource"
         },
         "title": "Items",
         "type": "array"
      },
      "kind": {
         "const": "List",
         "title": "Kind",
         "type": "string"
      }
   },
   "$defs": {
      "Condition": {
         "description": "A Kubernetes condition.",
         "properties": {
            "type": {
               "title": "Type",
               "type": "string"
            },
            "status": {
               "$ref": "#/$defs/ConditionStatus"
            }
         },
         "required": [
            "type",
            "status"
         ],
         "title": "Condition",
         "type": "object"
      },
      "ConditionStatus": {
         "description": "Valid values for the spec.type field of a Service.",
         "enum": [
            "True",
            "False",
            "Unknown"
         ],
         "title": "ConditionStatus",
         "type": "string"
      },
      "Resource": {
         "description": "Properties common to all Kubernetes resources.",
         "properties": {
            "kind": {
               "title": "Kind",
               "type": "string"
            },
            "name": {
               "title": "Name",
               "type": "string"
            },
            "finalizers": {
               "default": [],
               "items": {
                  "type": "string"
               },
               "title": "Finalizers",
               "type": "array"
            },
            "status": {
               "anyOf": [
                  {
                     "$ref": "#/$defs/Status"
                  },
                  {
                     "type": "null"
                  }
               ],
               "default": null
            }
         },
         "required": [
            "kind",
            "name"
         ],
         "title": "Resource",
         "type": "object"
      },
      "Status": {
         "description": "The status field of a Kubernetes resource.",
         "properties": {
            "conditions": {
               "default": [],
               "items": {
                  "$ref": "#/$defs/Condition"
               },
               "title": "Conditions",
               "type": "array"
            }
         },
         "title": "Status",
         "type": "object"
      }
   },
   "required": [
      "items",
      "kind"
   ]
}

Fields:
field items: list[TypeVar(T, bound= Resource)] [Required]#

A list of Kubernetes resources.

field kind: Literal['List'] [Required]#

The kind field will always be List.