UNPKG

@soft-stech/spiffe

Version:
160 lines (159 loc) 5.06 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.SpiffeID = void 0; const IoK8sApimachineryPkgApisMetaV1ObjectMeta_1 = require("@soft-stech/apimachinery/_schemas/IoK8sApimachineryPkgApisMetaV1ObjectMeta"); const base_1 = require("@soft-stech/base"); const validate_1 = require("@soft-stech/validate"); const schemaId = "spiffeid.spiffe.io.v1beta1.SpiffeID"; const schema = { "type": "object", "properties": { "apiVersion": { "type": "string", "enum": [ "spiffeid.spiffe.io/v1beta1" ] }, "kind": { "type": "string", "enum": [ "SpiffeID" ] }, "metadata": { "oneOf": [ { "$ref": "io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta#" }, { "type": "null" } ] }, "spec": { "properties": { "dnsNames": { "items": { "type": "string" }, "type": "array", "nullable": true }, "federatesWith": { "items": { "type": "string" }, "type": "array", "nullable": true }, "parentId": { "type": "string" }, "downstream": { "type": "boolean", "nullable": true }, "selector": { "properties": { "arbitrary": { "items": { "type": "string" }, "type": "array", "nullable": true }, "containerImage": { "type": "string", "nullable": true }, "containerName": { "type": "string", "nullable": true }, "namespace": { "type": "string", "nullable": true }, "nodeName": { "type": "string", "nullable": true }, "podLabel": { "additionalProperties": { "type": "string" }, "type": "object", "properties": {}, "nullable": true }, "podName": { "type": "string", "nullable": true }, "podUid": { "type": "string", "nullable": true }, "serviceAccount": { "type": "string", "nullable": true }, "cluster": { "type": "string", "nullable": true }, "agent_node_uid": { "type": "string", "nullable": true } }, "type": "object" }, "spiffeId": { "type": "string" } }, "required": [ "parentId", "selector", "spiffeId" ], "type": "object", "nullable": true }, "status": { "properties": { "entryId": { "type": "string", "nullable": true } }, "type": "object", "nullable": true } }, "required": [ "apiVersion", "kind" ] }; /** * SpiffeID is the Schema for the spiffeid API */ class SpiffeID extends base_1.Model { constructor(data) { super({ apiVersion: SpiffeID.apiVersion, kind: SpiffeID.kind, ...data }); } } exports.SpiffeID = SpiffeID; SpiffeID.apiVersion = "spiffeid.spiffe.io/v1beta1"; SpiffeID.kind = "SpiffeID"; SpiffeID.is = (0, base_1.createTypeMetaGuard)(SpiffeID); (0, base_1.setSchema)(SpiffeID, schemaId, () => { (0, IoK8sApimachineryPkgApisMetaV1ObjectMeta_1.addSchema)(); (0, validate_1.register)(schemaId, schema); });