kubernetes-models
Version:
69 lines (68 loc) • 2.01 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.addSchema = void 0;
const validate_1 = require("@kubernetes-models/validate");
const IoK8sApiDiscoveryV1Endpoint_1 = require("./IoK8sApiDiscoveryV1Endpoint.js");
const IoK8sApimachineryPkgApisMetaV1ObjectMeta_1 = require("@kubernetes-models/apimachinery/_schemas/IoK8sApimachineryPkgApisMetaV1ObjectMeta");
const IoK8sApiDiscoveryV1EndpointPort_1 = require("./IoK8sApiDiscoveryV1EndpointPort.js");
const schema = {
"properties": {
"addressType": {
"enum": [
"FQDN",
"IPv4",
"IPv6"
],
"type": "string"
},
"apiVersion": {
"type": "string",
"enum": [
"discovery.k8s.io/v1"
]
},
"endpoints": {
"items": {
"$ref": "io.k8s.api.discovery.v1.Endpoint#"
},
"type": "array"
},
"kind": {
"type": "string",
"enum": [
"EndpointSlice"
]
},
"metadata": {
"oneOf": [
{
"$ref": "io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta#"
},
{
"type": "null"
}
]
},
"ports": {
"items": {
"$ref": "io.k8s.api.discovery.v1.EndpointPort#"
},
"type": "array",
"nullable": true
}
},
"required": [
"addressType",
"endpoints",
"apiVersion",
"kind"
],
"type": "object"
};
function addSchema() {
(0, IoK8sApiDiscoveryV1Endpoint_1.addSchema)();
(0, IoK8sApimachineryPkgApisMetaV1ObjectMeta_1.addSchema)();
(0, IoK8sApiDiscoveryV1EndpointPort_1.addSchema)();
(0, validate_1.register)("io.k8s.api.discovery.v1.EndpointSlice", schema);
}
exports.addSchema = addSchema;