UNPKG

@luminati-io/kubernetes-models-fluent-operator

Version:
196 lines (195 loc) 6.84 kB
import { addSchema } from "@kubernetes-models/apimachinery/_schemas/IoK8sApimachineryPkgApisMetaV1ObjectMeta"; import { Model, setSchema, createTypeMetaGuard } from "@kubernetes-models/base"; import { register } from "@kubernetes-models/validate"; const schemaId = "fluentd.fluent.io.v1alpha1.ClusterFluentdConfig"; const schema = { "type": "object", "properties": { "apiVersion": { "type": "string", "enum": [ "fluentd.fluent.io/v1alpha1" ] }, "kind": { "type": "string", "enum": [ "ClusterFluentdConfig" ] }, "metadata": { "oneOf": [ { "$ref": "io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta#" }, { "type": "null" } ] }, "spec": { "properties": { "clusterFilterSelector": { "properties": { "matchExpressions": { "items": { "properties": { "key": { "type": "string" }, "operator": { "type": "string" }, "values": { "items": { "type": "string" }, "type": "array", "nullable": true } }, "required": [ "key", "operator" ], "type": "object" }, "type": "array", "nullable": true }, "matchLabels": { "additionalProperties": { "type": "string" }, "type": "object", "properties": {}, "nullable": true } }, "type": "object", "nullable": true }, "clusterOutputSelector": { "properties": { "matchExpressions": { "items": { "properties": { "key": { "type": "string" }, "operator": { "type": "string" }, "values": { "items": { "type": "string" }, "type": "array", "nullable": true } }, "required": [ "key", "operator" ], "type": "object" }, "type": "array", "nullable": true }, "matchLabels": { "additionalProperties": { "type": "string" }, "type": "object", "properties": {}, "nullable": true } }, "type": "object", "nullable": true }, "emit_mode": { "enum": [ "record", "batch" ], "type": "string", "nullable": true }, "stickyTags": { "type": "string", "nullable": true }, "watchedConstainers": { "items": { "type": "string" }, "type": "array", "nullable": true }, "watchedHosts": { "items": { "type": "string" }, "type": "array", "nullable": true }, "watchedLabels": { "additionalProperties": { "type": "string" }, "type": "object", "properties": {}, "nullable": true }, "watchedNamespaces": { "items": { "type": "string" }, "type": "array", "nullable": true } }, "type": "object", "nullable": true }, "status": { "properties": { "messages": { "type": "string", "nullable": true }, "state": { "type": "string", "nullable": true } }, "type": "object", "nullable": true } }, "required": [ "apiVersion", "kind" ] }; /** * ClusterFluentdConfig is the Schema for the clusterfluentdconfigs API */ export class ClusterFluentdConfig extends Model { constructor(data) { super({ apiVersion: ClusterFluentdConfig.apiVersion, kind: ClusterFluentdConfig.kind, ...data }); } } ClusterFluentdConfig.apiVersion = "fluentd.fluent.io/v1alpha1"; ClusterFluentdConfig.kind = "ClusterFluentdConfig"; ClusterFluentdConfig.is = createTypeMetaGuard(ClusterFluentdConfig); setSchema(ClusterFluentdConfig, schemaId, () => { addSchema(); register(schemaId, schema); });