diff --git a/.gitignore b/.gitignore index 8de3fbd50..6bf96b8b9 100644 --- a/.gitignore +++ b/.gitignore @@ -20,3 +20,4 @@ docs/utils/webpack/node_modules # Local superpowers planning artifacts (specs/plans/notes) — not repo content docs/superpowers/ +examples/ \ No newline at end of file diff --git a/apis/inferenceclasses/definition.yaml b/apis/inferenceclasses/definition.yaml index 433576145..b4b607ba6 100644 --- a/apis/inferenceclasses/definition.yaml +++ b/apis/inferenceclasses/definition.yaml @@ -38,10 +38,12 @@ spec: message: spec.provisioning.gke is required when spec.provisioning.provider is GKE. - rule: "self.provider != 'EKS' || has(self.eks)" message: spec.provisioning.eks is required when spec.provisioning.provider is EKS. + - rule: "self.provider != 'Nebius' || has(self.nebius)" + message: spec.provisioning.nebius is required when spec.provisioning.provider is Nebius. properties: provider: type: string - enum: [GKE, EKS] + enum: [GKE, EKS, Nebius] gke: type: object required: [machineType, accelerator] @@ -110,6 +112,61 @@ spec: type: integer minimum: 1 maximum: 16 + nebius: + type: object + required: [platform, preset, accelerator] + properties: + platform: + type: string + description: >- + Nebius compute platform (e.g. gpu-h100-sxm, + gpu-l40s-a). Together with preset this determines + the GPU model and count; the accelerator block + below is informational. + minLength: 1 + maxLength: 63 + preset: + type: string + description: >- + Resource preset within the platform (e.g. + 8gpu-128vcpu-1600gb). Determines the GPU, vCPU, + and memory shape of each node. + minLength: 1 + maxLength: 63 + diskSizeGb: + type: integer + default: 100 + minimum: 10 + driversPreset: + type: string + default: cuda13.0 + description: >- + NVIDIA driver stack mk8s preinstalls on the pool's + nodes. Valid values depend on the platform and + Kubernetes version. Defaults to the only preset + mk8s implements on the default Kubernetes version; + older presets remain for older versions. + enum: [cuda12, cuda12.4, cuda12.8, cuda13.0] + accelerator: + type: object + description: >- + GPU accelerator to attach when provisioning the node + group. Provisioning input only: the scheduler matches + against spec.devices, not this block. + required: [type, count] + properties: + type: + type: string + description: >- + GPU accelerator type (e.g. nvidia-h100, + nvidia-l40s). Informational - reported on + the consuming InferenceCluster's status. + minLength: 1 + maxLength: 63 + count: + type: integer + minimum: 1 + maximum: 16 devices: type: array description: >- diff --git a/apis/inferenceclusters/definition.yaml b/apis/inferenceclusters/definition.yaml index dc0a13609..ccaf06641 100644 --- a/apis/inferenceclusters/definition.yaml +++ b/apis/inferenceclusters/definition.yaml @@ -40,12 +40,14 @@ spec: message: spec.cluster.gke is required when spec.cluster.source is GKE. - rule: "self.source != 'EKS' || has(self.eks)" message: spec.cluster.eks is required when spec.cluster.source is EKS. + - rule: "self.source != 'Nebius' || has(self.nebius)" + message: spec.cluster.nebius is required when spec.cluster.source is Nebius. properties: source: type: string description: >- Cluster provisioning method. - enum: [GKE, EKS, Existing] + enum: [GKE, EKS, Nebius, Existing] existing: type: object description: >- @@ -153,6 +155,23 @@ spec: EKS cluster Kubernetes version. Defaults to a version where Dynamic Resource Allocation (how GPUs bind to pods) is generally available. + nebius: + type: object + description: >- + Nebius mk8s cluster configuration. Required when source + is Nebius; may be empty, since every field has a + default. The cluster is created in the project the + Nebius ClusterProviderConfig named default sets as its + projectID; Nebius projects are bound to a region, so + the project also determines where the cluster runs. + properties: + kubernetesVersion: + type: string + default: "1.34" + description: >- + mk8s cluster Kubernetes version. Defaults to a + version where Dynamic Resource Allocation (DRA) + is generally available. nodePools: type: array description: >- @@ -224,21 +243,59 @@ spec: minLength: 4 maxLength: 64 fabric: - type: string - default: None + type: object description: >- High-performance node-to-node fabric for multi-node - engines. None uses standard VPC networking (ENA/TCP). - EFA attaches Elastic Fabric Adapter interfaces to each - node for GPUDirect RDMA across nodes, so a gang's - tensor-parallel traffic isn't capped by TCP. EKS only. - Only useful on EFA-capable instance types (e.g. - p5en.48xlarge). When any pool sets EFA, Modelplane - installs the EFA DRA driver on the cluster and the - gang's pods claim EFA devices alongside their GPUs. - enum: - - None - - EFA + engines, so a gang's tensor-parallel traffic isn't + capped by TCP. Omit for standard VPC networking. + x-kubernetes-validations: + - rule: "self.type != 'InfiniBand' || has(self.infiniband)" + message: fabric.infiniband is required when fabric.type is InfiniBand. + - rule: "!has(self.infiniband) || self.type == 'InfiniBand'" + message: fabric.infiniband is only valid when fabric.type is InfiniBand. + properties: + type: + type: string + default: None + description: >- + Fabric technology. None uses standard VPC + networking (TCP). EFA attaches Elastic Fabric + Adapter interfaces to each node for GPUDirect + RDMA across nodes; EKS only, and only useful on + EFA-capable instance types (e.g. p5en.48xlarge). + When any pool sets EFA, Modelplane installs the + EFA DRA driver on the cluster and the gang's pods + claim EFA devices alongside their GPUs. + InfiniBand places the pool's nodes in a GPU + cluster on a physical InfiniBand fabric for + GPUDirect RDMA across nodes; Nebius only, and + only useful on InfiniBand-capable platforms + (e.g. gpu-h100-sxm). + enum: + - None + - EFA + - InfiniBand + infiniband: + type: object + description: >- + InfiniBand fabric configuration. Required when + type is InfiniBand. + required: + - fabric + properties: + fabric: + type: string + description: >- + Identifier of the physical InfiniBand fabric + to join (e.g. fabric-2). This selects existing + Nebius infrastructure, not a name for a new + resource: fabrics are per-region - see + https://docs.nebius.com/compute/clusters/gpu#fabrics + - and multi-node GPU capacity is allocated on + specific fabrics, so use the fabric your + capacity lives on. + minLength: 1 + maxLength: 63 status: type: object properties: diff --git a/apis/nebiusclusters/composition.yaml b/apis/nebiusclusters/composition.yaml new file mode 100644 index 000000000..7104a1a3e --- /dev/null +++ b/apis/nebiusclusters/composition.yaml @@ -0,0 +1,13 @@ +apiVersion: apiextensions.crossplane.io/v1 +kind: Composition +metadata: + name: nebiusclusters.infrastructure.modelplane.ai +spec: + compositeTypeRef: + apiVersion: infrastructure.modelplane.ai/v1alpha1 + kind: NebiusCluster + mode: Pipeline + pipeline: + - functionRef: + name: modelplane-modelplanecompose-nebius-cluster + step: compose-nebius-cluster diff --git a/apis/nebiusclusters/definition.yaml b/apis/nebiusclusters/definition.yaml new file mode 100644 index 000000000..80972f705 --- /dev/null +++ b/apis/nebiusclusters/definition.yaml @@ -0,0 +1,252 @@ +apiVersion: apiextensions.crossplane.io/v2 +kind: CompositeResourceDefinition +metadata: + name: nebiusclusters.infrastructure.modelplane.ai +spec: + group: infrastructure.modelplane.ai + names: + categories: + - crossplane + - modelplane + kind: NebiusCluster + plural: nebiusclusters + shortNames: + - mk8s + scope: Namespaced + versions: + - name: v1alpha1 + referenceable: true + schema: + openAPIV3Schema: + description: >- + A NebiusCluster provisions a Nebius Managed Service for Kubernetes + (mk8s) cluster with dedicated node groups for GPU inference and + system workloads. It outputs a Secret containing the cluster + kubeconfig. The kubeconfig carries only the cluster endpoint and CA + certificate - Nebius clusters authenticate every client through + Nebius IAM - so consumers pair it with the credentials Secret of + the Nebius ClusterProviderConfig named default, the same identity + that provisions the cluster. The cluster is created in the project + that ClusterProviderConfig sets as its projectID; Nebius projects + are bound to a region, so the project also determines where the + cluster runs. + properties: + spec: + description: NebiusClusterSpec defines the desired state of NebiusCluster. + required: + - nodePools + properties: + kubernetesVersion: + type: string + default: "1.34" + description: >- + mk8s cluster Kubernetes version. Must be a version mk8s + currently supports. Defaults to a version where Dynamic + Resource Allocation (how GPUs bind to pods) is generally + available. + minLength: 1 + maxLength: 16 + nodePools: + type: array + description: >- + Node groups for the cluster. At least one System pool is + required for controllers and infrastructure workloads. + minItems: 1 + maxItems: 8 + x-kubernetes-list-type: map + x-kubernetes-list-map-keys: + - name + items: + type: object + required: + - name + - role + - platform + - preset + x-kubernetes-validations: + - rule: "self.role != 'GPU' || has(self.gpu)" + message: gpu is required when role is GPU. + - rule: "!has(self.minNodeCount) || has(self.maxNodeCount)" + message: maxNodeCount is required when minNodeCount is set. + properties: + name: + type: string + description: >- + Unique name for this node group. Used as a suffix + in the mk8s NodeGroup resource name. + maxLength: 40 + minLength: 1 + role: + type: string + description: >- + Determines what workloads this group runs. System + groups host controllers, gateways, and infrastructure. + GPU groups host inference workloads and are tainted to + exclude non-GPU pods. + enum: + - System + - GPU + platform: + type: string + description: >- + Nebius compute platform for the group's nodes (e.g. + gpu-h100-sxm, gpu-l40s-a, cpu-d3). Together with + preset this replaces the instance type used by other + clouds. + minLength: 1 + maxLength: 63 + preset: + type: string + description: >- + Resource preset within the platform (e.g. + 8gpu-128vcpu-1600gb, 4vcpu-16gb). Determines the GPU, + vCPU, and memory shape of each node. + minLength: 1 + maxLength: 63 + diskSizeGb: + type: integer + default: 100 + description: Boot disk size in GB. + minimum: 10 + maximum: 65536 + nodeCount: + type: integer + default: 1 + description: >- + Number of nodes. Fixed unless maxNodeCount enables + autoscaling. + minimum: 0 + maximum: 1000 + minNodeCount: + type: integer + description: >- + Minimum number of nodes for autoscaling. Defaults to + nodeCount when maxNodeCount is set. Requires + maxNodeCount. + minimum: 0 + maximum: 1000 + maxNodeCount: + type: integer + description: >- + Maximum number of nodes for autoscaling. When set the + node group autoscales between minNodeCount (or + nodeCount) and this; mk8s autoscaling is server-side, + no in-cluster autoscaler is installed. Omit for + fixed-size groups - unlike other clouds there is no + default, because mk8s node groups are either fixed + size or autoscaled, never both. + minimum: 1 + maximum: 1000 + gpu: + type: object + description: >- + GPU configuration. Required when role is GPU. + required: + - acceleratorType + properties: + acceleratorType: + type: string + description: >- + GPU accelerator type (e.g. nvidia-h100, + nvidia-l40s). Used to label GPU nodes; the actual + GPU and count are determined by the platform and + preset. + minLength: 1 + maxLength: 63 + driversPreset: + type: string + default: cuda13.0 + description: >- + NVIDIA driver stack mk8s preinstalls on the + group's nodes. Valid values depend on the platform + and Kubernetes version. Defaults to the only + preset mk8s implements on the default Kubernetes + version; older presets remain for older versions. + enum: + - cuda12 + - cuda12.4 + - cuda12.8 + - cuda13.0 + fabric: + type: string + description: >- + Identifier of the physical InfiniBand fabric to join + (e.g. fabric-2), for GPUDirect RDMA across nodes in + multi-node engines. This selects existing Nebius + infrastructure, not a name for a new resource: + fabrics are per-region - see + https://docs.nebius.com/compute/clusters/gpu#fabrics + - and multi-node GPU capacity is allocated on + specific fabrics, so use the fabric your capacity + lives on. When set, Modelplane composes a GPU cluster + on that fabric and places the group's nodes in it. + Only valid on InfiniBand-capable platforms (e.g. + gpu-h100-sxm). Omit for standard VPC networking. + minLength: 1 + maxLength: 63 + type: object + status: + description: NebiusClusterStatus defines the observed state of NebiusCluster. + properties: + secrets: + type: array + description: >- + Secrets produced by or passed through this cluster. + Consumers use these to authenticate to the cluster. Secrets + are in the same namespace as this NebiusCluster unless an + entry says otherwise. + items: + type: object + required: + - type + - name + - key + properties: + type: + type: string + description: >- + The type of credential this secret contains. + Kubeconfig contains a kubeconfig file with the cluster + endpoint and CA certificate. + NebiusServiceAccountCredentials contains a Nebius + service account JSON key that authenticates to the + cluster via Nebius IAM. + enum: + - Kubeconfig + - NebiusServiceAccountCredentials + name: + type: string + description: Name of the Secret. + maxLength: 253 + key: + type: string + description: >- + Key within the Secret that holds the credential data. + maxLength: 253 + namespace: + type: string + description: >- + Namespace of the Secret, when it isn't this + NebiusCluster's namespace. Set on the credentials + entry when the credential is reused from the Nebius + ClusterProviderConfig's Secret. + maxLength: 253 + cache: + type: object + description: >- + Observed ModelCache RWX storage state, served by the + Nebius shared filesystem mounted on every node group and + Nebius's csi-mounted-fs-path CSI driver. + properties: + storageClassName: + type: string + description: >- + Name of the Modelplane-managed ReadWriteMany StorageClass + composed on this cluster for ModelCache PVCs. ModelCache + reads this to target the cache PVC. + maxLength: 253 + type: object + required: + - spec + type: object + served: true diff --git a/apis/servingstacks/definition.yaml b/apis/servingstacks/definition.yaml index 04c9ef444..0fee963f0 100644 --- a/apis/servingstacks/definition.yaml +++ b/apis/servingstacks/definition.yaml @@ -44,11 +44,12 @@ spec: type: array description: >- Secrets used to authenticate to the target cluster. Typically - sourced from a GKECluster's status.secrets. All secrets must - be in the same namespace as this ServingStack. A Kubeconfig - secret is required. If a cloud identity secret is present, the - serving stack authenticates as that identity instead of - relying on the kubeconfig's embedded credentials. + sourced from a GKECluster's status.secrets. Secrets are in + the same namespace as this ServingStack unless an entry says + otherwise. A Kubeconfig secret is required. If a cloud + identity secret is present, the serving stack authenticates + as that identity instead of relying on the kubeconfig's + embedded credentials. minItems: 1 maxItems: 8 items: @@ -79,6 +80,14 @@ spec: type: string description: Key within the Secret that holds the credential data. maxLength: 253 + namespace: + type: string + description: >- + Namespace of the Secret, when it isn't this + ServingStack's namespace. Set on cloud identity + entries whose credential lives with the cloud + provider's ProviderConfig. + maxLength: 253 nvidiaDriverRoot: type: string default: "/" diff --git a/crossplane-project.yaml b/crossplane-project.yaml index 1084dfd52..ad34e62ff 100644 --- a/crossplane-project.yaml +++ b/crossplane-project.yaml @@ -31,6 +31,10 @@ spec: tarball: name: compose-inference-cluster pathPrefix: _output/functions/compose-inference-cluster + - source: Tarball + tarball: + name: compose-nebius-cluster + pathPrefix: _output/functions/compose-nebius-cluster - source: Tarball tarball: name: compose-inference-gateway @@ -125,3 +129,9 @@ spec: # ToDo(haarchri): switch to official provider package: xpkg.upbound.io/modelplane/provider-kubernetes version: v1.2.1-070dae7 + - type: xpkg + xpkg: + apiVersion: pkg.crossplane.io/v1 + kind: Provider + package: xpkg.upbound.io/upbound/provider-nebius + version: v1.0.1 diff --git a/docs/content/platform/inference-class.md b/docs/content/platform/inference-class.md index 9e827c7f1..7c6bb803c 100644 --- a/docs/content/platform/inference-class.md +++ b/docs/content/platform/inference-class.md @@ -68,6 +68,9 @@ GPU. {{< tab "EKS L4" >}} {{< manifests "concepts/inference-class-eks-l4.yaml" >}} {{< /tab >}} +{{< tab "Nebius H100" >}} +{{< manifests "concepts/inference-class-nebius-h100.yaml" >}} +{{< /tab >}} {{< tab "H100 bare-metal" >}} {{< manifests "concepts/inference-class-h100-byo.yaml" >}} {{< /tab >}} diff --git a/docs/content/platform/inference-cluster.md b/docs/content/platform/inference-cluster.md index 7d501c21a..e923fa8b8 100644 --- a/docs/content/platform/inference-cluster.md +++ b/docs/content/platform/inference-cluster.md @@ -11,8 +11,8 @@ serving. Platform teams create these to provide GPU capacity. Each cluster has: -- A **cluster source**: `GKE` or `EKS` (Modelplane provisions the full cluster) - or `Existing` (bring a cluster you manage yourself). See +- A **cluster source**: `GKE`, `EKS`, or `Nebius` (Modelplane provisions the + full cluster) or `Existing` (bring a cluster you manage yourself). See [Supported Providers]({{< ref "platform/providers.md" >}}) for the clouds and neoclouds Modelplane runs on. - One or more **node pools**, each referencing an `InferenceClass` for its @@ -39,7 +39,7 @@ existing cluster the platform team must meet the requirements. The `cluster.source` discriminator picks one of two models: -- **Provisioned (`GKE`, `EKS`).** Modelplane creates the cluster and its GPU node +- **Provisioned (`GKE`, `EKS`, `Nebius`).** Modelplane creates the cluster and its GPU node pools from each pool's `InferenceClass`, labels the pool's nodes so the scheduler's placement is enforced, and provisions the storage class for model weights. It also injects a non-GPU **system pool** with opinionated defaults to @@ -61,6 +61,9 @@ The `cluster.source` discriminator picks one of two models: {{< tab "EKS" >}} {{< manifests path="concepts/inference-cluster-eks.yaml" apply="false" >}} {{< /tab >}} +{{< tab "Nebius" >}} +{{< manifests path="concepts/inference-cluster-nebius.yaml" apply="false" >}} +{{< /tab >}} {{< tab "Existing" >}} {{< manifests path="concepts/inference-cluster-existing.yaml" apply="false" >}} {{< /tab >}} @@ -73,8 +76,9 @@ A [ModelCache]({{< ref "/models/model-cache.md" >}}) stages model weights on a depends on the source: -- **`GKE`** (Filestore Enterprise) and **`EKS`** (EFS): auto-provisioned. Those - classes are fixed; nothing for the admin to do. +- **`GKE`** (Filestore Enterprise), **`EKS`** (EFS), and **`Nebius`** (shared + filesystem): auto-provisioned. Those classes are fixed; nothing for the + admin to do. - **`Existing`**: bring your own. Create an RWX StorageClass on the cluster, with any backend that supports automatic PVC provisioning (WekaIO, NetApp Trident, `FSx` for NetApp, and similar), and name it in diff --git a/docs/content/platform/providers.md b/docs/content/platform/providers.md index cd4ad38b5..2db57368b 100644 --- a/docs/content/platform/providers.md +++ b/docs/content/platform/providers.md @@ -12,8 +12,8 @@ A provider can show up here in three ways: {{< hint "note" >}} - **Provisioning supported.** Modelplane creates and manages the whole cluster - from an `InferenceCluster`, selected through `provisioning.provider`. GKE and - EKS work this way today. + from an `InferenceCluster`, selected through `provisioning.provider`. GKE, + EKS, and Nebius mk8s work this way today. - **Bring your own supported.** Register a cluster you already run with `source: Existing`. This works on any provider whose Kubernetes meets Modelplane's requirements (Dynamic Resource Allocation and a recent Kubernetes @@ -47,7 +47,7 @@ native provisioning. | Lambda | {{< accel nvidia >}} | Planned | ✓ | none yet | | Linode / Akamai (LKE) | {{< accel nvidia >}} | Planned | ✓ | {{< repolink "https://github.com/linode/provider-linode" "provider-linode" "official" >}} | | Microsoft Azure (AKS) | {{< accel nvidia >}} | Planned | ✓ | {{< repolink "https://github.com/crossplane-contrib/provider-upjet-azure" "provider-upjet-azure" "community" >}} | -| Nebius | {{< accel nvidia >}} | Planned | ✓ | none yet | +| Nebius (mk8s) | {{< accel nvidia >}} | ✓ | ✓ | {{< repolink "https://github.com/upbound/provider-upjet-nebius" "provider-upjet-nebius" "official" >}} | | Oracle Cloud (OKE) | {{< accel nvidia >}} {{< accel amd >}} | Planned | ✓ | {{< repolink "https://github.com/oracle/crossplane-provider-oci" "crossplane-provider-oci" "official" >}} | | OVHcloud | {{< accel nvidia >}} | Planned | ✓ | {{< repolink "https://github.com/edixos/provider-ovh" "edixos/provider-ovh" "community" >}} | | Scaleway (Kapsule) | {{< accel nvidia >}} | Planned | ✓ | {{< repolink "https://github.com/scaleway/crossplane-provider-scaleway" "crossplane-provider-scaleway" "official" >}} | diff --git a/docs/manifests/concepts/inference-class-nebius-h100.yaml b/docs/manifests/concepts/inference-class-nebius-h100.yaml new file mode 100644 index 000000000..0cc315003 --- /dev/null +++ b/docs/manifests/concepts/inference-class-nebius-h100.yaml @@ -0,0 +1,38 @@ +# An InferenceClass describing Nebius gpu-h100-sxm with 8x NVIDIA H100. +# +# The provisioning block tells Modelplane how to create a node group of +# this class on Nebius mk8s. Nebius sizes nodes by platform + preset +# rather than an instance type; the preset determines the GPU, vCPU, +# and memory shape of each node. The devices block describes what +# hardware a node of this class has, DRA-style - used by the scheduler +# to match models to clusters, and to form DRA ResourceClaims for +# claim: DRA devices. +apiVersion: modelplane.ai/v1alpha1 +kind: InferenceClass +metadata: + name: nebius-h100-8x +spec: + description: "Nebius gpu-h100-sxm, 8x NVIDIA H100 80GB" + provisioning: + provider: Nebius + nebius: + platform: gpu-h100-sxm + preset: 8gpu-128vcpu-1600gb + diskSizeGb: 200 + driversPreset: cuda13.0 + accelerator: + type: nvidia-h100 + count: 8 + devices: + - name: gpu + claim: DRA + driver: gpu.nvidia.com + deviceClassName: gpu.nvidia.com + count: 8 + attributes: + architecture: { string: Hopper } + cudaComputeCapability: { version: "9.0.0" } + capacity: + # The H100 80GB's real usable VRAM, what the NVIDIA DRA driver reports, + # not its nominal 80GB. A nodeSelector asking for >= 80Gi would never bind. + memory: { value: "81559Mi" } diff --git a/docs/manifests/concepts/inference-cluster-nebius.yaml b/docs/manifests/concepts/inference-cluster-nebius.yaml new file mode 100644 index 000000000..c5881d4d1 --- /dev/null +++ b/docs/manifests/concepts/inference-cluster-nebius.yaml @@ -0,0 +1,53 @@ +# An InferenceCluster backed by a Nebius mk8s cluster. +# +# Modelplane provisions the full mk8s cluster (VPC network and subnet, +# control plane with a public endpoint, system + GPU node groups, GPU +# clusters for InfiniBand fabrics) and installs the inference stack +# (cert-manager, Traefik, Prometheus, KEDA, LeaderWorkerSet). +# +# The system node group that hosts control-plane components is +# provisioned automatically and is not declared here. Only GPU node +# pools - each referencing an InferenceClass that describes the +# hardware shape and how to provision it - need to be declared. +# +# Nebius authenticates every Kubernetes client through Nebius IAM: the +# mk8s kubeconfig carries only the cluster endpoint and CA certificate, +# and Nebius has no API that mints service account keys server-side. So +# Modelplane reuses the credentials Secret of the Nebius +# ClusterProviderConfig named default - the same identity that +# provisions the cluster - to authenticate to it. Nothing to create +# beyond the ClusterProviderConfig the provider needs anyway. +# +# ModelCache RWX storage is provisioned automatically: a Nebius shared +# filesystem mounted on every node group, served through Nebius's +# csi-mounted-fs-path CSI driver as the modelplane-rwx-fs StorageClass. +# +# Delete this InferenceCluster with foreground cascading deletion for a +# clean teardown: +# +# kubectl delete inferencecluster nebius-eu-north --cascade=foreground +# +# The inference stack runs on the mk8s cluster and must uninstall while +# the cluster's API server and kubeconfig still exist - otherwise its +# Helm releases hang, and a load balancer one of them created can leak +# and block the network from deleting. Foreground deletion holds the +# cluster until the stack is uninstalled. Background deletion (the +# kubectl default) tears everything down at once and can orphan cloud +# resources. +apiVersion: modelplane.ai/v1alpha1 +kind: InferenceCluster +metadata: + name: nebius-eu-north + labels: + modelplane.ai/region: eu-north +spec: + cluster: + source: Nebius + nebius: {} + + nodePools: + - name: gpu-h100 + className: nebius-h100-8x + nodeCount: 1 + minNodeCount: 1 + maxNodeCount: 4 diff --git a/docs/manifests/examples/kimi-k2/inference-cluster.yaml b/docs/manifests/examples/kimi-k2/inference-cluster.yaml index 92415381e..d21697628 100644 --- a/docs/manifests/examples/kimi-k2/inference-cluster.yaml +++ b/docs/manifests/examples/kimi-k2/inference-cluster.yaml @@ -20,6 +20,7 @@ spec: maxNodeCount: 2 zones: - us-east-2b - fabric: EFA + fabric: + type: EFA capacityBlock: capacityReservationId: cr-0123456789abcdef0 # replace with your reservation ID diff --git a/docs/manifests/examples/qwen3-coder/inference-cluster.yaml b/docs/manifests/examples/qwen3-coder/inference-cluster.yaml index 67e65ba15..b9082376e 100644 --- a/docs/manifests/examples/qwen3-coder/inference-cluster.yaml +++ b/docs/manifests/examples/qwen3-coder/inference-cluster.yaml @@ -2,8 +2,9 @@ # Qwen3-Coder-480B as a multi-node gang. The H200 nodes come from an EC2 # Capacity Block reserved for ML. # -# fabric: EFA turns on Elastic Fabric Adapter for the gang's cross-node traffic; -# without it multi-node NCCL falls back to TCP, which is slow and unstable. +# fabric.type: EFA turns on Elastic Fabric Adapter for the gang's cross-node +# traffic; without it multi-node NCCL falls back to TCP, which is slow and +# unstable. apiVersion: modelplane.ai/v1alpha1 kind: InferenceCluster metadata: @@ -23,6 +24,7 @@ spec: maxNodeCount: 2 zones: - us-east-2b - fabric: EFA + fabric: + type: EFA capacityBlock: capacityReservationId: cr-0123456789abcdef0 # replace with your reservation ID diff --git a/docs/manifests/getting-started/clusterproviderconfig-nebius.yaml b/docs/manifests/getting-started/clusterproviderconfig-nebius.yaml new file mode 100644 index 000000000..40c7e27ce --- /dev/null +++ b/docs/manifests/getting-started/clusterproviderconfig-nebius.yaml @@ -0,0 +1,18 @@ +# Points the Nebius provider at the credentials Secret you created. Named +# default, so InferenceClusters with a Nebius source use it without further +# configuration - Modelplane also reuses its credentials Secret to +# authenticate to the clusters it provisions. +apiVersion: nebius.m.upbound.io/v1beta1 +kind: ClusterProviderConfig +metadata: + name: default +spec: + identity: + type: ServiceAccount + credentials: + source: Secret + secretRef: + namespace: crossplane-system + name: nebius-credentials + key: credentials.json + projectID: project-e00example diff --git a/docs/manifests/getting-started/nebius/platform.yaml b/docs/manifests/getting-started/nebius/platform.yaml new file mode 100644 index 000000000..a8d82b28f --- /dev/null +++ b/docs/manifests/getting-started/nebius/platform.yaml @@ -0,0 +1,44 @@ +apiVersion: modelplane.ai/v1alpha1 +kind: InferenceClass +metadata: + name: h100-1x +spec: + description: "Nebius gpu-h100-sxm, 1x NVIDIA H100 80GB" + provisioning: + provider: Nebius + nebius: + platform: gpu-h100-sxm + preset: 1gpu-16vcpu-200gb + diskSizeGb: 200 + driversPreset: cuda13.0 + accelerator: + type: nvidia-h100 + count: 1 + devices: + - name: gpu + claim: DRA + driver: gpu.nvidia.com + deviceClassName: gpu.nvidia.com + count: 1 + attributes: + architecture: { string: Hopper } + cudaComputeCapability: { version: "9.0.0" } + capacity: + memory: { value: "81559Mi" } # H100's real reported VRAM (not the nominal 80GB) +--- +apiVersion: modelplane.ai/v1alpha1 +kind: InferenceCluster +metadata: + name: nebius-eu-north + labels: + modelplane.ai/region: eu-north +spec: + cluster: + source: Nebius + nebius: {} + nodePools: + - name: gpu-h100 + className: h100-1x + nodeCount: 1 + minNodeCount: 1 + maxNodeCount: 1 diff --git a/docs/manifests/getting-started/prerequisites.yaml b/docs/manifests/getting-started/prerequisites.yaml index 22fbd6ca3..a725aa0df 100644 --- a/docs/manifests/getting-started/prerequisites.yaml +++ b/docs/manifests/getting-started/prerequisites.yaml @@ -76,7 +76,7 @@ metadata: spec: matchImages: - type: Prefix - prefix: xpkg.upbound.io/upbound/provider-helm + prefix: xpkg.upbound.io/modelplane/provider-helm runtime: configRef: name: provider-helm-modelplane diff --git a/docs/manifests/reference/nebiusclusters.yaml b/docs/manifests/reference/nebiusclusters.yaml new file mode 100644 index 000000000..0ab69d822 --- /dev/null +++ b/docs/manifests/reference/nebiusclusters.yaml @@ -0,0 +1,26 @@ +apiVersion: infrastructure.modelplane.ai/v1alpha1 +kind: NebiusCluster +metadata: + name: inference-eu-north + namespace: platform +spec: + kubernetesVersion: "1.34" + nodePools: + - name: system + role: System + platform: cpu-d3 + preset: 8vcpu-32gb + nodeCount: 2 + - name: gpu-h100 + role: GPU + platform: gpu-h100-sxm + preset: 8gpu-128vcpu-1600gb + diskSizeGb: 200 + nodeCount: 0 + maxNodeCount: 8 + # Joins an existing physical InfiniBand fabric in the project's region; + # use the fabric your GPU capacity is allocated on. + fabric: fabric-2 + gpu: + acceleratorType: nvidia-h100 + driversPreset: cuda13.0 diff --git a/docs/utils/vale/styles/config/vocabularies/Modelplane/accept.txt b/docs/utils/vale/styles/config/vocabularies/Modelplane/accept.txt index 2694551a0..37bcac31b 100644 --- a/docs/utils/vale/styles/config/vocabularies/Modelplane/accept.txt +++ b/docs/utils/vale/styles/config/vocabularies/Modelplane/accept.txt @@ -512,6 +512,7 @@ CKS CMK VKE Nebius +mk8s OVHcloud Vultr Fluidstack diff --git a/flake.nix b/flake.nix index 0a61f4b3b..f7df80483 100644 --- a/flake.nix +++ b/flake.nix @@ -58,6 +58,7 @@ "compose-inference-class" "compose-inference-cluster" "compose-inference-gateway" + "compose-nebius-cluster" "compose-serving-stack" "compose-model-cache" "compose-model-deployment" diff --git a/functions/compose-inference-cluster/function/fn.py b/functions/compose-inference-cluster/function/fn.py index b0a60ec36..d6cf6728d 100644 --- a/functions/compose-inference-cluster/function/fn.py +++ b/functions/compose-inference-cluster/function/fn.py @@ -37,6 +37,7 @@ from models.ai.modelplane.inferencecluster import v1alpha1 from models.ai.modelplane.infrastructure.ekscluster import v1alpha1 as eksv1alpha1 from models.ai.modelplane.infrastructure.gkecluster import v1alpha1 as gkev1alpha1 +from models.ai.modelplane.infrastructure.nebiuscluster import v1alpha1 as nebiusv1alpha1 from models.ai.modelplane.infrastructure.servingstack import v1alpha1 as ssv1alpha1 from models.io.crossplane.m.kubernetes.clusterproviderconfig import ( v1alpha1 as k8scpcv1alpha1, @@ -48,6 +49,7 @@ # Cluster source discriminator values from the XRD enum. CLUSTER_SOURCE_GKE = "GKE" CLUSTER_SOURCE_EKS = "EKS" +CLUSTER_SOURCE_NEBIUS = "Nebius" CLUSTER_SOURCE_EXISTING = "Existing" # GKE installs the NVIDIA driver here rather than at the default / root; the @@ -90,6 +92,9 @@ # Identity type for GCP service account credentials. _IDENTITY_TYPE_GCP = "GoogleApplicationCredentials" +# Identity type for Nebius service account credentials. +_IDENTITY_TYPE_NEBIUS = "NebiusServiceAccountCredentials" + def _name(meta: metav1.ObjectMeta | None) -> str: """The object's name, always set on resources read from the API server.""" @@ -149,6 +154,8 @@ def compose(self) -> None: self.compose_gke(cluster.gke) elif source == CLUSTER_SOURCE_EKS: self.compose_eks(cluster.eks) + elif source == CLUSTER_SOURCE_NEBIUS: + self.compose_nebius(cluster.nebius) elif source == CLUSTER_SOURCE_EXISTING: self.compose_existing(cluster.existing) else: @@ -318,6 +325,52 @@ def compose_eks(self, eks: v1alpha1.Eks | None) -> None: self.write_status(self.gpu_pools()) self.derive_conditions(cluster_ready=eks_ready) + def compose_nebius(self, nebius: v1alpha1.Nebius | None) -> None: + """Compose an InferenceCluster backed by a Modelplane-provisioned + Nebius mk8s cluster. Composes the NebiusCluster XR, waits for it to + be ready, then wires its secrets into the backend. + + The mk8s kubeconfig carries only the cluster endpoint and CA + certificate - Nebius authenticates every client through Nebius IAM - + so the ClusterProviderConfig authenticates as the Nebius service + account identity relayed through the NebiusCluster's status (the + Nebius ClusterProviderConfig's credentials Secret) + """ + if not nebius: + response.warning(self.rsp, "Nebius configuration is required when source is Nebius") + return + + self.compose_nebius_cluster(nebius) + + nebius_ready = ( + resource.get_condition(self.req.observed.resources.get("nebius-cluster"), "Ready").status == "True" + ) + kubeconfig = self.observed_nebius_secret(_SECRET_TYPE_KUBECONFIG) + credentials = self.observed_nebius_secret(_IDENTITY_TYPE_NEBIUS) + backend_exists = BACKEND_RESOURCE_KEY in self.req.observed.resources + + if nebius_ready and kubeconfig: + self.compose_cluster_provider_config( + kubeconfig.name, + kubeconfig.key, + identity_ref=credentials, + identity_type=_IDENTITY_TYPE_NEBIUS, + ) + + backend_secrets = self.resolve_nebius_backend_secrets(nebius_ready=nebius_ready, backend_exists=backend_exists) + if backend_secrets or backend_exists: + if backend_secrets: + self.compose_serving_stack(backend_secrets) + self.compose_nebius_usage() + + if nebius_ready: + self.rsp.desired.resources["nebius-cluster"].ready = fnv1.READY_TRUE + if not backend_exists: + response.normal(self.rsp, "Nebius cluster ready, composing backend") + + self.write_status(self.gpu_pools()) + self.derive_conditions(cluster_ready=nebius_ready) + def compose_existing(self, existing: v1alpha1.Existing | None) -> None: """Compose an InferenceCluster backed by a user-supplied cluster. No gating needed — the kubeconfig secret is provided by the user.""" @@ -377,7 +430,7 @@ def compose_cluster_provider_config( self, kubeconfig_name: str, kubeconfig_key: str | None, - identity_ref: gkev1alpha1.Secret | v1alpha1.IdentitySecretRef | None = None, + identity_ref: gkev1alpha1.Secret | nebiusv1alpha1.Secret | v1alpha1.IdentitySecretRef | None = None, identity_type: str | None = None, ) -> None: """Compose a ClusterProviderConfig for provider-kubernetes so that @@ -385,7 +438,9 @@ def compose_cluster_provider_config( When identity_ref is set, the ProviderConfig authenticates as the given identity_type (the cloud IAM identity) on top of the kubeconfig instead - of relying on the kubeconfig's embedded credentials. + of relying on the kubeconfig's embedded credentials. The identity + secret is in modelplane-system unless the ref carries a namespace + (Nebius credentials live with the Nebius ClusterProviderConfig). """ cpc = k8scpcv1alpha1.ClusterProviderConfig( metadata=metav1.ObjectMeta(name=resource.child_name(_name(self.xr.metadata), "cluster-kubeconfig")), @@ -405,7 +460,7 @@ def compose_cluster_provider_config( type=identity_type, # ty: ignore[invalid-argument-type] # value comes from the XRD/GKE identity-type enums source="Secret", secretRef=k8scpcv1alpha1.SecretRef( - namespace=_NAMESPACE_SYSTEM, + namespace=getattr(identity_ref, "namespace", None) or _NAMESPACE_SYSTEM, name=identity_ref.name, key=identity_ref.key, # ty: ignore[invalid-argument-type] # XRD defaults the secret key ), @@ -571,8 +626,8 @@ def compose_eks_cluster(self, eks: v1alpha1.Eks) -> None: ) # Likewise only set fabric when the pool opts into one, so an # on-demand pool's EKSCluster spec stays free of fabric: None. - if pool.fabric and pool.fabric != "None": - node_pool.fabric = pool.fabric + if pool.fabric and pool.fabric.type == "EFA": + node_pool.fabric = pool.fabric.type eks_node_pools.append(node_pool) resource.update( @@ -590,6 +645,150 @@ def compose_eks_cluster(self, eks: v1alpha1.Eks) -> None: ), ) + def compose_nebius_cluster(self, nebius: v1alpha1.Nebius) -> None: + """Compose a NebiusCluster XR. + + Combines the cluster-level config (project, credentials) with GPU + node pools derived from the user's node pools + referenced classes. + The system pool is injected by compose-nebius-cluster. + """ + nebius_node_pools: list[nebiusv1alpha1.NodePool] = [] + + for pool in self.xr.spec.nodePools or []: + cls = self.classes.get(pool.className) + if not cls or not cls.spec.provisioning or not cls.spec.provisioning.nebius: + msg = f"InferenceClass {pool.className} has no Nebius provisioning block" + response.set_conditions( + self.rsp, + resource.Condition( + typ=CONDITION_TYPE_CLUSTER_READY, + status="False", + reason=CONDITION_REASON_INVALID_NODE_POOL, + message=msg, + ), + ) + response.warning(self.rsp, msg) + return + prov = cls.spec.provisioning.nebius + node_pool = nebiusv1alpha1.NodePool( + name=pool.name, + role="GPU", + platform=prov.platform, + preset=prov.preset, + diskSizeGb=prov.diskSizeGb, + nodeCount=pool.nodeCount, + gpu=nebiusv1alpha1.Gpu( + acceleratorType=prov.accelerator.type, + driversPreset=prov.driversPreset, + ), + ) + # mk8s node groups are either fixed size or autoscaled, never + # both. Only set the autoscaling bounds when the pool opts in, so + # fixed-size pools stay fixed (resource.update serializes with + # exclude_unset, keeping unset bounds out of the NebiusCluster + # spec rather than emitting maxNodeCount: null). + if pool.maxNodeCount is not None: + node_pool.maxNodeCount = pool.maxNodeCount + if pool.minNodeCount is not None: + node_pool.minNodeCount = pool.minNodeCount + # Likewise only set fabric when the pool opts into one. The XRD + # guarantees fabric.infiniband is set when fabric.type is + # InfiniBand; the value names the physical Nebius fabric the + # NebiusCluster composes a GPU cluster on. + if pool.fabric and pool.fabric.type == "InfiniBand" and pool.fabric.infiniband: + node_pool.fabric = pool.fabric.infiniband.fabric + nebius_node_pools.append(node_pool) + + spec = nebiusv1alpha1.Spec( + kubernetesVersion=nebius.kubernetesVersion, + nodePools=nebius_node_pools, + ) + resource.update( + self.rsp.desired.resources["nebius-cluster"], + nebiusv1alpha1.NebiusCluster( + metadata=metav1.ObjectMeta( + name=_name(self.xr.metadata), + namespace=_NAMESPACE_SYSTEM, + ), + spec=spec, + ), + ) + + def compose_nebius_usage(self) -> None: + """Block NebiusCluster deletion until the backend is deleted.""" + resource.update( + self.rsp.desired.resources["usage-nebius-by-backend"], + usagev1beta1.Usage( + metadata=metav1.ObjectMeta(namespace=_NAMESPACE_SYSTEM), + spec=usagev1beta1.Spec( + of=usagev1beta1.Of( + apiVersion="infrastructure.modelplane.ai/v1alpha1", + kind="NebiusCluster", + resourceSelector=usagev1beta1.ResourceSelectorModel(matchControllerRef=True), + ), + by=usagev1beta1.By( + apiVersion="infrastructure.modelplane.ai/v1alpha1", + kind="ServingStack", + resourceSelector=usagev1beta1.ResourceSelector(matchControllerRef=True), + ), + replayDeletion=True, + ), + ), + ) + self.rsp.desired.resources["usage-nebius-by-backend"].ready = fnv1.READY_TRUE + + def resolve_nebius_backend_secrets( + self, *, nebius_ready: bool, backend_exists: bool + ) -> list[ssv1alpha1.Secret] | None: + """Resolve secrets for the backend from NebiusCluster status. Falls + back to the observed backend's spec.secrets if NebiusCluster secrets + aren't available but the backend already exists. Entries keep their + namespace when set - the Nebius credential typically lives with the + Nebius ClusterProviderConfig, outside modelplane-system.""" + nebius_secrets = self.observed_nebius_secrets() + + if nebius_ready and nebius_secrets: + return [self._backend_secret(s.type, s.name, s.key, s.namespace) for s in nebius_secrets] + + if backend_exists: + observed = self.req.observed.resources.get(BACKEND_RESOURCE_KEY) + if observed: + d = resource.struct_to_dict(observed.resource) + observed_secrets = d.get("spec", {}).get("secrets", []) + if observed_secrets: + return [ + self._backend_secret(s["type"], s["name"], s["key"], s.get("namespace")) + for s in observed_secrets + ] + + return None + + @staticmethod + def _backend_secret(type_: str, name: str, key: str, namespace: str | None) -> ssv1alpha1.Secret: + """A ServingStack secret entry, with the namespace only when set so + entries in the backend's own namespace stay namespace-free.""" + secret = ssv1alpha1.Secret(type=type_, name=name, key=key) # ty: ignore[invalid-argument-type] # values come from the XRD secret-type enums + if namespace: + secret.namespace = namespace + return secret + + def observed_nebius_secrets(self) -> list[nebiusv1alpha1.Secret] | None: + """Read the NebiusCluster's status.secrets from observed state.""" + nebius_observed = self.req.observed.resources.get("nebius-cluster") + if not nebius_observed: + return None + observed_nebius = nebiusv1alpha1.NebiusCluster.model_validate(resource.struct_to_dict(nebius_observed.resource)) + if not observed_nebius.status: + return None + return observed_nebius.status.secrets + + def observed_nebius_secret(self, secret_type: str) -> nebiusv1alpha1.Secret | None: + """Read a specific secret from the observed NebiusCluster status.""" + nebius_secrets = self.observed_nebius_secrets() + if not nebius_secrets: + return None + return next((s for s in nebius_secrets if s.type == secret_type), None) + def compose_eks_usage(self) -> None: """Block EKSCluster deletion until the backend is deleted.""" resource.update( @@ -759,12 +958,16 @@ def observed_cache_storage_class(self) -> str | None: return self._observed_cluster_cache_class("gke-cluster", gkev1alpha1.GKECluster) if cluster.source == CLUSTER_SOURCE_EKS: return self._observed_cluster_cache_class("eks-cluster", eksv1alpha1.EKSCluster) + if cluster.source == CLUSTER_SOURCE_NEBIUS: + return self._observed_cluster_cache_class("nebius-cluster", nebiusv1alpha1.NebiusCluster) if cluster.source == CLUSTER_SOURCE_EXISTING and cluster.existing and cluster.existing.cache: return cluster.existing.cache.storageClassName return None def _observed_cluster_cache_class( - self, key: str, model: type[gkev1alpha1.GKECluster] | type[eksv1alpha1.EKSCluster] + self, + key: str, + model: type[gkev1alpha1.GKECluster] | type[eksv1alpha1.EKSCluster] | type[nebiusv1alpha1.NebiusCluster], ) -> str | None: """Read status.cache.storageClassName from an observed cluster XR.""" observed = self.req.observed.resources.get(key) diff --git a/functions/compose-inference-cluster/tests/test_fn.py b/functions/compose-inference-cluster/tests/test_fn.py index 1d6d84c07..4957c771b 100644 --- a/functions/compose-inference-cluster/tests/test_fn.py +++ b/functions/compose-inference-cluster/tests/test_fn.py @@ -965,7 +965,7 @@ async def test_compose(self) -> None: # noqa: PLR0915 want8.requirements.resources["class-gpu-l4-eks"].CopyFrom(class_selector_eks) # --- Case 9: EKS first pass with a node pool that opts into the EFA - # fabric. fabric flows through to the EKSCluster node pool, which + # fabric. fabric.type flows through to the EKSCluster node pool, which # compose-eks-cluster turns into EFA launch-template interfaces. --- req9 = fnv1.RunFunctionRequest( observed=fnv1.State( @@ -988,7 +988,7 @@ async def test_compose(self) -> None: # noqa: PLR0915 nodeCount=2, maxNodeCount=4, zones=["us-west-2a"], - fabric="EFA", + fabric=v1alpha1.Fabric(type="EFA"), ), ], ), @@ -1502,8 +1502,328 @@ async def test_compose(self) -> None: # noqa: PLR0915 ) ) + # --- Case 10: Nebius first pass composes the NebiusCluster XR only. + # The pool's fabric.infiniband.fabric flows through to the + # NebiusCluster pool's fabric, and minNodeCount stays unset so the + # pool's autoscaling floor defaults to its node count downstream. --- + inference_class_h100_nebius = { + "apiVersion": "modelplane.ai/v1alpha1", + "kind": "InferenceClass", + "metadata": {"name": "gpu-h100-nebius"}, + "spec": { + "devices": [ + { + "name": "gpu", + "claim": "DRA", + "driver": "gpu.nvidia.com", + "deviceClassName": "gpu.nvidia.com", + "count": 8, + "capacity": {"memory": {"value": "81559Mi"}}, + }, + ], + "provisioning": { + "provider": "Nebius", + "nebius": { + "platform": "gpu-h100-sxm", + "preset": "8gpu-128vcpu-1600gb", + "diskSizeGb": 200, + "accelerator": {"type": "nvidia-h100", "count": 8}, + }, + }, + }, + } + class_selector_nebius = fnv1.ResourceSelector( + api_version="modelplane.ai/v1alpha1", + kind="InferenceClass", + match_name="gpu-h100-nebius", + ) + + req10 = fnv1.RunFunctionRequest( + observed=fnv1.State( + composite=fnv1.Resource( + resource=resource.dict_to_struct( + v1alpha1.InferenceCluster( + metadata=metav1.ObjectMeta( + name="test-cluster", + namespace="modelplane-system", + ), + spec=v1alpha1.Spec( + cluster=v1alpha1.Cluster( + source="Nebius", + nebius=v1alpha1.Nebius(), + ), + nodePools=[ + v1alpha1.NodePool( + name="h100-pool", + className="gpu-h100-nebius", + nodeCount=2, + maxNodeCount=4, + fabric=v1alpha1.Fabric( + type="InfiniBand", + infiniband=v1alpha1.Infiniband(fabric="fabric-2"), + ), + ), + ], + ), + ).model_dump(exclude_none=True, mode="json"), + ), + ), + ), + ) + req10.required_resources["class-gpu-h100-nebius"].items.append( + fnv1.Resource(resource=resource.dict_to_struct(inference_class_h100_nebius)), + ) + + want10 = fnv1.RunFunctionResponse( + meta=fnv1.ResponseMeta(ttl=durationpb.Duration(seconds=60)), + desired=fnv1.State( + composite=fnv1.Resource( + resource=resource.dict_to_struct( + { + "status": { + "providerConfigRef": { + "name": "test-cluster-cluster-kubeconfig-d0f89", + }, + "namespace": "modelplane-system", + "gpuPools": [ + { + "name": "h100-pool", + "nodes": 4, + "devices": [ + { + "name": "gpu", + "claim": "DRA", + "driver": "gpu.nvidia.com", + "deviceClassName": "gpu.nvidia.com", + "count": 8, + "capacity": {"memory": {"value": "81559Mi"}}, + }, + ], + }, + ], + }, + }, + ), + ), + resources={ + "nebius-cluster": fnv1.Resource( + resource=resource.dict_to_struct( + { + "apiVersion": "infrastructure.modelplane.ai/v1alpha1", + "kind": "NebiusCluster", + "metadata": { + "name": "test-cluster", + "namespace": "modelplane-system", + }, + "spec": { + "kubernetesVersion": "1.34", + "nodePools": [ + { + "name": "h100-pool", + "role": "GPU", + "platform": "gpu-h100-sxm", + "preset": "8gpu-128vcpu-1600gb", + "diskSizeGb": 200, + "nodeCount": 2, + "maxNodeCount": 4, + "gpu": { + "acceleratorType": "nvidia-h100", + "driversPreset": "cuda13.0", + }, + "fabric": "fabric-2", + }, + ], + }, + }, + ), + ), + }, + ), + conditions=[ + fnv1.Condition( + type="ClusterReady", + status=fnv1.STATUS_CONDITION_FALSE, + reason="Provisioning", + ), + fnv1.Condition( + type="BackendReady", + status=fnv1.STATUS_CONDITION_FALSE, + reason="WaitingForCluster", + ), + ], + context=structpb.Struct(), + ) + want10.requirements.resources["class-gpu-h100-nebius"].CopyFrom(class_selector_nebius) + + # --- Case 11: Nebius cluster ready - kubeconfig and service account + # credentials observed on the NebiusCluster status. The function wires + # the ClusterProviderConfig with the Nebius identity (the mk8s + # kubeconfig has no embedded credentials), composes the ServingStack + # backend with both secrets, and emits the Usage that blocks + # NebiusCluster deletion until the ServingStack is gone. --- + req11 = fnv1.RunFunctionRequest() + req11.CopyFrom(req10) + req11.observed.resources["nebius-cluster"].CopyFrom( + fnv1.Resource( + resource=resource.dict_to_struct( + { + "apiVersion": "infrastructure.modelplane.ai/v1alpha1", + "kind": "NebiusCluster", + "metadata": {"name": "test-cluster", "namespace": "modelplane-system"}, + "spec": { + "nodePools": [ + { + "name": "h100-pool", + "role": "GPU", + "platform": "gpu-h100-sxm", + "preset": "8gpu-128vcpu-1600gb", + "nodeCount": 2, + }, + ], + }, + "status": { + "conditions": [ + { + "type": "Ready", + "status": "True", + "reason": "Available", + "lastTransitionTime": "2024-01-01T00:00:00Z", + }, + ], + "secrets": [ + { + "type": "Kubeconfig", + "name": "test-cluster-kubeconfig-abcde", + "key": "kubeconfig", + }, + # The credential entry carries a namespace: it + # is the Nebius ClusterProviderConfig's Secret, + # which lives outside modelplane-system. + { + "type": "NebiusServiceAccountCredentials", + "name": "nebius-credentials", + "key": "credentials.json", + "namespace": "crossplane-system", + }, + ], + }, + } + ), + ), + ) + + want11 = fnv1.RunFunctionResponse() + want11.CopyFrom(want10) + want11.desired.resources["nebius-cluster"].ready = fnv1.READY_TRUE + want11.desired.resources["cluster-provider-config-kubernetes"].CopyFrom( + fnv1.Resource( + resource=resource.dict_to_struct( + { + "apiVersion": "kubernetes.m.crossplane.io/v1alpha1", + "kind": "ClusterProviderConfig", + "metadata": {"name": "test-cluster-cluster-kubeconfig-d0f89"}, + "spec": { + "credentials": { + "source": "Secret", + "secretRef": { + "namespace": "modelplane-system", + "name": "test-cluster-kubeconfig-abcde", + "key": "kubeconfig", + }, + }, + "identity": { + "type": "NebiusServiceAccountCredentials", + "source": "Secret", + "secretRef": { + "namespace": "crossplane-system", + "name": "nebius-credentials", + "key": "credentials.json", + }, + }, + }, + } + ), + ready=fnv1.READY_TRUE, + ), + ) + want11.desired.resources["serving-stack"].CopyFrom( + fnv1.Resource( + resource=resource.dict_to_struct( + { + "apiVersion": "infrastructure.modelplane.ai/v1alpha1", + "kind": "ServingStack", + "metadata": { + "name": "test-cluster-serving-stack-fd00b", + "namespace": "modelplane-system", + }, + "spec": { + "secrets": [ + { + "type": "Kubeconfig", + "name": "test-cluster-kubeconfig-abcde", + "key": "kubeconfig", + }, + { + "type": "NebiusServiceAccountCredentials", + "name": "nebius-credentials", + "key": "credentials.json", + "namespace": "crossplane-system", + }, + ], + }, + } + ), + ), + ) + want11.desired.resources["usage-nebius-by-backend"].CopyFrom( + fnv1.Resource( + resource=resource.dict_to_struct( + { + "apiVersion": "protection.crossplane.io/v1beta1", + "kind": "Usage", + "metadata": {"namespace": "modelplane-system"}, + "spec": { + "of": { + "apiVersion": "infrastructure.modelplane.ai/v1alpha1", + "kind": "NebiusCluster", + "resourceSelector": {"matchControllerRef": True}, + }, + "by": { + "apiVersion": "infrastructure.modelplane.ai/v1alpha1", + "kind": "ServingStack", + "resourceSelector": {"matchControllerRef": True}, + }, + "replayDeletion": True, + }, + } + ), + ready=fnv1.READY_TRUE, + ), + ) + del want11.conditions[:] + want11.conditions.extend( + [ + fnv1.Condition( + type="ClusterReady", + status=fnv1.STATUS_CONDITION_TRUE, + reason="ClusterRunning", + ), + fnv1.Condition( + type="BackendReady", + status=fnv1.STATUS_CONDITION_FALSE, + reason="Installing", + ), + ] + ) + want11.results.append( + fnv1.Result( + severity=fnv1.SEVERITY_NORMAL, + message="Nebius cluster ready, composing backend", + ) + ) + # Every compose path emits the ModelReplica guard requirement. - for want in (want1, want2, want3, want4, want5, want6, want7, want8, want9): + for want in (want1, want2, want3, want4, want5, want6, want7, want8, want9, want10, want11): want.requirements.resources["model-replicas"].CopyFrom(_replicas_selector("test-cluster")) # The guard cases reuse case 1's request and response. @@ -1534,6 +1854,12 @@ async def test_compose(self) -> None: # noqa: PLR0915 req=req9, want=want9, ), + Case(name="Nebius cluster first pass composes NebiusCluster XR only", req=req10, want=want10), + Case( + name="Nebius cluster ready composes CPC with Nebius identity, ServingStack, and Usage", + req=req11, + want=want11, + ), *guard_cases, ] diff --git a/functions/compose-nebius-cluster/function/__init__.py b/functions/compose-nebius-cluster/function/__init__.py new file mode 100644 index 000000000..b53d39d12 --- /dev/null +++ b/functions/compose-nebius-cluster/function/__init__.py @@ -0,0 +1,14 @@ +# Copyright 2026 The Modelplane Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + diff --git a/functions/compose-nebius-cluster/function/fn.py b/functions/compose-nebius-cluster/function/fn.py new file mode 100644 index 000000000..f60819cb8 --- /dev/null +++ b/functions/compose-nebius-cluster/function/fn.py @@ -0,0 +1,729 @@ +# Copyright 2026 The Modelplane Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Compose a Nebius mk8s cluster with networking and node groups. + +This function provisions the Nebius infrastructure for an inference +environment: a VPC network and subnet, an mk8s cluster with system and GPU +node groups, GPU clusters for InfiniBand fabrics, and ProviderConfigs for +provider-kubernetes and provider-helm to reach the cluster. + +The mk8s cluster's connection secret contains a kubeconfig with only the +cluster endpoint and CA certificate - Nebius authenticates every client +through Nebius IAM, and offers no way to mint service account keys +server-side. Consumers authenticate with service account credentials layered on +the kubeconfig as the ProviderConfigs' NebiusServiceAccountCredentials +identity. The credentials Secret is read off the Nebius ClusterProviderConfig +named default - the same identity that provisions the cluster. + +Node group autoscaling is served by mk8s itself (the NodeGroup's autoscaling +block), and the CNI and cluster DNS are bundled with the control plane, so no +in-cluster autoscaler or addons are composed. + +ModelCache RWX storage is served by a Nebius shared filesystem. +Nebius has no elastic RWX filesystem and no managed CSI integration, +so the pieces are composed individually: the filesystem is +attached to every node group and mounted by cloud-init, Nebius's +csi-mounted-fs-path CSI driver is installed as a Helm release to serve RWX +PersistentVolumes from paths on the mount, and the modelplane-rwx-fs +StorageClass pins ModelCache PVCs to that driver. +""" + +import dataclasses +from typing import Literal + +import grpc +from crossplane.function import logging, request, resource, response +from crossplane.function.proto.v1 import run_function_pb2 as fnv1 +from crossplane.function.proto.v1 import run_function_pb2_grpc as grpcv1 +from models.ai.modelplane.infrastructure.nebiuscluster import v1alpha1 +from models.io.crossplane.m.helm.providerconfig import v1beta1 as helmpcv1beta1 +from models.io.crossplane.m.helm.release import v1beta1 as helmv1beta1 +from models.io.crossplane.m.kubernetes.object import v1alpha1 as k8sobjv1alpha1 +from models.io.crossplane.m.kubernetes.providerconfig import v1alpha1 as k8spcv1alpha1 +from models.io.k8s.apimachinery.pkg.apis.meta import v1 as metav1 +from models.io.upbound.m.nebius.clusterproviderconfig import v1beta1 as nebiuspcv1beta1 +from models.io.upbound.m.nebius.compute.filesystem import v1beta1 as fsv1beta1 +from models.io.upbound.m.nebius.compute.gpucluster import v1beta1 as gpuclusterv1beta1 +from models.io.upbound.m.nebius.mk8s.cluster import v1beta1 as clusterv1beta1 +from models.io.upbound.m.nebius.mk8s.nodegroup import v1beta1 as nodegroupv1beta1 +from models.io.upbound.m.nebius.vpc.network import v1beta1 as networkv1beta1 +from models.io.upbound.m.nebius.vpc.subnet import v1beta1 as subnetv1beta1 + +# System pool injected into every mk8s cluster to host control-plane +# components (Envoy Gateway, LeaderWorkerSet, cert-manager, etc.). Not part of +# the user-facing API - compose-inference-cluster only passes GPU pools. +_SYSTEM_POOL_NAME = "system" +_SYSTEM_POOL_PLATFORM = "cpu-d3" +_SYSTEM_POOL_PRESET = "4vcpu-16gb" +_SYSTEM_POOL_MIN_NODE_COUNT = 1 +_SYSTEM_POOL_MAX_NODE_COUNT = 2 + +# Labels written on mk8s node groups' nodes. compose-model-deployment reads +# these labels for GPU scheduling. +_LABEL_GPU = "modelplane.ai/gpu" +_LABEL_POOL = "modelplane.ai/pool" + +# Label written on composed GPU clusters so node groups can select the GPU +# cluster backing their InfiniBand fabric. +_LABEL_FABRIC = "modelplane.ai/fabric" + +# Secret types written to XR status. compose-inference-cluster reads these to +# wire the kubeconfig and service account credentials into ProviderConfigs. +# The credentials' type is the provider identity it authenticates as. +_SECRET_TYPE_KUBECONFIG = "Kubeconfig" + +# Key within the connection secret the mk8s Cluster writes. The provider +# renders a kubeconfig targeting the public endpoint when one exists. +_SECRET_KEY_KUBECONFIG = "kubeconfig" + +# Identity type for Nebius service account credentials. +_IDENTITY_TYPE_NEBIUS = "NebiusServiceAccountCredentials" + +# Name of the Nebius ClusterProviderConfig the composed managed resources use +# (Crossplane's default for namespaced MRs without a providerConfigRef). Its +# credentials Secret is reused as the cluster identity. +_NEBIUS_PROVIDER_CONFIG_NAME = "default" + +# Boot disk type for node groups. Network SSDs are available on all +# platforms; local disks would tie the group to specific presets. +_BOOT_DISK_TYPE = "NETWORK_SSD" + +# Taint applied to GPU node groups so only inference workloads that +# tolerate GPUs are scheduled on them. +_GPU_TAINT_KEY = "nvidia.com/gpu" +_GPU_TAINT_VALUE = "true" +_GPU_TAINT_EFFECT = "NO_SCHEDULE" + +# Management policies that exclude Delete, used for resources installed on the +# workload cluster (the RWX StorageClass Object and the CSI driver Helm +# Release). These exist only to configure the cluster and are only ever +# deleted because the whole NebiusCluster - and the cluster itself - is being +# torn down. Deleting them then means asking provider-helm / +# provider-kubernetes to reach a cluster whose kubeconfig Secret has already +# been deleted, which wedges their finalizers and hangs the composite. +# Orphaning them sidesteps that: the in-cluster resources die with the +# cluster. +_ManagementPolicy = Literal["Observe", "Create", "Update", "Delete", "LateInitialize", "*"] +_ORPHAN_MANAGEMENT: list[_ManagementPolicy] = ["Observe", "Create", "Update"] + +# The shared filesystem backing ModelCache RWX storage. Nebius shared +# filesystems are fixed size - there is no elastic option like EFS - so the +# filesystem is created at a fixed size that fits several large models' +# weights. +_FS_TYPE = "NETWORK_SSD" +_FS_SIZE_GIB = 1024 + +# The tag node groups attach the filesystem under, and the host path their +# cloud-init mounts it on. The CSI driver serves volumes from dataDir, a +# directory on that mount. +_FS_MOUNT_TAG = "modelplane-cache" +_FS_MOUNT_POINT = "/mnt/data" + +# Key within the composed cloud-init Secret that holds the user data. +_SECRET_KEY_USER_DATA = "userData" + +# Cloud-init user data mounting the shared filesystem on every node, per +# https://docs.nebius.com/kubernetes/storage/filesystem-over-csi. runcmd runs +# once at first boot; the fstab entry keeps the mount across reboots. +_FS_CLOUD_INIT = f"""#cloud-config +runcmd: + - mkdir -p {_FS_MOUNT_POINT} + - mount -t virtiofs {_FS_MOUNT_TAG} {_FS_MOUNT_POINT} + - printf "{_FS_MOUNT_TAG} {_FS_MOUNT_POINT} virtiofs defaults,nofail 0 2\\n" >> /etc/fstab +""" + +# Nebius's csi-mounted-fs-path CSI driver, which serves RWX +# PersistentVolumes from paths on the pre-mounted shared filesystem. +_CSI_CHART_REPO = "oci://cr.eu-north1.nebius.cloud/mk8s/helm" +_CSI_CHART_NAME = "csi-mounted-fs-path" +_CSI_CHART_VERSION = "0.1.6" +_CSI_NAMESPACE = "kube-system" + +# The driver name the chart registers (its values.yaml driverName default). +# The composed StorageClass pins to it as its provisioner. +_CSI_DRIVER_NAME = "mounted-fs-path.csi.nebius.ai" + +# Name of the RWX StorageClass Modelplane composes for ModelCache, mirroring +# modelplane-rwx-efs on EKS. +_MANAGED_STORAGE_CLASS = "modelplane-rwx-fs" + + +def _name(meta: metav1.ObjectMeta | None) -> str: + """The object's name, always set on resources read from the API server.""" + if meta is None or meta.name is None: + raise ValueError("metadata.name is unexpectedly absent") + return meta.name + + +def _namespace(meta: metav1.ObjectMeta | None) -> str: + """The object's namespace, always set on namespaced resources read from the API server.""" + if meta is None or meta.namespace is None: + raise ValueError("metadata.namespace is unexpectedly absent") + return meta.namespace + + +def _kubeconfig_secret_name(xr: v1alpha1.NebiusCluster) -> str: + """Derive the kubeconfig secret name from the XR.""" + return resource.child_name(_name(xr.metadata), "kubeconfig") + + +def _cloud_init_secret_name(xr: v1alpha1.NebiusCluster) -> str: + """Derive the cloud-init user data secret name from the XR.""" + return resource.child_name(_name(xr.metadata), "cloud-init") + + +@dataclasses.dataclass +class Credentials: + """A reference to the Nebius service account credentials Secret.""" + + namespace: str + name: str + key: str + + +class FunctionRunner(grpcv1.FunctionRunnerServiceServicer): + """A FunctionRunner handles gRPC RunFunctionRequests.""" + + def __init__(self) -> None: + """Create a new FunctionRunner.""" + self.log = logging.get_logger() + + async def RunFunction( + self, req: fnv1.RunFunctionRequest, _: grpc.aio.ServicerContext | None + ) -> fnv1.RunFunctionResponse: # ty: ignore[invalid-method-override] # the generated grpc servicer base is untyped + """Run the function.""" + log = self.log.bind(tag=req.meta.tag) + log.info("Running function") + + rsp = response.to(req) + c = Composer(req, rsp) + c.compose() + return rsp + + +class Composer: + def __init__(self, req: fnv1.RunFunctionRequest, rsp: fnv1.RunFunctionResponse) -> None: + self.req = req + self.rsp = rsp + self.xr = v1alpha1.NebiusCluster(**resource.struct_to_dict(req.observed.composite.resource)) + + def compose(self) -> None: + # Resolving credentials can gate on the Nebius ClusterProviderConfig + # being fetched, but the infrastructure doesn't need them - only the + # ProviderConfigs and the status credential entry do - so the cluster + # provisions in parallel with the first fetch. + creds = self.resolve_credentials() + self.compose_network() + self.compose_cluster() + self.compose_filesystem() + self.compose_gpu_clusters() + self.compose_node_groups() + if creds: + self.compose_provider_configs(creds) + self.compose_csi_driver() + self.compose_storage_class() + self.write_status(creds) + self.mark_readiness(provider_configs_composed=creds is not None) + + def resolve_credentials(self) -> Credentials | None: + """Resolve the Nebius service account credentials Secret consumers + authenticate to the cluster with. + + The credentials Secret is read off the Nebius ClusterProviderConfig + the composed resources use - the cluster identity is the identity + that provisioned it. None while the ClusterProviderConfig hasn't been + fetched yet, or when it doesn't source credentials from a Secret.""" + response.require_resources( + self.rsp, + name="nebius-provider-config", + api_version="nebius.m.upbound.io/v1beta1", + kind="ClusterProviderConfig", + match_name=_NEBIUS_PROVIDER_CONFIG_NAME, + ) + d = request.get_required_resource(self.req, "nebius-provider-config") + if d is None: + response.normal(self.rsp, f"Waiting for Nebius ClusterProviderConfig {_NEBIUS_PROVIDER_CONFIG_NAME}") + return None + + pc = nebiuspcv1beta1.ClusterProviderConfig.model_validate(d) + secret_ref = pc.spec.credentials.secretRef + if pc.spec.credentials.source != "Secret" or not secret_ref: + response.warning( + self.rsp, + f"Nebius ClusterProviderConfig {_NEBIUS_PROVIDER_CONFIG_NAME} doesn't source credentials " + "from a Secret; consumers can't authenticate to the cluster without one", + ) + return None + return Credentials(namespace=secret_ref.namespace, name=secret_ref.name, key=secret_ref.key) + + def compose_network(self) -> None: + """Compose a dedicated VPC network and subnet for the cluster. Nebius + allocates subnet CIDRs from the network's pools, so there is nothing + to configure beyond opting into them. + + Every Nebius resource carries an explicit forProvider.name: the Nebius + API requires a non-empty name, and the provider doesn't derive one + from the Kubernetes object name.""" + network = networkv1beta1.Network( + spec=networkv1beta1.Spec( + forProvider=networkv1beta1.ForProvider( + name=_name(self.xr.metadata), + ), + ), + ) + resource.update(self.rsp.desired.resources["network"], network) + + subnet = subnetv1beta1.Subnet( + spec=subnetv1beta1.Spec( + forProvider=subnetv1beta1.ForProvider( + name=_name(self.xr.metadata), + networkIdSelector=subnetv1beta1.NetworkIdSelector( + matchControllerRef=True, + ), + ipv4PrivatePools=subnetv1beta1.Ipv4PrivatePools( + useNetworkPools=True, + ), + ), + ), + ) + resource.update(self.rsp.desired.resources["subnet"], subnet) + + def compose_cluster(self) -> None: + cluster = clusterv1beta1.Cluster( + spec=clusterv1beta1.Spec( + forProvider=clusterv1beta1.ForProvider( + name=_name(self.xr.metadata), + controlPlane=clusterv1beta1.ControlPlane( + version=self.xr.spec.kubernetesVersion, + subnetIdSelector=clusterv1beta1.SubnetIdSelector( + matchControllerRef=True, + ), + endpoints=clusterv1beta1.Endpoints( + publicEndpoint=clusterv1beta1.PublicEndpoint(), + ), + ), + ), + writeConnectionSecretToRef=clusterv1beta1.WriteConnectionSecretToRef( + name=_kubeconfig_secret_name(self.xr), + ), + ), + ) + resource.update(self.rsp.desired.resources["cluster"], cluster) + + def compose_filesystem(self) -> None: + """Provision the shared filesystem backing ModelCache RWX storage, + and the cloud-init Secret node groups mount it with. + + Every node group attaches the filesystem under _FS_MOUNT_TAG + (compose_node_groups) and mounts it via this cloud-init; + compose_csi_driver installs the CSI driver that serves RWX volumes + from the mount, and compose_storage_class pins the modelplane-rwx-fs + StorageClass to that driver.""" + resource.update( + self.rsp.desired.resources["filesystem"], + fsv1beta1.Filesystem( + spec=fsv1beta1.Spec( + forProvider=fsv1beta1.ForProvider( + name=f"{_name(self.xr.metadata)}-cache", + type=_FS_TYPE, + sizeGibibytes=_FS_SIZE_GIB, + ), + ), + ), + ) + + # The NodeGroup API only takes cloud-init user data by Secret + # reference, read from the node group's own namespace, so the static + # mount config is composed as a plain Secret next to the node groups. + # Secrets have no Ready condition, so mark readiness here. + resource.update( + self.rsp.desired.resources["cloud-init"], + { + "apiVersion": "v1", + "kind": "Secret", + "metadata": { + "name": _cloud_init_secret_name(self.xr), + "namespace": _namespace(self.xr.metadata), + }, + "type": "Opaque", + "stringData": {_SECRET_KEY_USER_DATA: _FS_CLOUD_INIT}, + }, + ) + self.rsp.desired.resources["cloud-init"].ready = fnv1.READY_TRUE + + def compose_csi_driver(self) -> None: + """Compose Nebius's csi-mounted-fs-path CSI driver as a Helm release + on the cluster's own helm ProviderConfig. It serves RWX + PersistentVolumes from dataDir, a directory on the shared filesystem + mount every node carries. Gate it on the cluster being observed: + until it exists, the ProviderConfig can't reach a cluster and the + release would just error.""" + cluster_observed = "cluster" in self.req.observed.resources + release_exists = "release-csi-mounted-fs-path" in self.req.observed.resources + if not (cluster_observed or release_exists): + return + + resource.update( + self.rsp.desired.resources["release-csi-mounted-fs-path"], + helmv1beta1.Release( + metadata=metav1.ObjectMeta(namespace=_namespace(self.xr.metadata)), + spec=helmv1beta1.Spec( + managementPolicies=_ORPHAN_MANAGEMENT, + providerConfigRef=helmv1beta1.ProviderConfigRef( + kind="ProviderConfig", + name=_kubeconfig_secret_name(self.xr), + ), + forProvider=helmv1beta1.ForProvider( + chart=helmv1beta1.Chart( + name=_CSI_CHART_NAME, + repository=_CSI_CHART_REPO, + version=_CSI_CHART_VERSION, + ), + namespace=_CSI_NAMESPACE, + values={ + "dataDir": f"{_FS_MOUNT_POINT}/csi-mounted-fs-path-data/", + # The node plugin must run on every node whose pods + # mount cache PVCs - including the GPU nodes, which + # carry the nvidia.com/gpu taint. The chart's + # DaemonSet tolerates nothing by default, so + # without this the driver never registers with the + # GPU nodes' kubelet and engine pods fail to mount + # ("driver name mounted-fs-path.csi.nebius.ai not + # found in the list of registered CSI drivers"). + "tolerations": [ + { + "key": _GPU_TAINT_KEY, + "operator": "Exists", + "effect": "NoSchedule", + }, + ], + }, + ), + ), + ), + ) + + def compose_storage_class(self) -> None: + """Compose the RWX StorageClass on the workload cluster, pinned to + the csi-mounted-fs-path driver. Gated like the CSI driver release: + until the cluster is observed, the ProviderConfig can't reach it. The + Object is applied through the cluster's own provider-kubernetes + ProviderConfig. StorageClass has no Ready condition, so use + SuccessfulCreate (DeriveFromObject would hang).""" + cluster_observed = "cluster" in self.req.observed.resources + storage_class_exists = "storage-class-rwx-fs" in self.req.observed.resources + if not (cluster_observed or storage_class_exists): + return + + manifest = { + "apiVersion": "storage.k8s.io/v1", + "kind": "StorageClass", + "metadata": {"name": _MANAGED_STORAGE_CLASS}, + "provisioner": _CSI_DRIVER_NAME, + "volumeBindingMode": "WaitForFirstConsumer", + } + resource.update( + self.rsp.desired.resources["storage-class-rwx-fs"], + k8sobjv1alpha1.Object( + metadata=metav1.ObjectMeta(namespace=_namespace(self.xr.metadata)), + spec=k8sobjv1alpha1.Spec( + managementPolicies=_ORPHAN_MANAGEMENT, + providerConfigRef=k8sobjv1alpha1.ProviderConfigRef( + kind="ProviderConfig", + name=_kubeconfig_secret_name(self.xr), + ), + readiness=k8sobjv1alpha1.Readiness(policy="SuccessfulCreate"), + forProvider=k8sobjv1alpha1.ForProvider(manifest=manifest), + ), + ), + ) + self.rsp.desired.resources["storage-class-rwx-fs"].ready = fnv1.READY_TRUE + + def compose_gpu_clusters(self) -> None: + """Compose one GPU cluster per distinct InfiniBand fabric used by the + node pools. Node groups on a fabric select their GPU cluster by its + fabric label.""" + for fabric in self._fabrics(): + gpu_cluster = gpuclusterv1beta1.GpuCluster( + metadata=metav1.ObjectMeta(labels={_LABEL_FABRIC: fabric}), + spec=gpuclusterv1beta1.Spec( + forProvider=gpuclusterv1beta1.ForProvider( + name=f"{_name(self.xr.metadata)}-{fabric}", + infinibandFabric=fabric, + ), + ), + ) + resource.update(self.rsp.desired.resources[f"gpu-cluster-{fabric}"], gpu_cluster) + + def compose_node_groups(self) -> None: + self._compose_system_group() + for pool in self.xr.spec.nodePools: + labels = {_LABEL_POOL: pool.name} + if pool.role == "GPU" and pool.gpu: + labels[_LABEL_GPU] = pool.gpu.acceleratorType + + template = nodegroupv1beta1.Template( + resources=nodegroupv1beta1.Resources( + platform=pool.platform, + preset=pool.preset, + ), + bootDisk=nodegroupv1beta1.BootDisk( + sizeGibibytes=pool.diskSizeGb, + type=_BOOT_DISK_TYPE, + ), + networkInterfaces=[ + nodegroupv1beta1.NetworkInterface( + subnetIdSelector=nodegroupv1beta1.SubnetIdSelector( + matchControllerRef=True, + ), + ), + ], + filesystems=self._cache_filesystems(), + cloudInitUserDataSecretRef=self._cloud_init_ref(), + metadata=nodegroupv1beta1.Metadata(labels=labels), + ) + + if pool.role == "GPU" and pool.gpu: + template.gpuSettings = nodegroupv1beta1.GpuSettings( + driversPreset=pool.gpu.driversPreset, + ) + template.taints = [ + nodegroupv1beta1.Taint( + key=_GPU_TAINT_KEY, + value=_GPU_TAINT_VALUE, + effect=_GPU_TAINT_EFFECT, + ), + ] + + if pool.fabric: + template.gpuCluster = nodegroupv1beta1.GpuCluster( + idSelector=nodegroupv1beta1.IdSelector( + matchControllerRef=True, + matchLabels={_LABEL_FABRIC: pool.fabric}, + ), + ) + + ng = nodegroupv1beta1.NodeGroup( + spec=nodegroupv1beta1.Spec( + forProvider=nodegroupv1beta1.ForProvider( + name=f"{_name(self.xr.metadata)}-{pool.name}", + parentIdSelector=nodegroupv1beta1.ParentIdSelector( + matchControllerRef=True, + ), + version=self.xr.spec.kubernetesVersion, + template=template, + ), + ), + ) + + # mk8s node groups are either fixed size or autoscaled, never + # both. maxNodeCount opts into server-side autoscaling. + if pool.maxNodeCount is not None: + ng.spec.forProvider.autoscaling = nodegroupv1beta1.Autoscaling( + minNodeCount=(pool.minNodeCount if pool.minNodeCount is not None else pool.nodeCount), + maxNodeCount=pool.maxNodeCount, + ) + else: + ng.spec.forProvider.fixedNodeCount = pool.nodeCount + + resource.update( + self.rsp.desired.resources[f"nodegroup-{pool.name}"], + ng, + ) + + def _compose_system_group(self) -> None: + """Compose the system node group for control-plane components.""" + resource.update( + self.rsp.desired.resources[f"nodegroup-{_SYSTEM_POOL_NAME}"], + nodegroupv1beta1.NodeGroup( + spec=nodegroupv1beta1.Spec( + forProvider=nodegroupv1beta1.ForProvider( + name=f"{_name(self.xr.metadata)}-{_SYSTEM_POOL_NAME}", + parentIdSelector=nodegroupv1beta1.ParentIdSelector( + matchControllerRef=True, + ), + version=self.xr.spec.kubernetesVersion, + autoscaling=nodegroupv1beta1.Autoscaling( + minNodeCount=_SYSTEM_POOL_MIN_NODE_COUNT, + maxNodeCount=_SYSTEM_POOL_MAX_NODE_COUNT, + ), + template=nodegroupv1beta1.Template( + resources=nodegroupv1beta1.Resources( + platform=_SYSTEM_POOL_PLATFORM, + preset=_SYSTEM_POOL_PRESET, + ), + bootDisk=nodegroupv1beta1.BootDisk( + sizeGibibytes=100, + type=_BOOT_DISK_TYPE, + ), + networkInterfaces=[ + nodegroupv1beta1.NetworkInterface( + subnetIdSelector=nodegroupv1beta1.SubnetIdSelector( + matchControllerRef=True, + ), + ), + ], + filesystems=self._cache_filesystems(), + cloudInitUserDataSecretRef=self._cloud_init_ref(), + metadata=nodegroupv1beta1.Metadata( + labels={ + _LABEL_POOL: _SYSTEM_POOL_NAME, + }, + ), + ), + ), + ), + ), + ) + + def _cache_filesystems(self) -> list[nodegroupv1beta1.Filesystem]: + """The cache filesystem attachment every node group carries. The + selector resolves to the one composed Filesystem.""" + return [ + nodegroupv1beta1.Filesystem( + attachMode="READ_WRITE", + mountTag=_FS_MOUNT_TAG, + existingFilesystem=nodegroupv1beta1.ExistingFilesystem( + idSelector=nodegroupv1beta1.IdSelector(matchControllerRef=True), + ), + ), + ] + + def _cloud_init_ref(self) -> nodegroupv1beta1.CloudInitUserDataSecretRef: + """A reference to the composed cloud-init Secret that mounts the + cache filesystem.""" + return nodegroupv1beta1.CloudInitUserDataSecretRef( + name=_cloud_init_secret_name(self.xr), + key=_SECRET_KEY_USER_DATA, + ) + + def compose_provider_configs(self, creds: Credentials) -> None: + """Compose ProviderConfigs for provider-kubernetes and provider-helm + targeting the cluster. The kubeconfig from the cluster's connection + secret has no credentials, so both authenticate as the Nebius service + account identity.""" + resource.update( + self.rsp.desired.resources["provider-config-kubernetes"], + k8spcv1alpha1.ProviderConfig( + metadata=metav1.ObjectMeta(name=_kubeconfig_secret_name(self.xr)), + spec=k8spcv1alpha1.Spec( + credentials=k8spcv1alpha1.Credentials( + source="Secret", + secretRef=k8spcv1alpha1.SecretRef( + name=_kubeconfig_secret_name(self.xr), + namespace=_namespace(self.xr.metadata), + key=_SECRET_KEY_KUBECONFIG, + ), + ), + identity=k8spcv1alpha1.Identity( + type=_IDENTITY_TYPE_NEBIUS, + source="Secret", + secretRef=k8spcv1alpha1.SecretRef( + name=creds.name, + namespace=creds.namespace, + key=creds.key, + ), + ), + ), + ), + ) + + resource.update( + self.rsp.desired.resources["provider-config-helm"], + helmpcv1beta1.ProviderConfig( + metadata=metav1.ObjectMeta(name=_kubeconfig_secret_name(self.xr)), + spec=helmpcv1beta1.Spec( + credentials=helmpcv1beta1.Credentials( + source="Secret", + secretRef=helmpcv1beta1.SecretRef( + name=_kubeconfig_secret_name(self.xr), + namespace=_namespace(self.xr.metadata), + key=_SECRET_KEY_KUBECONFIG, + ), + ), + identity=helmpcv1beta1.Identity( + type=_IDENTITY_TYPE_NEBIUS, + source="Secret", + secretRef=helmpcv1beta1.SecretRef( + name=creds.name, + namespace=creds.namespace, + key=creds.key, + ), + ), + ), + ), + ) + + def write_status(self, creds: Credentials | None) -> None: + secrets = [ + v1alpha1.Secret( + type=_SECRET_TYPE_KUBECONFIG, + name=_kubeconfig_secret_name(self.xr), + key=_SECRET_KEY_KUBECONFIG, + ), + ] + if creds: + credential = v1alpha1.Secret( + type=_IDENTITY_TYPE_NEBIUS, + name=creds.name, + key=creds.key, + ) + # Only name a namespace when it differs from the XR's own, the + # namespace consumers assume by default. + if creds.namespace != _namespace(self.xr.metadata): + credential.namespace = creds.namespace + secrets.append(credential) + status = v1alpha1.Status( + secrets=secrets, + # The RWX StorageClass Modelplane composes for ModelCache. + # Published immediately so ModelCache can target it; the class may + # still be materialising on the workload cluster. + cache=v1alpha1.Cache(storageClassName=_MANAGED_STORAGE_CLASS), + ) + resource.update_status(self.rsp.desired.composite, status) + + def mark_readiness(self, *, provider_configs_composed: bool) -> None: + """Mark composed resources as ready based on their observed conditions.""" + managed_resources = [ + "network", + "subnet", + "cluster", + "filesystem", + ] + managed_resources += [f"gpu-cluster-{fabric}" for fabric in self._fabrics()] + managed_resources.append(f"nodegroup-{_SYSTEM_POOL_NAME}") + managed_resources += [f"nodegroup-{pool.name}" for pool in self.xr.spec.nodePools] + # The CSI driver Helm release is only composed once the cluster is + # observed, so only mark it ready when it's actually in desired state - + # touching it here otherwise would re-add a resource we gated out. + if "release-csi-mounted-fs-path" in self.rsp.desired.resources: + managed_resources.append("release-csi-mounted-fs-path") + + for r in managed_resources: + if resource.get_condition(self.req.observed.resources.get(r), "Ready").status == "True": + self.rsp.desired.resources[r].ready = fnv1.READY_TRUE + + if provider_configs_composed: + self.rsp.desired.resources["provider-config-kubernetes"].ready = fnv1.READY_TRUE + self.rsp.desired.resources["provider-config-helm"].ready = fnv1.READY_TRUE + + def _fabrics(self) -> list[str]: + """The distinct InfiniBand fabrics used by the node pools, in + first-use order.""" + fabrics: list[str] = [] + for pool in self.xr.spec.nodePools: + if pool.fabric and pool.fabric not in fabrics: + fabrics.append(pool.fabric) + return fabrics diff --git a/functions/compose-nebius-cluster/function/main.py b/functions/compose-nebius-cluster/function/main.py new file mode 100644 index 000000000..2e8441dac --- /dev/null +++ b/functions/compose-nebius-cluster/function/main.py @@ -0,0 +1,55 @@ +# Copyright 2026 The Modelplane Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""The composition function's main CLI.""" + +import click +from crossplane.function import logging, runtime + +from function import fn + + +@click.command() +@click.option("--debug", "-d", is_flag=True, help="Emit debug logs.") +@click.option( + "--address", + default="0.0.0.0:9443", + show_default=True, + help="Address at which to listen for gRPC connections", +) +@click.option("--tls-certs-dir", help="Serve using mTLS certificates.", envvar="TLS_SERVER_CERTS_DIR") +@click.option( + "--insecure", + is_flag=True, + help="Run without mTLS credentials. If you supply this flag --tls-certs-dir will be ignored.", +) +def cli(debug: bool, address: str, tls_certs_dir: str, insecure: bool) -> None: + """A Crossplane composition function.""" + try: + level = logging.Level.INFO + if debug: + level = logging.Level.DEBUG + logging.configure(level=level) + runtime.serve( + fn.FunctionRunner(), + address, + creds=runtime.load_credentials(tls_certs_dir), + insecure=insecure, + ) + except Exception as e: + click.echo(f"Cannot run function: {e}") + + +if __name__ == "__main__": + cli() diff --git a/functions/compose-nebius-cluster/pyproject.toml b/functions/compose-nebius-cluster/pyproject.toml new file mode 100644 index 000000000..22167b695 --- /dev/null +++ b/functions/compose-nebius-cluster/pyproject.toml @@ -0,0 +1,26 @@ +[build-system] +requires = ["uv_build>=0.11.0,<0.12"] +build-backend = "uv_build" + +[project] +name = "compose-nebius-cluster" +version = "0.0.0" +description = "Compose a Nebius mk8s cluster with networking and node groups." +requires-python = ">=3.11,<3.14" +license = "Apache-2.0" +dependencies = [ + "crossplane-function-sdk-python>=0.14.0", + "click>=8.1.0", + "grpcio>=1.73.1", + "crossplane-models", +] + +[tool.uv.sources] +crossplane-models = { workspace = true } + +[project.scripts] +function = "function.main:cli" + +[tool.uv.build-backend] +module-name = "function" +module-root = "" diff --git a/functions/compose-nebius-cluster/tests/test_fn.py b/functions/compose-nebius-cluster/tests/test_fn.py new file mode 100644 index 000000000..4c69b799b --- /dev/null +++ b/functions/compose-nebius-cluster/tests/test_fn.py @@ -0,0 +1,656 @@ +# Copyright 2026 The Modelplane Authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +"""Tests for the compose-nebius-cluster function.""" + +import dataclasses +import unittest + +from crossplane.function import logging, resource +from crossplane.function.proto.v1 import run_function_pb2 as fnv1 +from function import fn +from google.protobuf import duration_pb2 as durationpb +from google.protobuf import json_format +from google.protobuf import struct_pb2 as structpb +from models.ai.modelplane.infrastructure.nebiuscluster import v1alpha1 +from models.io.k8s.apimachinery.pkg.apis.meta import v1 as metav1 + + +@dataclasses.dataclass +class Case: + """A test case for compose-nebius-cluster.""" + + name: str + req: fnv1.RunFunctionRequest + want: fnv1.RunFunctionResponse + + +def setUpModule() -> None: + logging.configure(level=logging.Level.DISABLED) + + +# The Nebius ClusterProviderConfig the function reads the credentials +# Secret off. +_NEBIUS_PROVIDER_CONFIG = { + "apiVersion": "nebius.m.upbound.io/v1beta1", + "kind": "ClusterProviderConfig", + "metadata": {"name": "default"}, + "spec": { + "identity": {"type": "ServiceAccount"}, + "credentials": { + "source": "Secret", + "secretRef": { + "namespace": "crossplane-system", + "name": "nebius-credentials", + "key": "credentials.json", + }, + }, + "projectID": "project-e00test", + }, +} + +_PROVIDER_CONFIG_SELECTOR = fnv1.ResourceSelector( + api_version="nebius.m.upbound.io/v1beta1", + kind="ClusterProviderConfig", + match_name="default", +) + +# Name of the composed cloud-init Secret. Derived like the function derives +# it - the hash suffix depends only on the parent and child names. +_CLOUD_INIT_SECRET_NAME = resource.child_name("test-cluster", "cloud-init") + +# The cloud-init user data mounting the cache filesystem on every node. +_CLOUD_INIT = ( + "#cloud-config\n" + "runcmd:\n" + " - mkdir -p /mnt/data\n" + " - mount -t virtiofs modelplane-cache /mnt/data\n" + ' - printf "modelplane-cache /mnt/data virtiofs defaults,nofail 0 2\\n" >> /etc/fstab\n' +) + +# The cache filesystem attachment and cloud-init reference every node group +# template carries. +_TEMPLATE_CACHE_MOUNT = { + "filesystems": [ + { + "attachMode": "READ_WRITE", + "mountTag": "modelplane-cache", + "existingFilesystem": {"idSelector": {"matchControllerRef": True}}, + }, + ], + "cloudInitUserDataSecretRef": {"name": _CLOUD_INIT_SECRET_NAME, "key": "userData"}, +} + + +def _xr(pools: list[v1alpha1.NodePool]) -> dict: + """A NebiusCluster XR with the given node pools, as a request dict.""" + return v1alpha1.NebiusCluster( + metadata=metav1.ObjectMeta( + name="test-cluster", + namespace="modelplane-system", + ), + spec=v1alpha1.Spec( + nodePools=pools, + ), + ).model_dump(exclude_none=True, mode="json") + + +def _req( + pools: list[v1alpha1.NodePool], + observed_resources: dict[str, fnv1.Resource] | None = None, + *, + with_provider_config: bool = True, +) -> fnv1.RunFunctionRequest: + req = fnv1.RunFunctionRequest( + observed=fnv1.State( + composite=fnv1.Resource(resource=resource.dict_to_struct(_xr(pools))), + resources=observed_resources or {}, + ), + ) + if with_provider_config: + req.required_resources["nebius-provider-config"].items.append( + fnv1.Resource(resource=resource.dict_to_struct(_NEBIUS_PROVIDER_CONFIG)), + ) + return req + + +def _network() -> dict: + return { + "apiVersion": "vpc.nebius.m.upbound.io/v1beta1", + "kind": "Network", + "spec": { + "forProvider": {"name": "test-cluster"}, + }, + } + + +def _subnet() -> dict: + return { + "apiVersion": "vpc.nebius.m.upbound.io/v1beta1", + "kind": "Subnet", + "spec": { + "forProvider": { + "name": "test-cluster", + "networkIdSelector": {"matchControllerRef": True}, + "ipv4PrivatePools": {"useNetworkPools": True}, + }, + }, + } + + +def _cluster() -> dict: + return { + "apiVersion": "mk8s.nebius.m.upbound.io/v1beta1", + "kind": "Cluster", + "spec": { + "forProvider": { + "name": "test-cluster", + "controlPlane": { + "version": "1.34", + "subnetIdSelector": {"matchControllerRef": True}, + "endpoints": {"publicEndpoint": {}}, + }, + }, + "writeConnectionSecretToRef": {"name": "test-cluster-kubeconfig-55b57"}, + }, + } + + +def _filesystem() -> dict: + return { + "apiVersion": "compute.nebius.m.upbound.io/v1beta1", + "kind": "Filesystem", + "spec": { + "forProvider": { + "name": "test-cluster-cache", + "type": "NETWORK_SSD", + "sizeGibibytes": 1024, + }, + }, + } + + +def _cloud_init_secret() -> dict: + return { + "apiVersion": "v1", + "kind": "Secret", + "metadata": { + "name": _CLOUD_INIT_SECRET_NAME, + "namespace": "modelplane-system", + }, + "type": "Opaque", + "stringData": {"userData": _CLOUD_INIT}, + } + + +def _csi_release() -> dict: + return { + "apiVersion": "helm.m.crossplane.io/v1beta1", + "kind": "Release", + "metadata": {"namespace": "modelplane-system"}, + "spec": { + "managementPolicies": ["Observe", "Create", "Update"], + "providerConfigRef": { + "kind": "ProviderConfig", + "name": "test-cluster-kubeconfig-55b57", + }, + "forProvider": { + "chart": { + "name": "csi-mounted-fs-path", + "repository": "oci://cr.eu-north1.nebius.cloud/mk8s/helm", + "version": "0.1.6", + }, + "namespace": "kube-system", + "values": { + "dataDir": "/mnt/data/csi-mounted-fs-path-data/", + # The node plugin must tolerate the GPU taint so engine + # pods on GPU nodes can mount cache PVCs. + "tolerations": [ + { + "key": "nvidia.com/gpu", + "operator": "Exists", + "effect": "NoSchedule", + }, + ], + }, + }, + }, + } + + +def _storage_class() -> dict: + return { + "apiVersion": "kubernetes.m.crossplane.io/v1alpha1", + "kind": "Object", + "metadata": {"namespace": "modelplane-system"}, + "spec": { + "managementPolicies": ["Observe", "Create", "Update"], + "providerConfigRef": { + "kind": "ProviderConfig", + "name": "test-cluster-kubeconfig-55b57", + }, + "readiness": {"policy": "SuccessfulCreate"}, + "forProvider": { + "manifest": { + "apiVersion": "storage.k8s.io/v1", + "kind": "StorageClass", + "metadata": {"name": "modelplane-rwx-fs"}, + "provisioner": "mounted-fs-path.csi.nebius.ai", + "volumeBindingMode": "WaitForFirstConsumer", + }, + }, + }, + } + + +def _nodegroup_system() -> dict: + return { + "apiVersion": "mk8s.nebius.m.upbound.io/v1beta1", + "kind": "NodeGroup", + "spec": { + "forProvider": { + "name": "test-cluster-system", + "parentIdSelector": {"matchControllerRef": True}, + "version": "1.34", + "autoscaling": {"minNodeCount": 1, "maxNodeCount": 2}, + "template": { + "resources": {"platform": "cpu-d3", "preset": "4vcpu-16gb"}, + "bootDisk": {"sizeGibibytes": 100, "type": "NETWORK_SSD"}, + "networkInterfaces": [ + {"subnetIdSelector": {"matchControllerRef": True}}, + ], + **_TEMPLATE_CACHE_MOUNT, + "metadata": {"labels": {"modelplane.ai/pool": "system"}}, + }, + }, + }, + } + + +def _nodegroup_gpu(template_extra: dict, **for_provider_extra: object) -> dict: + """A GPU node group golden with the standard template, merged with the + given scaling config and extra template fields.""" + template = { + "resources": {"platform": "gpu-h100-sxm", "preset": "8gpu-128vcpu-1600gb"}, + "bootDisk": {"sizeGibibytes": 200, "type": "NETWORK_SSD"}, + "networkInterfaces": [ + {"subnetIdSelector": {"matchControllerRef": True}}, + ], + **_TEMPLATE_CACHE_MOUNT, + "metadata": { + "labels": { + "modelplane.ai/pool": "gpu-h100", + "modelplane.ai/gpu": "nvidia-h100", + }, + }, + "gpuSettings": {"driversPreset": "cuda13.0"}, + "taints": [ + {"key": "nvidia.com/gpu", "value": "true", "effect": "NO_SCHEDULE"}, + ], + } + template.update(template_extra) + return { + "apiVersion": "mk8s.nebius.m.upbound.io/v1beta1", + "kind": "NodeGroup", + "spec": { + "forProvider": { + "name": "test-cluster-gpu-h100", + "parentIdSelector": {"matchControllerRef": True}, + "version": "1.34", + "template": template, + **for_provider_extra, + }, + }, + } + + +def _provider_config(api_version: str, kind: str) -> dict: + return { + "apiVersion": api_version, + "kind": kind, + "metadata": {"name": "test-cluster-kubeconfig-55b57"}, + "spec": { + "credentials": { + "source": "Secret", + "secretRef": { + "name": "test-cluster-kubeconfig-55b57", + "namespace": "modelplane-system", + "key": "kubeconfig", + }, + }, + "identity": { + "type": "NebiusServiceAccountCredentials", + "source": "Secret", + "secretRef": { + "name": "nebius-credentials", + "namespace": "crossplane-system", + "key": "credentials.json", + }, + }, + }, + } + + +def _status(*, with_credentials: bool = True) -> dict: + secrets: list[dict] = [ + { + "type": "Kubeconfig", + "name": "test-cluster-kubeconfig-55b57", + "key": "kubeconfig", + }, + ] + if with_credentials: + secrets.append( + { + "type": "NebiusServiceAccountCredentials", + "name": "nebius-credentials", + "key": "credentials.json", + "namespace": "crossplane-system", + }, + ) + return { + "status": { + "secrets": secrets, + "cache": {"storageClassName": "modelplane-rwx-fs"}, + }, + } + + +def _observed_ready(desired: dict) -> fnv1.Resource: + """An observed variant of a desired resource with a Ready=True condition.""" + observed = { + **desired, + "status": { + "conditions": [ + { + "type": "Ready", + "status": "True", + "reason": "Available", + "lastTransitionTime": "2024-01-01T00:00:00Z", + }, + ], + }, + } + return fnv1.Resource(resource=resource.dict_to_struct(observed)) + + +_GPU_POOL = v1alpha1.NodePool( + name="gpu-h100", + role="GPU", + platform="gpu-h100-sxm", + preset="8gpu-128vcpu-1600gb", + diskSizeGb=200, + maxNodeCount=4, + gpu=v1alpha1.Gpu(acceleratorType="nvidia-h100"), +) + + +class TestFunctionRunner(unittest.IsolatedAsyncioTestCase): + """Tests for FunctionRunner.RunFunction.""" + + @classmethod + def setUpClass(cls) -> None: + cls.runner = fn.FunctionRunner() + + async def test_compose(self) -> None: + """The function composes Nebius mk8s cluster infrastructure.""" + cases = [ + Case( + name="first pass composes infra resources; autoscaling from maxNodeCount", + req=_req([_GPU_POOL]), + want=fnv1.RunFunctionResponse( + meta=fnv1.ResponseMeta(ttl=durationpb.Duration(seconds=60)), + desired=fnv1.State( + composite=fnv1.Resource(resource=resource.dict_to_struct(_status())), + resources={ + "network": fnv1.Resource(resource=resource.dict_to_struct(_network())), + "subnet": fnv1.Resource(resource=resource.dict_to_struct(_subnet())), + "cluster": fnv1.Resource(resource=resource.dict_to_struct(_cluster())), + "filesystem": fnv1.Resource(resource=resource.dict_to_struct(_filesystem())), + "cloud-init": fnv1.Resource( + resource=resource.dict_to_struct(_cloud_init_secret()), + ready=fnv1.READY_TRUE, + ), + # The CSI driver release and StorageClass aren't + # composed yet: the cluster isn't observed, so the + # ProviderConfigs can't reach it. + "nodegroup-system": fnv1.Resource(resource=resource.dict_to_struct(_nodegroup_system())), + # nodeCount defaults to 1 and minNodeCount is + # unset, so autoscaling starts at the node count. + "nodegroup-gpu-h100": fnv1.Resource( + resource=resource.dict_to_struct( + _nodegroup_gpu({}, autoscaling={"minNodeCount": 1, "maxNodeCount": 4}), + ), + ), + "provider-config-kubernetes": fnv1.Resource( + resource=resource.dict_to_struct( + _provider_config("kubernetes.m.crossplane.io/v1alpha1", "ProviderConfig"), + ), + ready=fnv1.READY_TRUE, + ), + "provider-config-helm": fnv1.Resource( + resource=resource.dict_to_struct( + _provider_config("helm.m.crossplane.io/v1beta1", "ProviderConfig"), + ), + ready=fnv1.READY_TRUE, + ), + }, + ), + context=structpb.Struct(), + ), + ), + Case( + name="provider config not yet fetched gates provider configs, not infra", + req=_req([_GPU_POOL], with_provider_config=False), + want=fnv1.RunFunctionResponse( + meta=fnv1.ResponseMeta(ttl=durationpb.Duration(seconds=60)), + desired=fnv1.State( + composite=fnv1.Resource( + resource=resource.dict_to_struct(_status(with_credentials=False)), + ), + resources={ + "network": fnv1.Resource(resource=resource.dict_to_struct(_network())), + "subnet": fnv1.Resource(resource=resource.dict_to_struct(_subnet())), + "cluster": fnv1.Resource(resource=resource.dict_to_struct(_cluster())), + "filesystem": fnv1.Resource(resource=resource.dict_to_struct(_filesystem())), + "cloud-init": fnv1.Resource( + resource=resource.dict_to_struct(_cloud_init_secret()), + ready=fnv1.READY_TRUE, + ), + "nodegroup-system": fnv1.Resource(resource=resource.dict_to_struct(_nodegroup_system())), + "nodegroup-gpu-h100": fnv1.Resource( + resource=resource.dict_to_struct( + _nodegroup_gpu({}, autoscaling={"minNodeCount": 1, "maxNodeCount": 4}), + ), + ), + }, + ), + results=[ + fnv1.Result( + severity=fnv1.SEVERITY_NORMAL, + message="Waiting for Nebius ClusterProviderConfig default", + ), + ], + context=structpb.Struct(), + ), + ), + Case( + name="fixed-size fabric pool composes a GPU cluster and fixedNodeCount", + req=_req( + [ + v1alpha1.NodePool( + name="gpu-h100", + role="GPU", + platform="gpu-h100-sxm", + preset="8gpu-128vcpu-1600gb", + diskSizeGb=200, + nodeCount=2, + fabric="fabric-2", + gpu=v1alpha1.Gpu(acceleratorType="nvidia-h100"), + ), + ] + ), + want=fnv1.RunFunctionResponse( + meta=fnv1.ResponseMeta(ttl=durationpb.Duration(seconds=60)), + desired=fnv1.State( + composite=fnv1.Resource(resource=resource.dict_to_struct(_status())), + resources={ + "network": fnv1.Resource(resource=resource.dict_to_struct(_network())), + "subnet": fnv1.Resource(resource=resource.dict_to_struct(_subnet())), + "cluster": fnv1.Resource(resource=resource.dict_to_struct(_cluster())), + "filesystem": fnv1.Resource(resource=resource.dict_to_struct(_filesystem())), + "cloud-init": fnv1.Resource( + resource=resource.dict_to_struct(_cloud_init_secret()), + ready=fnv1.READY_TRUE, + ), + "gpu-cluster-fabric-2": fnv1.Resource( + resource=resource.dict_to_struct( + { + "apiVersion": "compute.nebius.m.upbound.io/v1beta1", + "kind": "GpuCluster", + "metadata": {"labels": {"modelplane.ai/fabric": "fabric-2"}}, + "spec": { + "forProvider": { + "name": "test-cluster-fabric-2", + "infinibandFabric": "fabric-2", + }, + }, + } + ), + ), + "nodegroup-system": fnv1.Resource(resource=resource.dict_to_struct(_nodegroup_system())), + "nodegroup-gpu-h100": fnv1.Resource( + resource=resource.dict_to_struct( + _nodegroup_gpu( + { + "gpuCluster": { + "idSelector": { + "matchControllerRef": True, + "matchLabels": {"modelplane.ai/fabric": "fabric-2"}, + }, + }, + }, + fixedNodeCount=2, + ), + ), + ), + "provider-config-kubernetes": fnv1.Resource( + resource=resource.dict_to_struct( + _provider_config("kubernetes.m.crossplane.io/v1alpha1", "ProviderConfig"), + ), + ready=fnv1.READY_TRUE, + ), + "provider-config-helm": fnv1.Resource( + resource=resource.dict_to_struct( + _provider_config("helm.m.crossplane.io/v1beta1", "ProviderConfig"), + ), + ready=fnv1.READY_TRUE, + ), + }, + ), + context=structpb.Struct(), + ), + ), + Case( + name="marks managed resources ready from observed conditions", + req=_req( + [_GPU_POOL], + observed_resources={ + "network": _observed_ready(_network()), + "subnet": _observed_ready(_subnet()), + "cluster": _observed_ready(_cluster()), + "filesystem": _observed_ready(_filesystem()), + "release-csi-mounted-fs-path": _observed_ready(_csi_release()), + "nodegroup-system": _observed_ready(_nodegroup_system()), + "nodegroup-gpu-h100": _observed_ready( + _nodegroup_gpu({}, autoscaling={"minNodeCount": 1, "maxNodeCount": 4}), + ), + }, + ), + want=fnv1.RunFunctionResponse( + meta=fnv1.ResponseMeta(ttl=durationpb.Duration(seconds=60)), + desired=fnv1.State( + composite=fnv1.Resource(resource=resource.dict_to_struct(_status())), + resources={ + "network": fnv1.Resource( + resource=resource.dict_to_struct(_network()), + ready=fnv1.READY_TRUE, + ), + "subnet": fnv1.Resource( + resource=resource.dict_to_struct(_subnet()), + ready=fnv1.READY_TRUE, + ), + "cluster": fnv1.Resource( + resource=resource.dict_to_struct(_cluster()), + ready=fnv1.READY_TRUE, + ), + "filesystem": fnv1.Resource( + resource=resource.dict_to_struct(_filesystem()), + ready=fnv1.READY_TRUE, + ), + "cloud-init": fnv1.Resource( + resource=resource.dict_to_struct(_cloud_init_secret()), + ready=fnv1.READY_TRUE, + ), + # The cluster is observed, so the CSI driver + # release and StorageClass are composed too. + "release-csi-mounted-fs-path": fnv1.Resource( + resource=resource.dict_to_struct(_csi_release()), + ready=fnv1.READY_TRUE, + ), + "storage-class-rwx-fs": fnv1.Resource( + resource=resource.dict_to_struct(_storage_class()), + ready=fnv1.READY_TRUE, + ), + "nodegroup-system": fnv1.Resource( + resource=resource.dict_to_struct(_nodegroup_system()), + ready=fnv1.READY_TRUE, + ), + "nodegroup-gpu-h100": fnv1.Resource( + resource=resource.dict_to_struct( + _nodegroup_gpu({}, autoscaling={"minNodeCount": 1, "maxNodeCount": 4}), + ), + ready=fnv1.READY_TRUE, + ), + "provider-config-kubernetes": fnv1.Resource( + resource=resource.dict_to_struct( + _provider_config("kubernetes.m.crossplane.io/v1alpha1", "ProviderConfig"), + ), + ready=fnv1.READY_TRUE, + ), + "provider-config-helm": fnv1.Resource( + resource=resource.dict_to_struct( + _provider_config("helm.m.crossplane.io/v1beta1", "ProviderConfig"), + ), + ready=fnv1.READY_TRUE, + ), + }, + ), + context=structpb.Struct(), + ), + ), + ] + + # Every compose path declares the provider config requirement. + for case in cases: + case.want.requirements.resources["nebius-provider-config"].CopyFrom(_PROVIDER_CONFIG_SELECTOR) + + for case in cases: + with self.subTest(case.name): + got = await self.runner.RunFunction(case.req, None) + self.assertEqual( + json_format.MessageToDict(case.want), + json_format.MessageToDict(got), + "-want, +got", + ) diff --git a/functions/compose-serving-stack/function/fn.py b/functions/compose-serving-stack/function/fn.py index 5c8e04337..6d4c25ccb 100644 --- a/functions/compose-serving-stack/function/fn.py +++ b/functions/compose-serving-stack/function/fn.py @@ -364,12 +364,16 @@ def compose_provider_configs(self) -> None: None, ) if identity_secret: + # The identity entry may carry its own namespace - the Nebius + # credential lives with the Nebius ClusterProviderConfig's Secret + # rather than in this ServingStack's namespace. + identity_namespace = identity_secret.namespace or _namespace(self.xr.metadata) k8s_pc_spec.identity = k8spcv1alpha1.Identity( type=identity_secret.type, # ty: ignore[invalid-argument-type] # non-Kubeconfig types are exactly the provider identity types source="Secret", secretRef=k8spcv1alpha1.SecretRef( name=identity_secret.name, - namespace=_namespace(self.xr.metadata), + namespace=identity_namespace, key=identity_secret.key, ), ) @@ -378,7 +382,7 @@ def compose_provider_configs(self) -> None: source="Secret", secretRef=helmpcv1beta1.SecretRef( name=identity_secret.name, - namespace=_namespace(self.xr.metadata), + namespace=identity_namespace, key=identity_secret.key, ), ) @@ -644,6 +648,31 @@ def compose_node_feature_discovery(self) -> None: version=v.nodeFeatureDiscovery, # ty: ignore[invalid-argument-type] # XRD defaults this version and forbids null namespace="node-feature-discovery", provider_config=_pc_name(self.xr), + # The worker must run on the very nodes it is supposed to + # label: the DRA driver's kubelet plugin schedules only onto + # nodes carrying an NFD GPU label (feature.node.kubernetes.io/ + # pci-10de.present and friends, see the chart's kubeletPlugin + # affinity). But the cluster compositions taint GPU nodes with + # nvidia.com/gpu, and the NFD chart's worker tolerates nothing + # by default. Without this toleration the chain breaks + # silently: no worker on the GPU node, no pci-10de label, no + # kubelet plugin, no ResourceSlices and every GPU + # ResourceClaim stays unallocatable ("cannot allocate all + # claims") with all components looking healthy. The DRA + # driver itself already tolerates this taint by default; + # Exists matches every value (true on EKS/Nebius, present on + # GKE). + values={ + "worker": { + "tolerations": [ + { + "key": "nvidia.com/gpu", + "operator": "Exists", + "effect": "NoSchedule", + }, + ], + }, + }, ), ) diff --git a/functions/compose-serving-stack/tests/test_fn.py b/functions/compose-serving-stack/tests/test_fn.py index faf3342b0..7f071b44a 100644 --- a/functions/compose-serving-stack/tests/test_fn.py +++ b/functions/compose-serving-stack/tests/test_fn.py @@ -437,6 +437,19 @@ def _gaie_crd_observed() -> dict: "version": "0.18.3", }, "namespace": "node-feature-discovery", + # The worker labels GPU nodes for the DRA driver, so it must + # tolerate the GPU taint the cluster compositions apply. + "values": { + "worker": { + "tolerations": [ + { + "key": "nvidia.com/gpu", + "operator": "Exists", + "effect": "NoSchedule", + }, + ], + }, + }, }, "providerConfigRef": { "kind": "ProviderConfig", diff --git a/schemas/.lock.json b/schemas/.lock.json index fd8627874..1e364af6a 100644 --- a/schemas/.lock.json +++ b/schemas/.lock.json @@ -1 +1 @@ -{"packages":{"fs://apis":"a944c621e7433ac5cc6ead61170bc7b261c943d736c8a9ff7a3006f6341820f1","git://https://github.com/crossplane/crossplane/cluster/crds":"90d8b72ad8b829f0bcd7d7d5a98eaa0d579f244a","xpkg://xpkg.upbound.io/modelplane/provider-helm:v1.3.0-9a6fb4b":"sha256:af1858ee7dcabc9149bf2f8005bffb298961519c066b8e7c21a244039ccd066b","xpkg://xpkg.upbound.io/modelplane/provider-kubernetes:v1.2.1-070dae7":"sha256:718b481f5b760f5436e162e997fedf74c3b5e950c4f9d824a990973df071676b","xpkg://xpkg.upbound.io/upbound/provider-aws-ec2:v2.6.0":"sha256:acc26c8d2710e0306185b6c626a2f8c8fe0fdf89874e85efe7944a3668322865","xpkg://xpkg.upbound.io/upbound/provider-aws-efs:v2.6.0":"sha256:00f1bbbb3c0f1948b6dd45c841a083d63e41850f5a559a15580915311f404911","xpkg://xpkg.upbound.io/upbound/provider-aws-eks:v2.6.0":"sha256:5d144b19e188cb96c918aa7e4ccbc6759b8733ff09bd8ce412723c669aa3f763","xpkg://xpkg.upbound.io/upbound/provider-aws-iam:v2.6.0":"sha256:dbc5288589ccb302d527565680477f08477c280fc5c616dda95dfd558108a038","xpkg://xpkg.upbound.io/upbound/provider-gcp-cloudplatform:v2.6.0":"sha256:f1fe8bc55c474464642303e6fa8608c83e369b42ff12bb8a60a3e2d77339a52b","xpkg://xpkg.upbound.io/upbound/provider-gcp-compute:v2.6.0":"sha256:c7417c461d403f0d59a2dd83f242cebd5d738f9ad328e03ffe0c7b99ea251635","xpkg://xpkg.upbound.io/upbound/provider-gcp-container:v2.6.0":"sha256:b3f68d01ab2529026f1a5dd6d6215a2f499710fad4edd4850546bf6c756befb6"}} \ No newline at end of file +{"packages":{"fs://apis":"3a868b8388b31cece76f17f2eccba9245fd0da04866cc42fe9a7df7f2d17585e","git://https://github.com/crossplane/crossplane/cluster/crds":"90d8b72ad8b829f0bcd7d7d5a98eaa0d579f244a","xpkg://xpkg.upbound.io/modelplane/provider-helm:v1.3.0-9a6fb4b":"sha256:af1858ee7dcabc9149bf2f8005bffb298961519c066b8e7c21a244039ccd066b","xpkg://xpkg.upbound.io/modelplane/provider-kubernetes:v1.2.1-070dae7":"sha256:718b481f5b760f5436e162e997fedf74c3b5e950c4f9d824a990973df071676b","xpkg://xpkg.upbound.io/upbound/provider-aws-ec2:v2.6.0":"sha256:acc26c8d2710e0306185b6c626a2f8c8fe0fdf89874e85efe7944a3668322865","xpkg://xpkg.upbound.io/upbound/provider-aws-efs:v2.6.0":"sha256:00f1bbbb3c0f1948b6dd45c841a083d63e41850f5a559a15580915311f404911","xpkg://xpkg.upbound.io/upbound/provider-aws-eks:v2.6.0":"sha256:5d144b19e188cb96c918aa7e4ccbc6759b8733ff09bd8ce412723c669aa3f763","xpkg://xpkg.upbound.io/upbound/provider-aws-iam:v2.6.0":"sha256:dbc5288589ccb302d527565680477f08477c280fc5c616dda95dfd558108a038","xpkg://xpkg.upbound.io/upbound/provider-gcp-cloudplatform:v2.6.0":"sha256:f1fe8bc55c474464642303e6fa8608c83e369b42ff12bb8a60a3e2d77339a52b","xpkg://xpkg.upbound.io/upbound/provider-gcp-compute:v2.6.0":"sha256:c7417c461d403f0d59a2dd83f242cebd5d738f9ad328e03ffe0c7b99ea251635","xpkg://xpkg.upbound.io/upbound/provider-gcp-container:v2.6.0":"sha256:b3f68d01ab2529026f1a5dd6d6215a2f499710fad4edd4850546bf6c756befb6","xpkg://xpkg.upbound.io/upbound/provider-nebius:v1.0.1":"sha256:f14e09e8e35c2d4bf2da527191065c3e457850c404238fa4619493e0c2bfd13f"}} \ No newline at end of file diff --git a/schemas/python/models/ai/modelplane/inferenceclass/v1alpha1.py b/schemas/python/models/ai/modelplane/inferenceclass/v1alpha1.py index b9cea5a88..4866728d7 100644 --- a/schemas/python/models/ai/modelplane/inferenceclass/v1alpha1.py +++ b/schemas/python/models/ai/modelplane/inferenceclass/v1alpha1.py @@ -127,10 +127,41 @@ class Gke(BaseModel): machineType: constr(min_length=1) +class AcceleratorModel1(BaseModel): + count: conint(ge=1, le=16) + type: constr(min_length=1, max_length=63) + """ + GPU accelerator type (e.g. nvidia-h100, nvidia-l40s). Informational - reported on the consuming InferenceCluster's status. + """ + + +class Nebius(BaseModel): + accelerator: AcceleratorModel1 + """ + GPU accelerator to attach when provisioning the node group. Provisioning input only: the scheduler matches against spec.devices, not this block. + """ + diskSizeGb: conint(ge=10) | None = 100 + driversPreset: Literal['cuda12', 'cuda12.4', 'cuda12.8', 'cuda13.0'] | None = ( + 'cuda13.0' + ) + """ + NVIDIA driver stack mk8s preinstalls on the pool's nodes. Valid values depend on the platform and Kubernetes version. Defaults to the only preset mk8s implements on the default Kubernetes version; older presets remain for older versions. + """ + platform: constr(min_length=1, max_length=63) + """ + Nebius compute platform (e.g. gpu-h100-sxm, gpu-l40s-a). Together with preset this determines the GPU model and count; the accelerator block below is informational. + """ + preset: constr(min_length=1, max_length=63) + """ + Resource preset within the platform (e.g. 8gpu-128vcpu-1600gb). Determines the GPU, vCPU, and memory shape of each node. + """ + + class Provisioning(BaseModel): eks: Eks | None = None gke: Gke | None = None - provider: Literal['GKE', 'EKS'] + nebius: Nebius | None = None + provider: Literal['GKE', 'EKS', 'Nebius'] class Spec(BaseModel): diff --git a/schemas/python/models/ai/modelplane/inferencecluster/v1alpha1.py b/schemas/python/models/ai/modelplane/inferencecluster/v1alpha1.py index 339a8345e..d64ae9cc7 100644 --- a/schemas/python/models/ai/modelplane/inferencecluster/v1alpha1.py +++ b/schemas/python/models/ai/modelplane/inferencecluster/v1alpha1.py @@ -70,6 +70,13 @@ class Gke(BaseModel): region: constr(min_length=1, max_length=32) +class Nebius(BaseModel): + kubernetesVersion: str | None = '1.34' + """ + mk8s cluster Kubernetes version. Defaults to a version where Dynamic Resource Allocation (DRA) is generally available. + """ + + class Cluster(BaseModel): eks: Eks | None = None """ @@ -83,7 +90,11 @@ class Cluster(BaseModel): """ GKE cluster configuration. Required when source is GKE. """ - source: Literal['GKE', 'EKS', 'Existing'] + nebius: Nebius | None = None + """ + Nebius mk8s cluster configuration. Required when source is Nebius; may be empty, since every field has a default. The cluster is created in the project the Nebius ClusterProviderConfig named default sets as its projectID; Nebius projects are bound to a region, so the project also determines where the cluster runs. + """ + source: Literal['GKE', 'EKS', 'Nebius', 'Existing'] """ Cluster provisioning method. """ @@ -130,6 +141,24 @@ class CapacityBlock(BaseModel): """ +class Infiniband(BaseModel): + fabric: constr(min_length=1, max_length=63) + """ + Identifier of the physical InfiniBand fabric to join (e.g. fabric-2). This selects existing Nebius infrastructure, not a name for a new resource: fabrics are per-region - see https://docs.nebius.com/compute/clusters/gpu#fabrics - and multi-node GPU capacity is allocated on specific fabrics, so use the fabric your capacity lives on. + """ + + +class Fabric(BaseModel): + infiniband: Infiniband | None = None + """ + InfiniBand fabric configuration. Required when type is InfiniBand. + """ + type: Literal['None', 'EFA', 'InfiniBand'] | None = 'None' + """ + Fabric technology. None uses standard VPC networking (TCP). EFA attaches Elastic Fabric Adapter interfaces to each node for GPUDirect RDMA across nodes; EKS only, and only useful on EFA-capable instance types (e.g. p5en.48xlarge). When any pool sets EFA, Modelplane installs the EFA DRA driver on the cluster and the gang's pods claim EFA devices alongside their GPUs. InfiniBand places the pool's nodes in a GPU cluster on a physical InfiniBand fabric for GPUDirect RDMA across nodes; Nebius only, and only useful on InfiniBand-capable platforms (e.g. gpu-h100-sxm). + """ + + class NodePool(BaseModel): capacityBlock: CapacityBlock | None = None """ @@ -139,9 +168,9 @@ class NodePool(BaseModel): """ Name of the InferenceClass describing this pool's hardware. """ - fabric: Literal['None', 'EFA'] | None = 'None' + fabric: Fabric | None = None """ - High-performance node-to-node fabric for multi-node engines. None uses standard VPC networking (ENA/TCP). EFA attaches Elastic Fabric Adapter interfaces to each node for GPUDirect RDMA across nodes, so a gang's tensor-parallel traffic isn't capped by TCP. EKS only. Only useful on EFA-capable instance types (e.g. p5en.48xlarge). When any pool sets EFA, Modelplane installs the EFA DRA driver on the cluster and the gang's pods claim EFA devices alongside their GPUs. + High-performance node-to-node fabric for multi-node engines, so a gang's tensor-parallel traffic isn't capped by TCP. Omit for standard VPC networking. """ maxNodeCount: conint(ge=1) | None = None """ diff --git a/schemas/python/models/ai/modelplane/infrastructure/nebiuscluster/__init__.py b/schemas/python/models/ai/modelplane/infrastructure/nebiuscluster/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/ai/modelplane/infrastructure/nebiuscluster/v1alpha1.py b/schemas/python/models/ai/modelplane/infrastructure/nebiuscluster/v1alpha1.py new file mode 100644 index 000000000..1397bc8a3 --- /dev/null +++ b/schemas/python/models/ai/modelplane/infrastructure/nebiuscluster/v1alpha1.py @@ -0,0 +1,206 @@ +# generated by datamodel-codegen: +# filename: workdir/infrastructure_modelplane_ai_v1alpha1_nebiuscluster.yaml + +from __future__ import annotations + +from typing import Literal + +from pydantic import AwareDatetime, BaseModel, Field, conint, constr + +from .....io.k8s.apimachinery.pkg.apis.meta import v1 + + +class CompositionRef(BaseModel): + name: str + + +class CompositionRevisionRef(BaseModel): + name: str + + +class CompositionRevisionSelector(BaseModel): + matchLabels: dict[str, str] + + +class CompositionSelector(BaseModel): + matchLabels: dict[str, str] + + +class ResourceRef(BaseModel): + apiVersion: str + kind: str + name: str | None = None + + +class Crossplane(BaseModel): + compositionRef: CompositionRef | None = None + compositionRevisionRef: CompositionRevisionRef | None = None + compositionRevisionSelector: CompositionRevisionSelector | None = None + compositionSelector: CompositionSelector | None = None + compositionUpdatePolicy: Literal['Automatic', 'Manual'] | None = None + resourceRefs: list[ResourceRef] | None = None + + +class Gpu(BaseModel): + acceleratorType: constr(min_length=1, max_length=63) + """ + GPU accelerator type (e.g. nvidia-h100, nvidia-l40s). Used to label GPU nodes; the actual GPU and count are determined by the platform and preset. + """ + driversPreset: Literal['cuda12', 'cuda12.4', 'cuda12.8', 'cuda13.0'] | None = ( + 'cuda13.0' + ) + """ + NVIDIA driver stack mk8s preinstalls on the group's nodes. Valid values depend on the platform and Kubernetes version. Defaults to the only preset mk8s implements on the default Kubernetes version; older presets remain for older versions. + """ + + +class NodePool(BaseModel): + diskSizeGb: conint(ge=10, le=65536) | None = 100 + """ + Boot disk size in GB. + """ + fabric: constr(min_length=1, max_length=63) | None = None + """ + Identifier of the physical InfiniBand fabric to join (e.g. fabric-2), for GPUDirect RDMA across nodes in multi-node engines. This selects existing Nebius infrastructure, not a name for a new resource: fabrics are per-region - see https://docs.nebius.com/compute/clusters/gpu#fabrics - and multi-node GPU capacity is allocated on specific fabrics, so use the fabric your capacity lives on. When set, Modelplane composes a GPU cluster on that fabric and places the group's nodes in it. Only valid on InfiniBand-capable platforms (e.g. gpu-h100-sxm). Omit for standard VPC networking. + """ + gpu: Gpu | None = None + """ + GPU configuration. Required when role is GPU. + """ + maxNodeCount: conint(ge=1, le=1000) | None = None + """ + Maximum number of nodes for autoscaling. When set the node group autoscales between minNodeCount (or nodeCount) and this; mk8s autoscaling is server-side, no in-cluster autoscaler is installed. Omit for fixed-size groups - unlike other clouds there is no default, because mk8s node groups are either fixed size or autoscaled, never both. + """ + minNodeCount: conint(ge=0, le=1000) | None = None + """ + Minimum number of nodes for autoscaling. Defaults to nodeCount when maxNodeCount is set. Requires maxNodeCount. + """ + name: constr(min_length=1, max_length=40) + """ + Unique name for this node group. Used as a suffix in the mk8s NodeGroup resource name. + """ + nodeCount: conint(ge=0, le=1000) | None = 1 + """ + Number of nodes. Fixed unless maxNodeCount enables autoscaling. + """ + platform: constr(min_length=1, max_length=63) + """ + Nebius compute platform for the group's nodes (e.g. gpu-h100-sxm, gpu-l40s-a, cpu-d3). Together with preset this replaces the instance type used by other clouds. + """ + preset: constr(min_length=1, max_length=63) + """ + Resource preset within the platform (e.g. 8gpu-128vcpu-1600gb, 4vcpu-16gb). Determines the GPU, vCPU, and memory shape of each node. + """ + role: Literal['System', 'GPU'] + """ + Determines what workloads this group runs. System groups host controllers, gateways, and infrastructure. GPU groups host inference workloads and are tainted to exclude non-GPU pods. + """ + + +class Spec(BaseModel): + crossplane: Crossplane | None = None + """ + Configures how Crossplane will reconcile this composite resource + """ + kubernetesVersion: constr(min_length=1, max_length=16) | None = '1.34' + """ + mk8s cluster Kubernetes version. Must be a version mk8s currently supports. Defaults to a version where Dynamic Resource Allocation (how GPUs bind to pods) is generally available. + """ + nodePools: list[NodePool] = Field(..., max_length=8, min_length=1) + """ + Node groups for the cluster. At least one System pool is required for controllers and infrastructure workloads. + """ + + +class Cache(BaseModel): + storageClassName: constr(max_length=253) | None = None + """ + Name of the Modelplane-managed ReadWriteMany StorageClass composed on this cluster for ModelCache PVCs. ModelCache reads this to target the cache PVC. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + message: str | None = None + observedGeneration: int | None = None + reason: str + status: str + type: str + + +class Secret(BaseModel): + key: constr(max_length=253) + """ + Key within the Secret that holds the credential data. + """ + name: constr(max_length=253) + """ + Name of the Secret. + """ + namespace: constr(max_length=253) | None = None + """ + Namespace of the Secret, when it isn't this NebiusCluster's namespace. Set on the credentials entry when the credential is reused from the Nebius ClusterProviderConfig's Secret. + """ + type: Literal['Kubeconfig', 'NebiusServiceAccountCredentials'] + """ + The type of credential this secret contains. Kubeconfig contains a kubeconfig file with the cluster endpoint and CA certificate. NebiusServiceAccountCredentials contains a Nebius service account JSON key that authenticates to the cluster via Nebius IAM. + """ + + +class Status(BaseModel): + cache: Cache | None = None + """ + Observed ModelCache RWX storage state, served by the Nebius shared filesystem mounted on every node group and Nebius's csi-mounted-fs-path CSI driver. + """ + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + secrets: list[Secret] | None = None + """ + Secrets produced by or passed through this cluster. Consumers use these to authenticate to the cluster. Secrets are in the same namespace as this NebiusCluster unless an entry says otherwise. + """ + + +class NebiusCluster(BaseModel): + apiVersion: Literal['infrastructure.modelplane.ai/v1alpha1'] | None = ( + 'infrastructure.modelplane.ai/v1alpha1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['NebiusCluster'] | None = 'NebiusCluster' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NebiusClusterSpec defines the desired state of NebiusCluster. + """ + status: Status | None = None + """ + NebiusClusterStatus defines the observed state of NebiusCluster. + """ + + +class NebiusClusterList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[NebiusCluster] + """ + List of nebiusclusters. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/ai/modelplane/infrastructure/servingstack/v1alpha1.py b/schemas/python/models/ai/modelplane/infrastructure/servingstack/v1alpha1.py index 57a03ba46..5eb14aae0 100644 --- a/schemas/python/models/ai/modelplane/infrastructure/servingstack/v1alpha1.py +++ b/schemas/python/models/ai/modelplane/infrastructure/servingstack/v1alpha1.py @@ -76,6 +76,10 @@ class Secret(BaseModel): """ Name of the Secret. """ + namespace: constr(max_length=253) | None = None + """ + Namespace of the Secret, when it isn't this ServingStack's namespace. Set on cloud identity entries whose credential lives with the cloud provider's ProviderConfig. + """ type: Literal[ 'Kubeconfig', 'GoogleApplicationCredentials', @@ -133,7 +137,7 @@ class Spec(BaseModel): """ secrets: list[Secret] = Field(..., max_length=8, min_length=1) """ - Secrets used to authenticate to the target cluster. Typically sourced from a GKECluster's status.secrets. All secrets must be in the same namespace as this ServingStack. A Kubeconfig secret is required. If a cloud identity secret is present, the serving stack authenticates as that identity instead of relying on the kubeconfig's embedded credentials. + Secrets used to authenticate to the target cluster. Typically sourced from a GKECluster's status.secrets. Secrets are in the same namespace as this ServingStack unless an entry says otherwise. A Kubeconfig secret is required. If a cloud identity secret is present, the serving stack authenticates as that identity instead of relying on the kubeconfig's embedded credentials. """ versions: Versions | None = None """ diff --git a/schemas/python/models/io/upbound/m/nebius/__init__.py b/schemas/python/models/io/upbound/m/nebius/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/clusterproviderconfig/__init__.py b/schemas/python/models/io/upbound/m/nebius/clusterproviderconfig/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/clusterproviderconfig/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/clusterproviderconfig/v1beta1.py new file mode 100644 index 000000000..2b6fd7595 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/clusterproviderconfig/v1beta1.py @@ -0,0 +1,205 @@ +# generated by datamodel-codegen: +# filename: workdir/nebius_m_upbound_io_v1beta1_clusterproviderconfig.yaml + +from __future__ import annotations + +from typing import Literal + +from pydantic import AwareDatetime, BaseModel + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Env(BaseModel): + name: str + """ + Name is the name of an environment variable. + """ + + +class Fs(BaseModel): + path: str + """ + Path is a filesystem path. + """ + + +class SecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Credentials(BaseModel): + env: Env | None = None + """ + Env is a reference to an environment variable that contains credentials + that must be used to connect to the provider. + """ + fs: Fs | None = None + """ + Fs is a reference to a filesystem location that contains credentials that + must be used to connect to the provider. + """ + secretRef: SecretRef | None = None + """ + A SecretRef is a reference to a secret key that contains the credentials + that must be used to connect to the provider. + """ + source: Literal['None', 'Secret', 'InjectedIdentity', 'Environment', 'Filesystem'] + """ + Source of the provider credentials. + """ + + +class Identity(BaseModel): + type: Literal['Token', 'ServiceAccount'] + """ + Type specifies the authentication method. + Token: authenticate using a static IAM token from the credentials secret key "token". + ServiceAccount: authenticate using a service-account key (account_id, public_key_id, + private_key) from the credentials secret. + """ + + +class ExponentialFailureRateLimiter(BaseModel): + baseDelay: str | None = None + """ + BaseDelay is the initial delay between retries. + """ + maxDelay: str | None = None + """ + MaxDelay is the maximum delay between retries. + """ + + +class ReconciliationPolicy(BaseModel): + exponentialFailureRateLimiter: ExponentialFailureRateLimiter | None = None + """ + ExponentialFailureRateLimiter, when set, overrides the parameters of the + exponential failure rate limiter used to schedule retries for the + managed resource that this policy applies to. + """ + + +class Spec(BaseModel): + credentials: Credentials + """ + Credentials required to authenticate to this provider. + """ + identity: Identity + """ + Identity specifies the authentication identity configuration. + """ + projectID: str | None = None + """ + ProjectID is the Nebius project ID used as the default parent for + project-parented resources. Individual resources may override it via + spec.forProvider.parentId. Optional. + """ + reconciliationPolicy: ReconciliationPolicy | None = None + """ + ReconciliationPolicy configures how a managed resource is reconciled. + It currently allows overriding the controller's failure rate limiter + parameters on a per-resource basis via ExponentialFailureRateLimiter. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + users: int | None = None + """ + Users of this provider configuration. + """ + + +class ClusterProviderConfig(BaseModel): + apiVersion: Literal['nebius.m.upbound.io/v1beta1'] | None = ( + 'nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ClusterProviderConfig'] | None = 'ClusterProviderConfig' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + A ProviderConfigSpec defines the desired state of a cluster-scoped + ClusterProviderConfig. Its credential secret references carry an explicit + namespace, because a cluster-scoped config can reference secrets in any + namespace. The namespaced ProviderConfig uses NamespacedProviderConfigSpec + instead, which omits the namespace. + """ + status: Status | None = None + """ + A ProviderConfigStatus reflects the observed state of a ProviderConfig. + """ + + +class ClusterProviderConfigList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ClusterProviderConfig] + """ + List of clusterproviderconfigs. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/compute/__init__.py b/schemas/python/models/io/upbound/m/nebius/compute/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/compute/disk/__init__.py b/schemas/python/models/io/upbound/m/nebius/compute/disk/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/compute/disk/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/compute/disk/v1beta1.py new file mode 100644 index 000000000..80cd01299 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/compute/disk/v1beta1.py @@ -0,0 +1,585 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_m_upbound_io_v1beta1_disk.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class DiskEncryption(BaseModel): + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `DISK_ENCRYPTION_UNSPECIFIED` - No encryption is applied unless explicitly specified. + - `DISK_ENCRYPTION_MANAGED`: + Enables encryption using the platform's default root key from KMS. + Available for disks with NETWORK_SSD_NON_REPLICATED and NETWORK_SSD_IO_M3 types only. + """ + + +class SourceImageFamily(BaseModel): + imageFamily: str | None = None + """ + (String) + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + """ + + +class ForProvider(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class InitProvider(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class LockState(BaseModel): + images: list[str] | None = None + """ + (List of String) : + : + + Disk is locked for deletion and for read-write operations while image is being created. + Here is the list of these images. + """ + + +class Status(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + """ + lockState: LockState | None = None + """ + write. (see below for nested schema) + """ + managedBy: str | None = None + """ + (String) : + : + + Indicates whether the disk is deleted along with an instance. + Set only for disks declared in the instance spec. + If set, the value is the instance ID that manages this disk's lifecycle (the disk is deleted when that instance is deleted). + To change this value, update the instance specification (see AttachedDiskSpec.type). + """ + readOnlyAttachments: list[str] | None = None + """ + (List of String) + """ + readWriteAttachment: str | None = None + """ + (String) : + : + + Current read-write owner (instance ID). + May refer to an instance in any state, including stopped + (this semantics is preserved for backward compatibility). + Reassigned on disk detach, instance deletion, or ownership transfer. + Ownership transfer occurs when this disk is explicitly attached to another instance + or when a VM with this disk attached starts while the current owner is stopped. + """ + reconciling: bool | None = None + """ + (Boolean) Indicates whether there is an ongoing operation + Indicates whether there is an ongoing operation + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + """ + sourceImageCpuArchitecture: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `SOURCE_IMAGE_CPU_UNSPECIFIED` + - `AMD64` + - `ARM64` + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `READY` + - `UPDATING` + - `DELETING` + - `ERROR` - Indicates that error happened during disk creation, and the disk cannot be recovered. + - `BROKEN` - Indicates that an error has occurred during the disk's life cycle, and the disk is broken or unhealthy, but can still be recovered. + """ + stateDescription: str | None = None + """ + (String) + """ + + +class AtProvider(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Disk(BaseModel): + apiVersion: Literal['compute.nebius.m.upbound.io/v1beta1'] | None = ( + 'compute.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Disk'] | None = 'Disk' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + DiskSpec defines the desired state of Disk + """ + status: StatusModel | None = None + """ + DiskStatus defines the observed state of Disk. + """ + + +class DiskList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Disk] + """ + List of disks. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/compute/filesystem/__init__.py b/schemas/python/models/io/upbound/m/nebius/compute/filesystem/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/compute/filesystem/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/compute/filesystem/v1beta1.py new file mode 100644 index 000000000..64fe90cbc --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/compute/filesystem/v1beta1.py @@ -0,0 +1,399 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_m_upbound_io_v1beta1_filesystem.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + blockSizeBytes: float | None = None + """ + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + forbidDeletion: bool | None = None + """ + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + type: str | None = None + """ + : + + The Shared Filesystem type determines its limits and performance characteristics. + For details, see https://docs.nebius.com/compute/storage/types#filesystems-types + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` - the list of available types will be clarified later, it is not final version + - `NETWORK_HDD` + - `WEKA` + - `VAST` + """ + + +class InitProvider(BaseModel): + blockSizeBytes: float | None = None + """ + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + forbidDeletion: bool | None = None + """ + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + type: str | None = None + """ + : + + The Shared Filesystem type determines its limits and performance characteristics. + For details, see https://docs.nebius.com/compute/storage/types#filesystems-types + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` - the list of available types will be clarified later, it is not final version + - `NETWORK_HDD` + - `WEKA` + - `VAST` + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + blockSizeBytes: float | None = None + readOnlyAttachments: list[str] | None = None + readWriteAttachments: list[str] | None = None + reconciling: bool | None = None + """ + Indicates whether there is an ongoing operation + """ + sizeBytes: float | None = None + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `READY` + - `UPDATING` + - `DELETING` + - `ERROR` + """ + stateDescription: str | None = None + + +class AtProvider(BaseModel): + blockSizeBytes: float | None = None + """ + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + forbidDeletion: bool | None = None + """ + Prevents deletion whilst set + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + sizeBytes: float | None = None + """ + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + status: Status | None = None + type: str | None = None + """ + : + + The Shared Filesystem type determines its limits and performance characteristics. + For details, see https://docs.nebius.com/compute/storage/types#filesystems-types + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` - the list of available types will be clarified later, it is not final version + - `NETWORK_HDD` + - `WEKA` + - `VAST` + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Filesystem(BaseModel): + apiVersion: Literal['compute.nebius.m.upbound.io/v1beta1'] | None = ( + 'compute.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Filesystem'] | None = 'Filesystem' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FilesystemSpec defines the desired state of Filesystem + """ + status: StatusModel | None = None + """ + FilesystemStatus defines the observed state of Filesystem. + """ + + +class FilesystemList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Filesystem] + """ + List of filesystems. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/compute/gpucluster/__init__.py b/schemas/python/models/io/upbound/m/nebius/compute/gpucluster/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/compute/gpucluster/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/compute/gpucluster/v1beta1.py new file mode 100644 index 000000000..06672cd30 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/compute/gpucluster/v1beta1.py @@ -0,0 +1,276 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_m_upbound_io_v1beta1_gpucluster.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + infinibandFabric: str | None = None + """ + : + + The identifier of the physical InfiniBand fabric to connect GPU instances to. + For details, see https://docs.nebius.com/compute/clusters/gpu#fabrics + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + infinibandFabric: str | None = None + """ + : + + The identifier of the physical InfiniBand fabric to connect GPU instances to. + For details, see https://docs.nebius.com/compute/clusters/gpu#fabrics + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Instance(BaseModel): + instanceId: str | None = None + path: list[str] | None = None + + +class InfinibandTopologyPath(BaseModel): + instances: list[Instance] | None = None + + +class Status(BaseModel): + infinibandTopologyPath: InfinibandTopologyPath | None = None + instances: list[str] | None = None + reconciling: bool | None = None + """ + Indicates whether there is an ongoing operation + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + infinibandFabric: str | None = None + """ + : + + The identifier of the physical InfiniBand fabric to connect GPU instances to. + For details, see https://docs.nebius.com/compute/clusters/gpu#fabrics + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class GpuCluster(BaseModel): + apiVersion: Literal['compute.nebius.m.upbound.io/v1beta1'] | None = ( + 'compute.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['GpuCluster'] | None = 'GpuCluster' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + GpuClusterSpec defines the desired state of GpuCluster + """ + status: StatusModel | None = None + """ + GpuClusterStatus defines the observed state of GpuCluster. + """ + + +class GpuClusterList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[GpuCluster] + """ + List of gpuclusters. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/compute/instance/__init__.py b/schemas/python/models/io/upbound/m/nebius/compute/instance/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/compute/instance/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/compute/instance/v1beta1.py new file mode 100644 index 000000000..108097824 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/compute/instance/v1beta1.py @@ -0,0 +1,1402 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_m_upbound_io_v1beta1_instance.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ExistingDisk(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a Disk in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Disk in compute to populate id. + """ + + +class DiskEncryption(BaseModel): + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `DISK_ENCRYPTION_UNSPECIFIED` - No encryption is applied unless explicitly specified. + - `DISK_ENCRYPTION_MANAGED`: + Enables encryption using the platform's default root key from KMS. + Available for disks with NETWORK_SSD_NON_REPLICATED and NETWORK_SSD_IO_M3 types only. + """ + + +class SourceImageFamily(BaseModel): + imageFamily: str | None = None + """ + (String) + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + """ + + +class Spec(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class ManagedDisk(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with disk resource. + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Name of a dependent disk. + Use it to convert an ExistingDisk to a dependent disk. + Changing the name will replace the disk and cause data loss. + """ + spec: Spec | None = None + """ + (Attributes) Specification of a dependent disk to be created. (see below for nested schema) + """ + + +class BootDisk(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + deviceId: str | None = None + """ + defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + Specifies the user-defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + """ + existingDisk: ExistingDisk | None = None + """ + (Attributes) : + """ + managedDisk: ManagedDisk | None = None + """ + (Attributes) : + """ + + +class CloudInitUserDataSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class ExistingFilesystem(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a Filesystem in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Filesystem in compute to populate id. + """ + + +class Filesystem(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + existingFilesystem: ExistingFilesystem | None = None + """ + (Attributes) (see below for nested schema) + """ + mountTag: str | None = None + """ + defined identifier, allowing to use it as a device in mount command. + Specifies the user-defined identifier, allowing to use it as a device in mount command. + """ + + +class GpuCluster(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + If you want to interconnect several instances in a GPU cluster via NVIDIA InfiniBand, + set the ID of an existing GPU cluster. + You can only add the VM to the cluster when creating the VM. + For details, see https://docs.nebius.com/compute/clusters/gpu + """ + idRef: IdRef | None = None + """ + Reference to a GpuCluster in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a GpuCluster in compute to populate id. + """ + + +class PassthroughGroup(BaseModel): + requested: bool | None = None + """ + (Boolean) : + : + + Passthrough local disks from the underlying host. + + Devices are expected to appear in the guest as NVMe devices (nvme0, nvme1, ...), + but the exact number depends on the preset. + Enabled only when this field is explicitly set. + """ + + +class LocalDisks(BaseModel): + passthroughGroup: PassthroughGroup | None = None + """ + (Attributes) : + """ + + +class Alias(BaseModel): + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + ID of allocation + """ + + +class IpAddress(BaseModel): + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier if it was created before. + """ + + +class PublicIpAddress(BaseModel): + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier if it was created before. + """ + static: bool | None = None + """ + (Boolean) : + : + + If false - Allocation will be created/deleted during NetworkInterface.Allocate/NetworkInterface.Deallocate + If true - Allocation will be created/deleted during NetworkInterface.Create/NetworkInterface.Delete + False by default + """ + + +class SecurityGroup(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Security group identifier + """ + idRef: IdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate id. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class NetworkInterface(BaseModel): + aliases: list[Alias] | None = None + """ + (Attributes List) Assign ranges of IP addresses as aliases (see below for nested schema) + """ + ipAddress: IpAddress | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Interface name + Value of this field configures the name of the network interface inside VM's OS. + Longer values will persist in the specification but will be truncated to 15 symbols before being passed to VM configuration. + """ + publicIpAddress: PublicIpAddress | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroup] | None = None + """ + (Attributes List) : + """ + subnetId: str | None = None + """ + (String) Subnet ID + Subnet ID + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class Preemptible(BaseModel): + onPreemption: str | None = None + """ + (String) : + : + + Specifies what happens when the VM is preempted. The only supported value is STOP: + Compute stops the VM without deleting or restarting it. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `STOP` + """ + priority: float | None = None + """ + (Number, Deprecated) + """ + + +class ReservationPolicy(BaseModel): + policy: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `AUTO`: + 1) Will try to launch instance in any reservation_ids if provided. + 2) Will try to launch instance in any of the available capacity block. + 3) Will try to launch instance in PAYG if 1 & 2 are not satisfied. + + - `FORBID`: + The instance is launched only using on-demand (PAYG) capacity. + No attempt is made to find or use a Capacity Block. + It's an error to provide reservation_ids with policy = FORBID + + - `STRICT`: + 1) Will try to launch the instance in Capacity Blocks from reservation_ids if provided. + 2) If reservation_ids are not provided will try to launch instance in suitable & available Capacity Block. + 3) Fail otherwise. + """ + reservationIds: list[str] | None = None + """ + (List of String) Capacity block groups, order matters + Capacity block groups, order matters + """ + + +class Resources(BaseModel): + platform: str | None = None + """ + (String) + """ + preset: str | None = None + """ + (String) + """ + + +class SecondaryDisk(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + deviceId: str | None = None + """ + defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + Specifies the user-defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + """ + existingDisk: ExistingDisk | None = None + """ + (Attributes) : + """ + managedDisk: ManagedDisk | None = None + """ + (Attributes) : + """ + + +class ServiceAccountIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ServiceAccountIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Specified boot disk attached to the instance. (see below for nested schema) + """ + cloudInitUserDataSecretRef: CloudInitUserDataSecretRef | None = None + """ + (String, Sensitive) : + : + + Data in cloud-init format for customizing instance initialization. + For details, see https://docs.nebius.com/compute/virtual-machines/manage#user-data + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) List of Shared Filesystems attached to the instance. (see below for nested schema) + """ + gpuCluster: GpuCluster | None = None + """ + (Attributes) : + """ + hostname: str | None = None + """ + (String) : + : + + Instance's hostname. Used to generate default DNS record in format `..compute.internal.` + or `..compute.internal.` if hostname is not specified. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkInterfaces: list[NetworkInterface] | None = None + """ + (Attributes List) : + """ + nvlInstanceGroupId: str | None = None + """ + (String) NVLink Instance Group ID associated with the VM + NVLink Instance Group ID associated with the VM + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + preemptible: Preemptible | None = None + """ + (Attributes) : + """ + recoveryPolicy: str | None = None + """ + (String) : + : + + Recovery policy defines how the instance will be treated in case of a failure. + Common source of failure is a host failure, but it can be any other failure. + Instance undergoing a guest shutdown (poweroff, etc.) will be subject to recovery policy, meaning that it could + be restarted and billed accordingly. Stop instance via API or UI to stop it to avoid recovering. + - If set to RECOVER, instance will be restarted, if possible. It could be restarted on the same host or on another host. + - If set to FAIL, instance will be stopped and not restarted. + + #### Supported values + + Possible values: + + - `RECOVER` + - `FAIL` + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) (see below for nested schema) + """ + resources: Resources | None = None + """ + (Attributes) : + """ + secondaryDisks: list[SecondaryDisk] | None = None + """ + (Attributes List) List of additional data disks attached to the instance beyond the boot disk. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + Unique identifier of the service account associated with this instance. + For details, see https://docs.nebius.com/iam/service-accounts/manage + """ + serviceAccountIdRef: ServiceAccountIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate serviceAccountId. + """ + serviceAccountIdSelector: ServiceAccountIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate serviceAccountId. + """ + stopped: bool | None = None + """ + (Boolean) Indicates whether the instance should be stopped. + Indicates whether the instance should be stopped. + """ + + +class InitProvider(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Specified boot disk attached to the instance. (see below for nested schema) + """ + cloudInitUserDataSecretRef: CloudInitUserDataSecretRef | None = None + """ + (String, Sensitive) : + : + + Data in cloud-init format for customizing instance initialization. + For details, see https://docs.nebius.com/compute/virtual-machines/manage#user-data + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) List of Shared Filesystems attached to the instance. (see below for nested schema) + """ + gpuCluster: GpuCluster | None = None + """ + (Attributes) : + """ + hostname: str | None = None + """ + (String) : + : + + Instance's hostname. Used to generate default DNS record in format `..compute.internal.` + or `..compute.internal.` if hostname is not specified. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkInterfaces: list[NetworkInterface] | None = None + """ + (Attributes List) : + """ + nvlInstanceGroupId: str | None = None + """ + (String) NVLink Instance Group ID associated with the VM + NVLink Instance Group ID associated with the VM + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + preemptible: Preemptible | None = None + """ + (Attributes) : + """ + recoveryPolicy: str | None = None + """ + (String) : + : + + Recovery policy defines how the instance will be treated in case of a failure. + Common source of failure is a host failure, but it can be any other failure. + Instance undergoing a guest shutdown (poweroff, etc.) will be subject to recovery policy, meaning that it could + be restarted and billed accordingly. Stop instance via API or UI to stop it to avoid recovering. + - If set to RECOVER, instance will be restarted, if possible. It could be restarted on the same host or on another host. + - If set to FAIL, instance will be stopped and not restarted. + + #### Supported values + + Possible values: + + - `RECOVER` + - `FAIL` + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) (see below for nested schema) + """ + resources: Resources | None = None + """ + (Attributes) : + """ + secondaryDisks: list[SecondaryDisk] | None = None + """ + (Attributes List) List of additional data disks attached to the instance beyond the boot disk. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + Unique identifier of the service account associated with this instance. + For details, see https://docs.nebius.com/iam/service-accounts/manage + """ + serviceAccountIdRef: ServiceAccountIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate serviceAccountId. + """ + serviceAccountIdSelector: ServiceAccountIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate serviceAccountId. + """ + stopped: bool | None = None + """ + (Boolean) Indicates whether the instance should be stopped. + Indicates whether the instance should be stopped. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class SpecModel(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ExistingDiskModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class SpecModel1(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class ExistingFilesystemModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class GpuClusterModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + If you want to interconnect several instances in a GPU cluster via NVIDIA InfiniBand, + set the ID of an existing GPU cluster. + You can only add the VM to the cluster when creating the VM. + For details, see https://docs.nebius.com/compute/clusters/gpu + """ + + +class SecurityGroupModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Security group identifier + """ + + +class NetworkInterfaceModel(BaseModel): + aliases: list[Alias] | None = None + """ + (Attributes List) Assign ranges of IP addresses as aliases (see below for nested schema) + """ + ipAddress: IpAddress | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Interface name + Value of this field configures the name of the network interface inside VM's OS. + Longer values will persist in the specification but will be truncated to 15 symbols before being passed to VM configuration. + """ + publicIpAddress: PublicIpAddress | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroupModel] | None = None + """ + (Attributes List) : + """ + subnetId: str | None = None + """ + (String) Subnet ID + Subnet ID + """ + + +class DiskAttachment(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Disk ID. + - For ExistingDisk, this is the referenced disk ID. + - For ManagedDisk, may be empty while the attachment intent is still pending. + """ + isManaged: bool | None = None + """ + (Boolean) : + : + + Indicates whether this attachment is managed by the instance lifecycle. + If true, the disk is expected to be deleted when the instance is deleted. + If false, the disk is preserved and only detached on instance deletion. + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Disk name used to match this status entry with the desired attachment + from the instance specification. + + Consistency: + - For ManagedDisk, this value is derived from the instance spec (ManagedDisk.name). + - For ExistingDisk, this value is derived from the disk resource name and may lag behind + in case of renaming. It is updated asynchronously and is eventually consistent. + """ + + +class InfinibandTopologyPath(BaseModel): + path: list[str] | None = None + """ + (List of String) + """ + + +class Aliases(BaseModel): + cidrs: list[str] | None = None + """ + (List of String) + """ + + +class IpAddressModel(BaseModel): + address: str | None = None + """ + (String) Effective private IPv4 address assigned to the interface. + Effective private IPv4 address assigned to the interface. + """ + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier. + """ + + +class PublicIpAddressModel(BaseModel): + address: str | None = None + """ + (String) Effective private IPv4 address assigned to the interface. + Effective public IPv4 address assigned to the interface. + """ + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier. + """ + static: bool | None = None + """ + (Boolean) : + : + + If false - Allocation will be created/deleted during NetworkInterface.Allocate/NetworkInterface.Deallocate + If true - Allocation will be created/deleted during NetworkInterface.Create/NetworkInterface.Delete + False by default + """ + + +class NetworkInterfaceModel1(BaseModel): + aliases: Aliases | None = None + """ + (Attributes List) Assign ranges of IP addresses as aliases (see below for nested schema) + """ + fqdn: str | None = None + """ + (String) FQDN of the interface + FQDN of the interface + """ + index: float | None = None + """ + (Number) The index of the network interface + The index of the network interface + """ + ipAddress: IpAddressModel | None = None + """ + (Attributes) : + """ + macAddress: str | None = None + """ + (String) MAC address + MAC address + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Name for interface. + Unique within instance's network interfaces + """ + publicIpAddress: PublicIpAddressModel | None = None + """ + (Attributes) : + """ + + +class Status(BaseModel): + diskAttachments: list[DiskAttachment] | None = None + """ + . + """ + infinibandTopologyPath: InfinibandTopologyPath | None = None + """ + (Attributes) (see below for nested schema) + """ + maintenanceEventId: str | None = None + """ + (String) + """ + networkInterfaces: list[NetworkInterfaceModel1] | None = None + """ + (Attributes List) : + """ + reconciling: bool | None = None + """ + (Boolean) Indicates whether there is an ongoing operation + Indicates whether there is an ongoing operation + """ + reservationId: str | None = None + """ + (String) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `UPDATING` + - `STARTING` + - `RUNNING` + - `STOPPING` + - `STOPPED` + - `DELETING` + - `ERROR` + """ + + +class AtProvider(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Specified boot disk attached to the instance. (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) List of Shared Filesystems attached to the instance. (see below for nested schema) + """ + gpuCluster: GpuClusterModel | None = None + """ + (Attributes) : + """ + hostname: str | None = None + """ + (String) : + : + + Instance's hostname. Used to generate default DNS record in format `..compute.internal.` + or `..compute.internal.` if hostname is not specified. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkInterfaces: list[NetworkInterfaceModel] | None = None + """ + (Attributes List) : + """ + nvlInstanceGroupId: str | None = None + """ + (String) NVLink Instance Group ID associated with the VM + NVLink Instance Group ID associated with the VM + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + preemptible: Preemptible | None = None + """ + (Attributes) : + """ + recoveryPolicy: str | None = None + """ + (String) : + : + + Recovery policy defines how the instance will be treated in case of a failure. + Common source of failure is a host failure, but it can be any other failure. + Instance undergoing a guest shutdown (poweroff, etc.) will be subject to recovery policy, meaning that it could + be restarted and billed accordingly. Stop instance via API or UI to stop it to avoid recovering. + - If set to RECOVER, instance will be restarted, if possible. It could be restarted on the same host or on another host. + - If set to FAIL, instance will be stopped and not restarted. + + #### Supported values + + Possible values: + + - `RECOVER` + - `FAIL` + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) (see below for nested schema) + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + resources: Resources | None = None + """ + (Attributes) : + """ + secondaryDisks: list[SecondaryDisk] | None = None + """ + (Attributes List) List of additional data disks attached to the instance beyond the boot disk. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + Unique identifier of the service account associated with this instance. + For details, see https://docs.nebius.com/iam/service-accounts/manage + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + stopped: bool | None = None + """ + (Boolean) Indicates whether the instance should be stopped. + Indicates whether the instance should be stopped. + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Instance(BaseModel): + apiVersion: Literal['compute.nebius.m.upbound.io/v1beta1'] | None = ( + 'compute.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Instance'] | None = 'Instance' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: SpecModel + """ + InstanceSpec defines the desired state of Instance + """ + status: StatusModel | None = None + """ + InstanceStatus defines the observed state of Instance. + """ + + +class InstanceList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Instance] + """ + List of instances. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/compute/nvlinstancegroup/__init__.py b/schemas/python/models/io/upbound/m/nebius/compute/nvlinstancegroup/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/compute/nvlinstancegroup/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/compute/nvlinstancegroup/v1beta1.py new file mode 100644 index 000000000..ffa31072a --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/compute/nvlinstancegroup/v1beta1.py @@ -0,0 +1,325 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_m_upbound_io_v1beta1_nvlinstancegroup.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + size: float | None = None + """ + Maximum number of instances in the NVLink InstanceGroup + """ + type: str | None = None + """ + : + + Type of the NVLink InstanceGroup (corresponds to the Compute platform) + + #### Supported values + + Type of the NVLink InstanceGroup. + Possible values: + + - `UNSPECIFIED` + - `GB200` + - `GB300` + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + size: float | None = None + """ + Maximum number of instances in the NVLink InstanceGroup + """ + type: str | None = None + """ + : + + Type of the NVLink InstanceGroup (corresponds to the Compute platform) + + #### Supported values + + Type of the NVLink InstanceGroup. + Possible values: + + - `UNSPECIFIED` + - `GB200` + - `GB300` + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Instances(BaseModel): + instanceState: str | None = None + """ + : + + Current state of the instance. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `UPDATING` + - `STARTING` + - `RUNNING` + - `STOPPING` + - `STOPPED` + - `DELETING` + - `ERROR` + """ + + +class Status(BaseModel): + instances: dict[str, Instances] | None = None + reconciling: bool | None = None + """ + Indicates whether there is an ongoing operation with any VM in the InstanceGroup + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + size: float | None = None + """ + Maximum number of instances in the NVLink InstanceGroup + """ + status: Status | None = None + type: str | None = None + """ + : + + Type of the NVLink InstanceGroup (corresponds to the Compute platform) + + #### Supported values + + Type of the NVLink InstanceGroup. + Possible values: + + - `UNSPECIFIED` + - `GB200` + - `GB300` + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class NvlInstanceGroup(BaseModel): + apiVersion: Literal['compute.nebius.m.upbound.io/v1beta1'] | None = ( + 'compute.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['NvlInstanceGroup'] | None = 'NvlInstanceGroup' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NvlInstanceGroupSpec defines the desired state of NvlInstanceGroup + """ + status: StatusModel | None = None + """ + NvlInstanceGroupStatus defines the observed state of NvlInstanceGroup. + """ + + +class NvlInstanceGroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[NvlInstanceGroup] + """ + List of nvlinstancegroups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/dns/__init__.py b/schemas/python/models/io/upbound/m/nebius/dns/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/dns/record/__init__.py b/schemas/python/models/io/upbound/m/nebius/dns/record/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/dns/record/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/dns/record/v1beta1.py new file mode 100644 index 000000000..fc569304f --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/dns/record/v1beta1.py @@ -0,0 +1,488 @@ +# generated by datamodel-codegen: +# filename: workdir/dns_nebius_m_upbound_io_v1beta1_record.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + data: str | None = None + """ + : + + # Record data in text format + + This should be the RDATA part of this Resource Record's + [presentation (zonefile) format](https://datatracker.ietf.org/doc/html/rfc9499#name-resource-records). + E.g., `10 xyz.tuv` for a `@ 600 IN MX 10 xyz.tuv.` resource record in a zonefile + """ + deletionProtection: bool | None = None + """ + : + + Mark this record as delete-protected + Delete-protected records can *only* be deleted by explicitly calling `RecordService/Delete` API with `force` flag set to `true` + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Zone in dns to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Zone in dns to populate parentId. + """ + relativeName: str | None = None + """ + : + + Zone-relative name of this record (e.g., `www` for `www.`) + Use `@` for records in zone apex (that is, records that have the same domain name as the zone itself) + To see the resolved absolute domain name, see `Record.status.effective_fqdn` + """ + ttl: float | None = None + """ + Record TTL. If absent or negative, will be assumed to be the default value (`600`) + """ + type: str | None = None + """ + : + + # Record type + + #### Supported values + + DNS Record type + Possible values: + + - `RECORD_TYPE_UNSPECIFIED` - Record type is not specified + - `A` - `A` record: IPv4 address + - `AAAA` - `AAAA` record: IPv6 address + - `PTR` - `PTR` record: mapping from IP address to a domain name + - `CNAME` - `CNAME` record: an alias for a *canonical domain name* + - `MX` - `MX` record: mail server information (domain name, priority) + - `TXT` - `TXT` record: text data, typically used to verify e-mail addresses, websites and TLS certificates + - `SRV` - `SRV` record: information about a network service (domain name, port, weight) + - `NS` - `NS` record: domain name of an authoritative nameserver for this DNS zone, or one of its subzones + - `SOA` - `SOA` record: administrative information about this DNS zone + - `CAA` - `CAA` record: certificate issuance settings for this DNS zone and its subzones + - `SVCB` - `SVCB` record: service binding. See [RFC 9460, section 2.3](https://www.rfc-editor.org/rfc/rfc9460.html#section-2.3) + - `HTTPS`: + `HTTPS` record: service binding with HTTPS protocol configuration. + See [RFC 9460, section 9.1](https://www.rfc-editor.org/rfc/rfc9460.html#section-9.1) + """ + + +class InitProvider(BaseModel): + data: str | None = None + """ + : + + # Record data in text format + + This should be the RDATA part of this Resource Record's + [presentation (zonefile) format](https://datatracker.ietf.org/doc/html/rfc9499#name-resource-records). + E.g., `10 xyz.tuv` for a `@ 600 IN MX 10 xyz.tuv.` resource record in a zonefile + """ + deletionProtection: bool | None = None + """ + : + + Mark this record as delete-protected + Delete-protected records can *only* be deleted by explicitly calling `RecordService/Delete` API with `force` flag set to `true` + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Zone in dns to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Zone in dns to populate parentId. + """ + relativeName: str | None = None + """ + : + + Zone-relative name of this record (e.g., `www` for `www.`) + Use `@` for records in zone apex (that is, records that have the same domain name as the zone itself) + To see the resolved absolute domain name, see `Record.status.effective_fqdn` + """ + ttl: float | None = None + """ + Record TTL. If absent or negative, will be assumed to be the default value (`600`) + """ + type: str | None = None + """ + : + + # Record type + + #### Supported values + + DNS Record type + Possible values: + + - `RECORD_TYPE_UNSPECIFIED` - Record type is not specified + - `A` - `A` record: IPv4 address + - `AAAA` - `AAAA` record: IPv6 address + - `PTR` - `PTR` record: mapping from IP address to a domain name + - `CNAME` - `CNAME` record: an alias for a *canonical domain name* + - `MX` - `MX` record: mail server information (domain name, priority) + - `TXT` - `TXT` record: text data, typically used to verify e-mail addresses, websites and TLS certificates + - `SRV` - `SRV` record: information about a network service (domain name, port, weight) + - `NS` - `NS` record: domain name of an authoritative nameserver for this DNS zone, or one of its subzones + - `SOA` - `SOA` record: administrative information about this DNS zone + - `CAA` - `CAA` record: certificate issuance settings for this DNS zone and its subzones + - `SVCB` - `SVCB` record: service binding. See [RFC 9460, section 2.3](https://www.rfc-editor.org/rfc/rfc9460.html#section-2.3) + - `HTTPS`: + `HTTPS` record: service binding with HTTPS protocol configuration. + See [RFC 9460, section 9.1](https://www.rfc-editor.org/rfc/rfc9460.html#section-9.1) + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + effectiveFqdn: str | None = None + """ + Fully-qualified domain name of this record including `.` at the end, e.g. `www.example.com.` + """ + reconciling: bool | None = None + """ + Indicates whether there is a running Operation for this Record + """ + zoneDomainName: str | None = None + """ + Domain name of this record's parent zone including `.` at the end, e.g. `example.com.` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + data: str | None = None + """ + : + + # Record data in text format + + This should be the RDATA part of this Resource Record's + [presentation (zonefile) format](https://datatracker.ietf.org/doc/html/rfc9499#name-resource-records). + E.g., `10 xyz.tuv` for a `@ 600 IN MX 10 xyz.tuv.` resource record in a zonefile + """ + deletionProtection: bool | None = None + """ + : + + Mark this record as delete-protected + Delete-protected records can *only* be deleted by explicitly calling `RecordService/Delete` API with `force` flag set to `true` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + relativeName: str | None = None + """ + : + + Zone-relative name of this record (e.g., `www` for `www.`) + Use `@` for records in zone apex (that is, records that have the same domain name as the zone itself) + To see the resolved absolute domain name, see `Record.status.effective_fqdn` + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + ttl: float | None = None + """ + Record TTL. If absent or negative, will be assumed to be the default value (`600`) + """ + type: str | None = None + """ + : + + # Record type + + #### Supported values + + DNS Record type + Possible values: + + - `RECORD_TYPE_UNSPECIFIED` - Record type is not specified + - `A` - `A` record: IPv4 address + - `AAAA` - `AAAA` record: IPv6 address + - `PTR` - `PTR` record: mapping from IP address to a domain name + - `CNAME` - `CNAME` record: an alias for a *canonical domain name* + - `MX` - `MX` record: mail server information (domain name, priority) + - `TXT` - `TXT` record: text data, typically used to verify e-mail addresses, websites and TLS certificates + - `SRV` - `SRV` record: information about a network service (domain name, port, weight) + - `NS` - `NS` record: domain name of an authoritative nameserver for this DNS zone, or one of its subzones + - `SOA` - `SOA` record: administrative information about this DNS zone + - `CAA` - `CAA` record: certificate issuance settings for this DNS zone and its subzones + - `SVCB` - `SVCB` record: service binding. See [RFC 9460, section 2.3](https://www.rfc-editor.org/rfc/rfc9460.html#section-2.3) + - `HTTPS`: + `HTTPS` record: service binding with HTTPS protocol configuration. + See [RFC 9460, section 9.1](https://www.rfc-editor.org/rfc/rfc9460.html#section-9.1) + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Record(BaseModel): + apiVersion: Literal['dns.nebius.m.upbound.io/v1beta1'] | None = ( + 'dns.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Record'] | None = 'Record' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RecordSpec defines the desired state of Record + """ + status: StatusModel | None = None + """ + RecordStatus defines the observed state of Record. + """ + + +class RecordList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Record] + """ + List of records. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/dns/zone/__init__.py b/schemas/python/models/io/upbound/m/nebius/dns/zone/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/dns/zone/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/dns/zone/v1beta1.py new file mode 100644 index 000000000..8d34da6ed --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/dns/zone/v1beta1.py @@ -0,0 +1,366 @@ +# generated by datamodel-codegen: +# filename: workdir/dns_nebius_m_upbound_io_v1beta1_zone.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class SoaSpec(BaseModel): + negativeTtl: float | None = None + """ + : + + Specifies TTL, in seconds, for caching `NXDOMAIN` ("record not found") DNS responses from this zone (*negative caching*) + Set this TTL to a low value if you frequently delete and recreate records instead of updating them + *Note:* Values of less than `5` will be ignored, and a default negative caching TTL will be used instead + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class PrimaryNetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class PrimaryNetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Vpc(BaseModel): + primaryNetworkId: str | None = None + """ + : + + ID of the virtual network that this zone's records will be visible from + This value cannot be changed after creating the zone + """ + primaryNetworkIdRef: PrimaryNetworkIdRef | None = None + """ + Reference to a Network in vpc to populate primaryNetworkId. + """ + primaryNetworkIdSelector: PrimaryNetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate primaryNetworkId. + """ + + +class ForProvider(BaseModel): + domainName: str | None = None + """ + : + + Fully qualified domain name of this zone, including `.` at the end + Cannot be changed after creating the zone + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + soaSpec: SoaSpec | None = None + vpc: Vpc | None = None + + +class InitProvider(BaseModel): + domainName: str | None = None + """ + : + + Fully qualified domain name of this zone, including `.` at the end + Cannot be changed after creating the zone + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + soaSpec: SoaSpec | None = None + vpc: Vpc | None = None + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + reconciling: bool | None = None + """ + Indicates whether there is a running Operation for this Zone + """ + recordCount: float | None = None + """ + Number of records in this zone. May be 0 if not calculated (e.g., in listings) + """ + + +class VpcModel(BaseModel): + primaryNetworkId: str | None = None + """ + : + + ID of the virtual network that this zone's records will be visible from + This value cannot be changed after creating the zone + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + domainName: str | None = None + """ + : + + Fully qualified domain name of this zone, including `.` at the end + Cannot be changed after creating the zone + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + soaSpec: SoaSpec | None = None + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + vpc: VpcModel | None = None + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Zone(BaseModel): + apiVersion: Literal['dns.nebius.m.upbound.io/v1beta1'] | None = ( + 'dns.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Zone'] | None = 'Zone' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ZoneSpec defines the desired state of Zone + """ + status: StatusModel | None = None + """ + ZoneStatus defines the observed state of Zone. + """ + + +class ZoneList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Zone] + """ + List of zones. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/accesskey/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/accesskey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/accesskey/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/accesskey/v1beta1.py new file mode 100644 index 000000000..d7ac051a1 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/accesskey/v1beta1.py @@ -0,0 +1,480 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_accesskey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ServiceAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a ServiceAccount in iam to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate id. + """ + + +class UserAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Account(BaseModel): + anonymousAccount: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside user_account or service_account. (see below for nested schema) + """ + serviceAccount: ServiceAccount | None = None + """ + (Attributes) Cannot be set alongside user_account or anonymous_account. (see below for nested schema) + """ + userAccount: UserAccount | None = None + """ + (Attributes) Cannot be set alongside service_account or anonymous_account. (see below for nested schema) + """ + + +class ForProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + secretDeliveryMode: str | None = None + """ + (String) : + : + + Specifies how the secret will be delivered upon creation. This field is immutable — it cannot be changed after the resource is + created. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - If not specified, the default behaviour will be applied. Currently it's INLINE, later will be EXPLICIT + """ + + +class InitProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + secretDeliveryMode: str | None = None + """ + (String) : + : + + Specifies how the secret will be delivered upon creation. This field is immutable — it cannot be changed after the resource is + created. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - If not specified, the default behaviour will be applied. Currently it's INLINE, later will be EXPLICIT + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ServiceAccountModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Status(BaseModel): + algorithm: str | None = None + """ + (String) + """ + awsAccessKeyId: str | None = None + """ + (String) + """ + fingerprint: str | None = None + """ + (String) + """ + keySize: float | None = None + """ + (Number) + """ + secretReferenceId: str | None = None + """ + (String) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `INACTIVE` + - `EXPIRED` + - `DELETING` + - `DELETED` + """ + + +class AtProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + secretDeliveryMode: str | None = None + """ + (String) : + : + + Specifies how the secret will be delivered upon creation. This field is immutable — it cannot be changed after the resource is + created. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - If not specified, the default behaviour will be applied. Currently it's INLINE, later will be EXPLICIT + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AccessKey(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AccessKey'] | None = 'AccessKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AccessKeySpec defines the desired state of AccessKey + """ + status: StatusModel | None = None + """ + AccessKeyStatus defines the observed state of AccessKey. + """ + + +class AccessKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AccessKey] + """ + List of accesskeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/accesspermit/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/accesspermit/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/accesspermit/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/accesspermit/v1beta1.py new file mode 100644 index 000000000..987059622 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/accesspermit/v1beta1.py @@ -0,0 +1,329 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_accesspermit.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + resourceId: str | None = None + """ + Resource for granting access permit. + """ + role: str | None = None + """ + Role for granting access permit. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + resourceId: str | None = None + """ + Resource for granting access permit. + """ + role: str | None = None + """ + Role for granting access permit. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceId: str | None = None + """ + Resource for granting access permit. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + role: str | None = None + """ + Role for granting access permit. + """ + status: dict[str, Any] | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AccessPermit(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AccessPermit'] | None = 'AccessPermit' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AccessPermitSpec defines the desired state of AccessPermit + """ + status: Status | None = None + """ + AccessPermitStatus defines the observed state of AccessPermit. + """ + + +class AccessPermitList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AccessPermit] + """ + List of accesspermits. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/authpublickey/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/authpublickey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/authpublickey/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/authpublickey/v1beta1.py new file mode 100644 index 000000000..3991974c2 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/authpublickey/v1beta1.py @@ -0,0 +1,446 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_authpublickey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ServiceAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a ServiceAccount in iam to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate id. + """ + + +class UserAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Account(BaseModel): + anonymousAccount: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside user_account or service_account. (see below for nested schema) + """ + serviceAccount: ServiceAccount | None = None + """ + (Attributes) Cannot be set alongside user_account or anonymous_account. (see below for nested schema) + """ + userAccount: UserAccount | None = None + """ + (Attributes) Cannot be set alongside service_account or anonymous_account. (see below for nested schema) + """ + + +class DataSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class ForProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + dataSecretRef: DataSecretRef | None = None + """ + (String) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + dataSecretRef: DataSecretRef | None = None + """ + (String) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ServiceAccountModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Status(BaseModel): + algorithm: str | None = None + """ + (String) + """ + fingerprint: str | None = None + """ + (String) + """ + keySize: float | None = None + """ + (Number) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `INACTIVE` + - `EXPIRED` + - `DELETING` + - `DELETED` + """ + + +class AtProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AuthPublicKey(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AuthPublicKey'] | None = 'AuthPublicKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AuthPublicKeySpec defines the desired state of AuthPublicKey + """ + status: StatusModel | None = None + """ + AuthPublicKeyStatus defines the observed state of AuthPublicKey. + """ + + +class AuthPublicKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AuthPublicKey] + """ + List of authpublickeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/federatedcredentials/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/federatedcredentials/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/federatedcredentials/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/federatedcredentials/v1beta1.py new file mode 100644 index 000000000..85948a58a --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/federatedcredentials/v1beta1.py @@ -0,0 +1,356 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_federatedcredentials.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class OidcProvider(BaseModel): + issuerUrl: str | None = None + """ + OIDC-compatible JWT issuer URL. + """ + jwkSetJson: str | None = None + """ + : + + JSON representation of a JSON Web Key Set (JWKS) with public keys used for + JWT signature verification. + If set, the token service uses this JWKS to verify token signatures. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class SubjectIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubjectIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + federatedSubjectId: str | None = None + """ + : + + Federated subject ID. For oidc_provider, the subject is calculated from the + "sub" claim of the federated JWT token. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + oidcProvider: OidcProvider | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + subjectId: str | None = None + """ + IAM subject (service account) that the federated subject impersonates. + """ + subjectIdRef: SubjectIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate subjectId. + """ + subjectIdSelector: SubjectIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate subjectId. + """ + + +class InitProvider(BaseModel): + federatedSubjectId: str | None = None + """ + : + + Federated subject ID. For oidc_provider, the subject is calculated from the + "sub" claim of the federated JWT token. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + oidcProvider: OidcProvider | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + subjectId: str | None = None + """ + IAM subject (service account) that the federated subject impersonates. + """ + subjectIdRef: SubjectIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate subjectId. + """ + subjectIdSelector: SubjectIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate subjectId. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + federatedSubjectId: str | None = None + """ + : + + Federated subject ID. For oidc_provider, the subject is calculated from the + "sub" claim of the federated JWT token. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + oidcProvider: OidcProvider | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: dict[str, Any] | None = None + subjectId: str | None = None + """ + IAM subject (service account) that the federated subject impersonates. + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class FederatedCredentials(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['FederatedCredentials'] | None = 'FederatedCredentials' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FederatedCredentialsSpec defines the desired state of FederatedCredentials + """ + status: Status | None = None + """ + FederatedCredentialsStatus defines the observed state of FederatedCredentials. + """ + + +class FederatedCredentialsList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[FederatedCredentials] + """ + List of federatedcredentials. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/federation/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/federation/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/federation/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/federation/v1beta1.py new file mode 100644 index 000000000..3a9c073da --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/federation/v1beta1.py @@ -0,0 +1,313 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_federation.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class SamlSettings(BaseModel): + forceAuthn: bool | None = None + """ + if "true", the identity provider MUST authenticate the presenter directly rather than rely on a previous security context. + """ + idpIssuer: str | None = None + """ + The unique identifier of the SAML Identity Provider. It usually matches the entityID from the IdP metadata. + """ + ssoUrl: str | None = None + """ + Identity Provider’s Single Sign-On endpoint. This is the URL where the user is redirected to start SAML login. + """ + + +class ForProvider(BaseModel): + active: bool | None = None + """ + Specifies if the federation in active state + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + samlSettings: SamlSettings | None = None + userAccountAutoCreation: bool | None = None + """ + : + + If false, users with access to the federation cannot sign in automatically + and user accounts for them must be pre-created by a federation administrator. + """ + + +class InitProvider(BaseModel): + active: bool | None = None + """ + Specifies if the federation in active state + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + samlSettings: SamlSettings | None = None + userAccountAutoCreation: bool | None = None + """ + : + + If false, users with access to the federation cannot sign in automatically + and user accounts for them must be pre-created by a federation administrator. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + certificatesCount: float | None = None + """ + Number of certificates attached to the SAML federation for verifying SAML responses. + """ + state: str | None = None + """ + : + + Federation state. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `ACTIVE` + - `INACTIVE` + """ + usersCount: float | None = None + """ + Number of users registered in the IAM federation. This value may differ from the number of users in the identity provider. + """ + + +class AtProvider(BaseModel): + active: bool | None = None + """ + Specifies if the federation in active state + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + samlSettings: SamlSettings | None = None + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + userAccountAutoCreation: bool | None = None + """ + : + + If false, users with access to the federation cannot sign in automatically + and user accounts for them must be pre-created by a federation administrator. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Federation(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Federation'] | None = 'Federation' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FederationSpec defines the desired state of Federation + """ + status: StatusModel | None = None + """ + FederationStatus defines the observed state of Federation. + """ + + +class FederationList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Federation] + """ + List of federations. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/federationcertificate/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/federationcertificate/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/federationcertificate/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/federationcertificate/v1beta1.py new file mode 100644 index 000000000..fce76ec8e --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/federationcertificate/v1beta1.py @@ -0,0 +1,352 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_federationcertificate.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class DataSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + dataSecretRef: DataSecretRef | None = None + """ + A LocalSecretKeySelector is a reference to a secret key + in the same namespace with the referencing object. + """ + description: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Federation in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Federation in iam to populate parentId. + """ + + +class InitProvider(BaseModel): + dataSecretRef: DataSecretRef | None = None + """ + A LocalSecretKeySelector is a reference to a secret key + in the same namespace with the referencing object. + """ + description: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Federation in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Federation in iam to populate parentId. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + algorithm: str | None = None + fingerprint: str | None = None + keySize: float | None = None + notAfter: str | None = None + """ + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + notBefore: str | None = None + """ + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `EXPIRED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class FederationCertificate(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['FederationCertificate'] | None = 'FederationCertificate' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FederationCertificateSpec defines the desired state of FederationCertificate + """ + status: StatusModel | None = None + """ + FederationCertificateStatus defines the observed state of FederationCertificate. + """ + + +class FederationCertificateList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[FederationCertificate] + """ + List of federationcertificates. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/group/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/group/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/group/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/group/v1beta1.py new file mode 100644 index 000000000..1023e1f0a --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/group/v1beta1.py @@ -0,0 +1,254 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_group.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + membersCount: float | None = None + serviceAccountsCount: float | None = None + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `ACTIVE` + """ + tenantUserAccountsCount: float | None = None + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Group(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Group'] | None = 'Group' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + GroupSpec defines the desired state of Group + """ + status: StatusModel | None = None + """ + GroupStatus defines the observed state of Group. + """ + + +class GroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Group] + """ + List of groups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/groupmembership/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/groupmembership/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/groupmembership/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/groupmembership/v1beta1.py new file mode 100644 index 000000000..a208adb2c --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/groupmembership/v1beta1.py @@ -0,0 +1,477 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_groupmembership.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class MemberIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class MemberIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + memberId: str | None = None + """ + Member of the group. Can be tenant user account id or service account id. + """ + memberIdRef: MemberIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate memberId. + """ + memberIdSelector: MemberIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate memberId. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + memberId: str | None = None + """ + Member of the group. Can be tenant user account id or service account id. + """ + memberIdRef: MemberIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate memberId. + """ + memberIdSelector: MemberIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate memberId. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class GroupMemberMetadata(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class ServiceAccountStatus(BaseModel): + active: bool | None = None + + +class TenantUserAccountStatus(BaseModel): + federationId: str | None = None + """ + : + + the federation id of the linked user account. Could be empty in a case of a tenant user account belongs to an invitation which wasn't + accepted. + """ + invitationId: str | None = None + """ + : + + if a tenant user account is created during invitation it gets a reference to the invitation resource + once invitation is accepted it looses this reference (and internally gets a reference to their global federated user account) + """ + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE`: + - in case of ordinary tenant user account a corresponding user can log into the system and use granted tenant resources + - in case of invited tenant user account once the invitation is accepted a corresponding user can start using granted resources + immediately + + - `INACTIVE` - unused + - `BLOCKED`: + - in case of ordinary tenant user account a corresponding user can log into the system but cannot be authorized to use tenant + resources + - in case of invited tenant user account once the invitation is accepted a corresponding user cannot start using granted resources + until is unblocked + """ + userAccountState: str | None = None + """ + : + + user account state can help distinguish case when account is blocked globally + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` - usual state when federated user can log into the system and view/manage granted resources in one or more tenants + - `INACTIVE` - federated user can be blocked (manually or by any specific automated process), in this state user cannot log into the system + - `DELETING`: + federated user can be deleted/forgot, in this state user cannot log into the system and various internal removal interactions are in + progress + """ + + +class Status(BaseModel): + groupMemberMetadata: GroupMemberMetadata | None = None + serviceAccountStatus: ServiceAccountStatus | None = None + tenantUserAccountStatus: TenantUserAccountStatus | None = None + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + memberId: str | None = None + """ + Member of the group. Can be tenant user account id or service account id. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class GroupMembership(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['GroupMembership'] | None = 'GroupMembership' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + GroupMembershipSpec defines the desired state of GroupMembership + """ + status: StatusModel | None = None + """ + GroupMembershipStatus defines the observed state of GroupMembership. + """ + + +class GroupMembershipList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[GroupMembership] + """ + List of groupmemberships. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/invitation/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/invitation/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/invitation/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/invitation/v1beta1.py new file mode 100644 index 000000000..edb1d96cc --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/invitation/v1beta1.py @@ -0,0 +1,281 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_invitation.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class EmailSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class ForProvider(BaseModel): + description: str | None = None + emailSecretRef: EmailSecretRef | None = None + """ + A LocalSecretKeySelector is a reference to a secret key + in the same namespace with the referencing object. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + emailSecretRef: EmailSecretRef | None = None + """ + A LocalSecretKeySelector is a reference to a secret key + in the same namespace with the referencing object. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + expiresAt: str | None = None + """ + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` - contacts data is not stored in pds yet. probably will GC it later + - `CREATED` - notification is not sent yet + - `PENDING` - notification is sent, we are waiting for the user to approve the notification + - `EXPIRED` - notification is expired, accept is no longer possible + - `ACCEPTED` - notification is accepted + """ + tenantUserAccountId: str | None = None + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Invitation(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Invitation'] | None = 'Invitation' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + InvitationSpec defines the desired state of Invitation + """ + status: StatusModel | None = None + """ + InvitationStatus defines the observed state of Invitation. + """ + + +class InvitationList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Invitation] + """ + List of invitations. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/project/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/project/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/project/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/project/v1beta1.py new file mode 100644 index 000000000..f387e829f --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/project/v1beta1.py @@ -0,0 +1,280 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_project.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + : + + Name of the region where project resources will be created. + Example: "eu-north1". + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + : + + Name of the region where project resources will be created. + Example: "eu-north1". + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + projectState: str | None = None + """ + : + + Current state of the project. + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `CREATING` + - `ACTIVE` + - `PURGING` + - `CREATED` + - `ACTIVATING` + - `PARKING` + - `PARKED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + : + + Name of the region where project resources will be created. + Example: "eu-north1". + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Project(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Project'] | None = 'Project' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ProjectSpec defines the desired state of Project + """ + status: StatusModel | None = None + """ + ProjectStatus defines the observed state of Project. + """ + + +class ProjectList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Project] + """ + List of projects. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/iam/serviceaccount/__init__.py b/schemas/python/models/io/upbound/m/nebius/iam/serviceaccount/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/iam/serviceaccount/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/iam/serviceaccount/v1beta1.py new file mode 100644 index 000000000..4d3f58c1f --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/iam/serviceaccount/v1beta1.py @@ -0,0 +1,283 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_m_upbound_io_v1beta1_serviceaccount.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + active: bool | None = None + """ + (Boolean) + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class ServiceAccount(BaseModel): + apiVersion: Literal['iam.nebius.m.upbound.io/v1beta1'] | None = ( + 'iam.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ServiceAccount'] | None = 'ServiceAccount' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ServiceAccountSpec defines the desired state of ServiceAccount + """ + status: StatusModel | None = None + """ + ServiceAccountStatus defines the observed state of ServiceAccount. + """ + + +class ServiceAccountList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ServiceAccount] + """ + List of serviceaccounts. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/kms/__init__.py b/schemas/python/models/io/upbound/m/nebius/kms/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/kms/asymmetrickey/__init__.py b/schemas/python/models/io/upbound/m/nebius/kms/asymmetrickey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/kms/asymmetrickey/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/kms/asymmetrickey/v1beta1.py new file mode 100644 index 000000000..19a8f2fe6 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/kms/asymmetrickey/v1beta1.py @@ -0,0 +1,334 @@ +# generated by datamodel-codegen: +# filename: workdir/kms_nebius_m_upbound_io_v1beta1_asymmetrickey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + algorithm: str | None = None + """ + : + + Cryptographic algorithm that should be used with the key. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported asymmetric algorithms. + Possible values: + + - `ASYMMETRIC_ALGORITHM_UNSPECIFIED` + - `ECDSA_NIST_P256_SHA_256` - ECDSA signature with NIST P-256 curve and SHA-256 + - `ECDSA_NIST_P384_SHA_384` - ECDSA signature with NIST P-384 curve and SHA-384 + - `RSA_4096_ENC_OAEP_SHA_256` - RSA encryption with RSA-4096 key, OAEP padding and SHA-256. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + algorithm: str | None = None + """ + : + + Cryptographic algorithm that should be used with the key. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported asymmetric algorithms. + Possible values: + + - `ASYMMETRIC_ALGORITHM_UNSPECIFIED` + - `ECDSA_NIST_P256_SHA_256` - ECDSA signature with NIST P-256 curve and SHA-256 + - `ECDSA_NIST_P384_SHA_384` - ECDSA signature with NIST P-384 curve and SHA-384 + - `RSA_4096_ENC_OAEP_SHA_256` - RSA encryption with RSA-4096 key, OAEP padding and SHA-256. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + : + + Time when the key was scheduled for deletion. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + purgeAt: str | None = None + """ + : + + Time when the key will be permanently deleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + State (ACTIVE, SCHEDULED_FOR_DELETION) + + #### Supported values + + Key state + Possible values: + + - `KEY_STATE_UNSPECIFIED` + - `ACTIVE` - Key is active, ready for use + - `SCHEDULED_FOR_DELETION` - Key is scheduled for deletion. + """ + + +class AtProvider(BaseModel): + algorithm: str | None = None + """ + : + + Cryptographic algorithm that should be used with the key. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported asymmetric algorithms. + Possible values: + + - `ASYMMETRIC_ALGORITHM_UNSPECIFIED` + - `ECDSA_NIST_P256_SHA_256` - ECDSA signature with NIST P-256 curve and SHA-256 + - `ECDSA_NIST_P384_SHA_384` - ECDSA signature with NIST P-384 curve and SHA-384 + - `RSA_4096_ENC_OAEP_SHA_256` - RSA encryption with RSA-4096 key, OAEP padding and SHA-256. + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Description of the key. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AsymmetricKey(BaseModel): + apiVersion: Literal['kms.nebius.m.upbound.io/v1beta1'] | None = ( + 'kms.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AsymmetricKey'] | None = 'AsymmetricKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AsymmetricKeySpec defines the desired state of AsymmetricKey + """ + status: StatusModel | None = None + """ + AsymmetricKeyStatus defines the observed state of AsymmetricKey. + """ + + +class AsymmetricKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AsymmetricKey] + """ + List of asymmetrickeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/kms/symmetrickey/__init__.py b/schemas/python/models/io/upbound/m/nebius/kms/symmetrickey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/kms/symmetrickey/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/kms/symmetrickey/v1beta1.py new file mode 100644 index 000000000..c2106efbc --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/kms/symmetrickey/v1beta1.py @@ -0,0 +1,364 @@ +# generated by datamodel-codegen: +# filename: workdir/kms_nebius_m_upbound_io_v1beta1_symmetrickey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + algorithm: str | None = None + """ + : + + Encryption algorithm that should be used when using the key to encrypt plaintext. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported symmetric encryption algorithms. + Possible values: + + - `SYMMETRIC_ALGORITHM_UNSPECIFIED` + - `AES_128`: + Deprecated. It is impossible to create new keys with this algorithm. + AES algorithm with 128-bit keys. + + - `AES_256` - AES algorithm with 256-bit keys. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + rotationPeriod: str | None = None + """ + : + + Key rotation period. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + + +class InitProvider(BaseModel): + algorithm: str | None = None + """ + : + + Encryption algorithm that should be used when using the key to encrypt plaintext. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported symmetric encryption algorithms. + Possible values: + + - `SYMMETRIC_ALGORITHM_UNSPECIFIED` + - `AES_128`: + Deprecated. It is impossible to create new keys with this algorithm. + AES algorithm with 128-bit keys. + + - `AES_256` - AES algorithm with 256-bit keys. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + rotationPeriod: str | None = None + """ + : + + Key rotation period. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + : + + Time when the key was scheduled for deletion. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + purgeAt: str | None = None + """ + : + + Time when the key will be permanently deleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + State (ACTIVE, SCHEDULED_FOR_DELETION). + + #### Supported values + + Key state + Possible values: + + - `KEY_STATE_UNSPECIFIED` + - `ACTIVE` - Key is active, ready for use + - `SCHEDULED_FOR_DELETION` - Key is scheduled for deletion. + """ + + +class AtProvider(BaseModel): + algorithm: str | None = None + """ + : + + Encryption algorithm that should be used when using the key to encrypt plaintext. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported symmetric encryption algorithms. + Possible values: + + - `SYMMETRIC_ALGORITHM_UNSPECIFIED` + - `AES_128`: + Deprecated. It is impossible to create new keys with this algorithm. + AES algorithm with 128-bit keys. + + - `AES_256` - AES algorithm with 256-bit keys. + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Description of the key. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + rotationPeriod: str | None = None + """ + : + + Key rotation period. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SymmetricKey(BaseModel): + apiVersion: Literal['kms.nebius.m.upbound.io/v1beta1'] | None = ( + 'kms.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SymmetricKey'] | None = 'SymmetricKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SymmetricKeySpec defines the desired state of SymmetricKey + """ + status: StatusModel | None = None + """ + SymmetricKeyStatus defines the observed state of SymmetricKey. + """ + + +class SymmetricKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SymmetricKey] + """ + List of symmetrickeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/mk8s/__init__.py b/schemas/python/models/io/upbound/m/nebius/mk8s/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/mk8s/cluster/__init__.py b/schemas/python/models/io/upbound/m/nebius/mk8s/cluster/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/mk8s/cluster/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/mk8s/cluster/v1beta1.py new file mode 100644 index 000000000..a5150bdb2 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/mk8s/cluster/v1beta1.py @@ -0,0 +1,587 @@ +# generated by datamodel-codegen: +# filename: workdir/mk8s_nebius_m_upbound_io_v1beta1_cluster.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class PublicEndpoint(BaseModel): + allowedCidrs: list[str] | None = None + """ + (List of String) : + : + + List of CIDR blocks from which access to public endpoint is allowed. + If field is not set, or list is empty, it means that access is not restricted at all. + """ + + +class Endpoints(BaseModel): + publicEndpoint: PublicEndpoint | None = None + """ + (Attributes) Public endpoint specification. When set, a public endpoint is created. (see below for nested schema) + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ControlPlane(BaseModel): + auditLogs: dict[str, Any] | None = None + """ + (Attributes) : + """ + endpoints: Endpoints | None = None + """ + (Attributes) Specification of endpoints of cluster control plane. (see below for nested schema) + """ + etcdClusterSize: float | None = None + """ + (Number) : + : + + Number of instances in etcd cluster. + 3 by default. + Control plane with `etcd_cluster_size: 3` called "Highly Available" ("HA"), because it's Kubernetes API + will be available despite a failure of one control plane instance. + """ + karpenter: dict[str, Any] | None = None + """ + (Attributes) : + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID where control plane instances will be located. + Also will be default NodeGroup subnet. + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + version: str | None = None + """ + (String) : + : + + Desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + """ + + +class KubeNetwork(BaseModel): + serviceCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks for Service ClusterIP allocation. + For now, only one value is supported. + Must be a valid CIDR block or prefix length. + In case of prefix length, certain CIDR is auto allocated. + Specified CIDR blocks will be reserved in Cluster.spec.control_plane.subnet_id to prevent address duplication. + Allowed prefix length is from "/12" to "/28". + Empty value treated as ["/16"]. + """ + + +class ForProvider(BaseModel): + controlPlane: ControlPlane | None = None + """ + (Attributes) (see below for nested schema) + """ + kubeNetwork: KubeNetwork | None = None + """ + (Attributes) Defines kubernetes network configuration, like IP allocation. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + controlPlane: ControlPlane | None = None + """ + (Attributes) (see below for nested schema) + """ + kubeNetwork: KubeNetwork | None = None + """ + (Attributes) Defines kubernetes network configuration, like IP allocation. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ControlPlaneModel(BaseModel): + auditLogs: dict[str, Any] | None = None + """ + (Attributes) : + """ + endpoints: Endpoints | None = None + """ + (Attributes) Specification of endpoints of cluster control plane. (see below for nested schema) + """ + etcdClusterSize: float | None = None + """ + (Number) : + : + + Number of instances in etcd cluster. + 3 by default. + Control plane with `etcd_cluster_size: 3` called "Highly Available" ("HA"), because it's Kubernetes API + will be available despite a failure of one control plane instance. + """ + karpenter: dict[str, Any] | None = None + """ + (Attributes) : + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID where control plane instances will be located. + Also will be default NodeGroup subnet. + """ + version: str | None = None + """ + (String) : + : + + Desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + """ + + +class ControlPlaneModel1(BaseModel): + auth: dict[str, Any] | None = None + """ + (Attributes) (see below for nested schema) + """ + endpoints: dict[str, Any] | None = None + """ + (Attributes) Specification of endpoints of cluster control plane. (see below for nested schema) + """ + etcdClusterSize: float | None = None + """ + (Number) : + Number of instances in etcd cluster. + """ + version: str | None = None + """ + (String) : + : + + Actual Kubernetes and configuration version. + Version has format `..-nebius-cp.` like + "1.30.0-nebius-cp.3", where `..` is Kubernetes version and `` is version of control plane + infrastructure and configuration, updating of which may include bug fixes, security updates and new features of components running on + control plane, like CCM or Cluster Autoscaler. + """ + + +class LastOccurrence(BaseModel): + code: str | None = None + """ + (String) Event code (unique within the API service), in UpperCamelCase, e.g. "DiskAttached" + Event code (unique within the API service), in UpperCamelCase, e.g. `"DiskAttached"` + """ + level: str | None = None + """ + (String) : + : + + # Severity level for the event + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - Unspecified event severity level + - `DEBUG` - A debug event providing detailed insight. Such events are used to debug problems with specific resource(s) and process(es) + - `INFO` - A normal event or state change. Informs what is happening with the API resource. Does not require user attention or interaction + - `WARN`: + Warning event. Indicates a potential or minor problem with the API resource and/or the corresponding processes. Needs user attention, + but requires no immediate action (yet) + + - `ERROR` - Error event. Indicates a serious problem with the API resource and/or the corresponding processes. Requires immediate user action + """ + message: str | None = None + """ + (String) : + : + + A human-readable message describing what has happened + (and suggested actions for the user, if this is a `WARN` or `ERROR` level event) + """ + occurredAt: str | None = None + """ + (String) : + : + + # Time at which the event has occurred + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Event(BaseModel): + firstOccurredAt: str | None = None + """ + (String) : + : + + # Time of the first occurrence of a recurrent event + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + lastOccurrence: LastOccurrence | None = None + """ + (Attributes) : + """ + occurrenceCount: float | None = None + """ + (Number) The number of times this event has occurred between first_occurred_at and last_occurrence.occurred_at. Must be > 0 + The number of times this event has occurred between `first_occurred_at` and `last_occurrence.occurred_at`. Must be > 0 + """ + + +class Status(BaseModel): + controlPlane: ControlPlaneModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + events: list[Event] | None = None + """ + (Attributes List) : + """ + reconciling: bool | None = None + """ + (Boolean) Show that changes are in flight + Show that changes are in flight + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `PROVISIONING` + - `RUNNING` + - `DELETING` + """ + + +class AtProvider(BaseModel): + controlPlane: ControlPlaneModel | None = None + """ + (Attributes) (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + kubeNetwork: KubeNetwork | None = None + """ + (Attributes) Defines kubernetes network configuration, like IP allocation. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Cluster(BaseModel): + apiVersion: Literal['mk8s.nebius.m.upbound.io/v1beta1'] | None = ( + 'mk8s.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Cluster'] | None = 'Cluster' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ClusterSpec defines the desired state of Cluster + """ + status: StatusModel | None = None + """ + ClusterStatus defines the observed state of Cluster. + """ + + +class ClusterList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Cluster] + """ + List of clusters. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/mk8s/nodegroup/__init__.py b/schemas/python/models/io/upbound/m/nebius/mk8s/nodegroup/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/mk8s/nodegroup/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/mk8s/nodegroup/v1beta1.py new file mode 100644 index 000000000..917325536 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/mk8s/nodegroup/v1beta1.py @@ -0,0 +1,1402 @@ +# generated by datamodel-codegen: +# filename: workdir/mk8s_nebius_m_upbound_io_v1beta1_nodegroup.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Condition(BaseModel): + disabled: bool | None = None + """ + (Boolean) : + : + + When true, disables the default auto-repair condition rules. + + *Cannot be set alongside timeout.* + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + Node condition status. + + #### Supported values + + Possible values: + + - `CONDITION_STATUS_UNSPECIFIED` + - `TRUE` + - `FALSE` + - `UNKNOWN` + """ + timeout: str | None = None + """ + (String) : + : + + The duration after which the node is automatically repaired if the condition remains in the specified status. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + + *Cannot be set alongside disabled.* + """ + type: str | None = None + """ + (String) : + Node condition type. + """ + + +class AutoRepair(BaseModel): + conditions: list[Condition] | None = None + """ + (Attributes List) Conditions that determine whether a node should be auto repaired. (see below for nested schema) + """ + + +class Autoscaling(BaseModel): + maxNodeCount: float | None = None + """ + (Number) + """ + minNodeCount: float | None = None + """ + (Number) + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class MaxSurge(BaseModel): + count: float | None = None + """ + (Number) Cannot be set alongside percent. + *Cannot be set alongside percent.* + """ + percent: float | None = None + """ + (Number) Cannot be set alongside count. + *Cannot be set alongside count.* + """ + + +class MaxUnavailable(BaseModel): + count: float | None = None + """ + (Number) Cannot be set alongside percent. + *Cannot be set alongside percent.* + """ + percent: float | None = None + """ + (Number) Cannot be set alongside count. + *Cannot be set alongside count.* + """ + + +class Strategy(BaseModel): + drainTimeout: str | None = None + """ + (String) : + : + + Maximum amount of time that the service will spend attempting to gracefully drain a node + (evicting its pods) before falling back to pod deletion. + A value of 0 (or when field is omitted) means no timeout: the node can be drained for an unlimited time. + Important consequence of that is if PodDisruptionBudget doesn't allow evicting a pod, + then NodeGroup update with node re-creation will hang on that pod eviction. + Note that this is different from `kubectl drain --timeout`, which gives up and returns an error. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + maxSurge: MaxSurge | None = None + """ + (Attributes) : + """ + maxUnavailable: MaxUnavailable | None = None + """ + is also set to 0. + """ + + +class BootDisk(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_IO_M3` + - `NETWORK_SSD_NON_REPLICATED` + """ + + +class CloudInitUserDataSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ExistingFilesystem(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a Filesystem in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Filesystem in compute to populate id. + """ + + +class Filesystem(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + existingFilesystem: ExistingFilesystem | None = None + """ + (Attributes) (see below for nested schema) + """ + mountTag: str | None = None + """ + defined identifier, allowing to use it as a device in mount command. + Specifies the user-defined identifier, allowing to use it as a device in mount command. + """ + + +class GpuCluster(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a GpuCluster in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a GpuCluster in compute to populate id. + """ + + +class GpuSettings(BaseModel): + driversPreset: str | None = None + """ + : "" + : + + Identifier of the predefined set of drivers included in the ComputeImage deployed on ComputeInstances that are part of the NodeGroup. + Supported presets for different platform / Kubernetes version combinations: + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`: + * `version`: 1.30 → `"cuda12"` (CUDA 12.4) + * `version`: 1.31 → `"cuda12"` (CUDA 12.4), `"cuda12.4"`, `"cuda12.8"` + * `gpu-b200-sxm`: + * `version`: 1.31 → `"cuda12"` (CUDA 12.8), `"cuda12.8"` + * `gpu-b200-sxm-a`: + * `version`: 1.31 → `"cuda12.8"` + """ + + +class Config(BaseModel): + kubeletEphemeral: bool | None = None + """ + (Boolean) : + : + + kubelet_ephemeral: combine all local disks into a single storage volume and use it as kubelet's local ephemeral storage on the node + See also https://kubernetes.io/docs/concepts/storage/ephemeral-storage/ + + The default when LocalDisksSpecConfig is not set. + + *Cannot be set alongside none.* + """ + none: bool | None = None + """ + (Boolean) : + : + + none: "do nothing" - local disks will be provisioned as on a regular compute instance. + + *Cannot be set alongside kubelet_ephemeral.* + """ + + +class PassthroughGroup(BaseModel): + requested: bool | None = None + """ + (Boolean) : + : + + Passthrough local disks from the underlying host. + + Devices are expected to appear in the guest as NVMe devices (nvme0, nvme1, ...), + but the exact number depends on the preset. + Enabled only when this field is explicitly set. + """ + + +class LocalDisks(BaseModel): + config: Config | None = None + """ + (Attributes) : + """ + passthroughGroup: PassthroughGroup | None = None + """ + (Attributes) : + """ + + +class Metadata(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + : + + Kubernetes Node labels. + + Keys and values must follow Kubernetes label syntax: + https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + + For now change will not be propagated to existing nodes, so will be applied only to Kubernetes Nodes created after the field change. + That behavior may change later. + So, for now you will need to manually set them to existing nodes, if that is needed. + + System labels containing "kubernetes.io" and "k8s.io" will be ignored. + Field change will NOT trigger NodeGroup roll out. + """ + + +class SecurityGroup(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class NetworkInterface(BaseModel): + publicIpAddress: dict[str, Any] | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroup] | None = None + """ + (Attributes List) User provided VPC Security Groups which will be assigned to all nodes of this NodeGroup. (see below for nested schema) + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID that will be attached to a node cloud instance network interface. + By default Cluster control plane subnet_id used. + Subnet should be located in the same network with control plane. + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class NvlInstanceGroupIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NvlInstanceGroupIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Nvlink(BaseModel): + nvlInstanceGroupId: str | None = None + """ + (String) Existing NVLInstanceGroup ID to use. + Existing NVLInstanceGroup ID to use. + """ + nvlInstanceGroupIdRef: NvlInstanceGroupIdRef | None = None + """ + Reference to a NvlInstanceGroup in compute to populate nvlInstanceGroupId. + """ + nvlInstanceGroupIdSelector: NvlInstanceGroupIdSelector | None = None + """ + Selector for a NvlInstanceGroup in compute to populate nvlInstanceGroupId. + """ + + +class ReservationPolicy(BaseModel): + policy: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `AUTO`: + 1) Will try to launch instance in any reservation_ids if provided. + 2) Will try to launch instance in any of the available capacity block. + 3) Will try to launch instance in PAYG if 1 & 2 are not satisfied. + + - `FORBID`: + The instance is launched only using on-demand (PAYG) capacity. + No attempt is made to find or use a Capacity Block. + It's an error to provide reservation_ids with policy = FORBID + + - `STRICT`: + 1) Will try to launch the instance in Capacity Blocks from reservation_ids if provided. + 2) If reservation_ids are not provided will try to launch instance in suitable & available Capacity Block. + 3) Fail otherwise. + """ + reservationIds: list[str] | None = None + """ + (List of String) Capacity block groups, order matters + Capacity block groups, order matters + """ + + +class Resources(BaseModel): + platform: str | None = None + """ + (String) + """ + preset: str | None = None + """ + (String) + """ + + +class ServiceAccountIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ServiceAccountIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Taint(BaseModel): + effect: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `EFFECT_UNSPECIFIED` + - `NO_EXECUTE` + - `NO_SCHEDULE` + - `PREFER_NO_SCHEDULE` + """ + key: str | None = None + """ + (String) + """ + value: str | None = None + """ + (String) + """ + + +class Template(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Parameters of a Node Nebius Compute Instance boot disk. (see below for nested schema) + """ + cloudInitUserDataSecretRef: CloudInitUserDataSecretRef | None = None + """ + (String, Sensitive) : + : + + cloud-init user-data + Should contain at least one SSH key. + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) : + """ + gpuCluster: GpuCluster | None = None + """ + (Attributes) Nebius Compute GPUCluster ID that will be attached to node. (see below for nested schema) + """ + gpuSettings: GpuSettings | None = None + """ + (Attributes) : + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + maxPods: float | None = None + """ + (Number) : + : + + The maximum number of Pods per node for your cluster. If omitted, MK8S assigns the default value of 110. When you + configure the maximum number of Pods per node for the cluster, MK8S uses this value to allocate a CIDR range for every node + in group. The node CIDR prefix is calculated as `32 - ceil(log2(2 * max_pods))`, i.e. the smallest IPv4 subnet whose total address + count is at least `2 * max_pods`. Not all IPs are usable for workload Pods because some of them are consumed by system Pods. + """ + metadata: Metadata | None = None + """ + (Attributes) : + """ + networkInterfaces: list[NetworkInterface] | None = None + """ + (Attributes List) (see below for nested schema) + """ + nvlink: Nvlink | None = None + """ + (Attributes) NVLinkSpec configures NVLink settings for the NodeGroup. (see below for nested schema) + """ + os: str | None = None + """ + (String) : + : + + OS version that will be used to create the boot disk of Compute Instances in the NodeGroup. + Supported platform / Kubernetes version / OS / driver presets combinations + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`, `cpu-e1`, `cpu-e2`, `cpu-d3`: + * `drivers_preset`: `""` + * `version`: 1.30 → `"ubuntu22.04"` + * `version`: 1.31 → `"ubuntu22.04"` (default), `"ubuntu24.04"` + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`: + * `drivers_preset`: `"cuda12"` (CUDA 12.4) + * `version`: 1.30, 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.4"` + * `version`: 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm`: + * `drivers_preset`: `""` + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12"` (CUDA 12.8) + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm-a`: + * `drivers_preset`: `""` + * `version`: 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + """ + preemptible: dict[str, Any] | None = None + """ + (Attributes) : + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) : + """ + resources: Resources | None = None + """ + (Attributes) Resources that will have Nebius Compute Instance where Node kubelet will run. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + the Nebius service account whose credentials will be available on the nodes of the group. + With these credentials, it is possible to make `nebius` CLI or public API requests from the nodes + without the need for extra authentication. + This service account is also used to make requests to container registry. + + `resource.serviceaccount.issueAccessToken` permission is required to use this field. + """ + serviceAccountIdRef: ServiceAccountIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate serviceAccountId. + """ + serviceAccountIdSelector: ServiceAccountIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate serviceAccountId. + """ + taints: list[Taint] | None = None + """ + (Attributes List) : + """ + + +class ForProvider(BaseModel): + autoRepair: AutoRepair | None = None + """ + (Attributes) Parameters for nodes auto repair. (see below for nested schema) + """ + autoscaling: Autoscaling | None = None + """ + (Attributes) : + """ + fixedNodeCount: float | None = None + """ + (Number) : + : + + Number of nodes in the group. Can be changed manually at any time. + + *Cannot be set alongside autoscaling.* + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Cluster in mk8s to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Cluster in mk8s to populate parentId. + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + template: Template | None = None + """ + (Attributes) : + """ + version: str | None = None + """ + (String) : + : + + Version is desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + By default the cluster control plane `.` version will be used. + """ + + +class InitProvider(BaseModel): + autoRepair: AutoRepair | None = None + """ + (Attributes) Parameters for nodes auto repair. (see below for nested schema) + """ + autoscaling: Autoscaling | None = None + """ + (Attributes) : + """ + fixedNodeCount: float | None = None + """ + (Number) : + : + + Number of nodes in the group. Can be changed manually at any time. + + *Cannot be set alongside autoscaling.* + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Cluster in mk8s to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Cluster in mk8s to populate parentId. + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + template: Template | None = None + """ + (Attributes) : + """ + version: str | None = None + """ + (String) : + : + + Version is desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + By default the cluster control plane `.` version will be used. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class LastOccurrence(BaseModel): + code: str | None = None + """ + (String) Event code (unique within the API service), in UpperCamelCase, e.g. "DiskAttached" + Event code (unique within the API service), in UpperCamelCase, e.g. `"DiskAttached"` + """ + level: str | None = None + """ + (String) : + : + + # Severity level for the event + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - Unspecified event severity level + - `DEBUG` - A debug event providing detailed insight. Such events are used to debug problems with specific resource(s) and process(es) + - `INFO` - A normal event or state change. Informs what is happening with the API resource. Does not require user attention or interaction + - `WARN`: + Warning event. Indicates a potential or minor problem with the API resource and/or the corresponding processes. Needs user attention, + but requires no immediate action (yet) + + - `ERROR` - Error event. Indicates a serious problem with the API resource and/or the corresponding processes. Requires immediate user action + """ + message: str | None = None + """ + (String) : + : + + A human-readable message describing what has happened + (and suggested actions for the user, if this is a `WARN` or `ERROR` level event) + """ + occurredAt: str | None = None + """ + (String) : + : + + # Time at which the event has occurred + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Event(BaseModel): + firstOccurredAt: str | None = None + """ + (String) : + : + + # Time of the first occurrence of a recurrent event + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + lastOccurrence: LastOccurrence | None = None + """ + (Attributes) : + """ + occurrenceCount: float | None = None + """ + (Number) The number of times this event has occurred between first_occurred_at and last_occurrence.occurred_at. Must be > 0 + The number of times this event has occurred between `first_occurred_at` and `last_occurrence.occurred_at`. Must be > 0 + """ + + +class Status(BaseModel): + events: list[Event] | None = None + """ + (Attributes List) : + """ + nodeCount: float | None = None + """ + (Number) : + : + + Total number of nodes that are currently in the node group. + Both ready and not ready nodes are counted. + """ + outdatedNodeCount: float | None = None + """ + (Number) : + : + + Total number of nodes that has outdated node configuration. + These nodes will be replaced by new nodes with up-to-date configuration. + """ + readyNodeCount: float | None = None + """ + (Number) : + : + + Total number of nodes that successfully joined the cluster and are ready to serve workloads. + Both outdated and up-to-date nodes are counted. + """ + reconciling: bool | None = None + """ + (Boolean) Show that there are changes are in flight. + Show that there are changes are in flight. + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `PROVISIONING` + - `RUNNING` + - `DELETING` + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + targetNodeCount: float | None = None + """ + (Number) : + : + + Desired total number of nodes that should be in the node group. + It is either `NodeGroupSpec.fixed_node_count` or arbitrary number between + `NodeGroupAutoscalingSpec.min_node_count` and `NodeGroupAutoscalingSpec.max_node_count` decided by autoscaler. + """ + version: str | None = None + """ + (String) : + : + + Actual version of NodeGroup. Have format `..-nebius-node.` like "1.30.0-nebius-node.10". + Where `..` is Kubernetes version and `` is version of Node infrastructure and configuration, + which update may include bug fixes, security updates and new features depending on worker node configuration. + """ + + +class ExistingFilesystemModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class GpuClusterModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class NetworkInterfaceModel(BaseModel): + publicIpAddress: dict[str, Any] | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroup] | None = None + """ + (Attributes List) User provided VPC Security Groups which will be assigned to all nodes of this NodeGroup. (see below for nested schema) + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID that will be attached to a node cloud instance network interface. + By default Cluster control plane subnet_id used. + Subnet should be located in the same network with control plane. + """ + + +class NvlinkModel(BaseModel): + nvlInstanceGroupId: str | None = None + """ + (String) Existing NVLInstanceGroup ID to use. + Existing NVLInstanceGroup ID to use. + """ + + +class TemplateModel(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Parameters of a Node Nebius Compute Instance boot disk. (see below for nested schema) + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) : + """ + gpuCluster: GpuClusterModel | None = None + """ + (Attributes) Nebius Compute GPUCluster ID that will be attached to node. (see below for nested schema) + """ + gpuSettings: GpuSettings | None = None + """ + (Attributes) : + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + maxPods: float | None = None + """ + (Number) : + : + + The maximum number of Pods per node for your cluster. If omitted, MK8S assigns the default value of 110. When you + configure the maximum number of Pods per node for the cluster, MK8S uses this value to allocate a CIDR range for every node + in group. The node CIDR prefix is calculated as `32 - ceil(log2(2 * max_pods))`, i.e. the smallest IPv4 subnet whose total address + count is at least `2 * max_pods`. Not all IPs are usable for workload Pods because some of them are consumed by system Pods. + """ + metadata: Metadata | None = None + """ + (Attributes) : + """ + networkInterfaces: list[NetworkInterfaceModel] | None = None + """ + (Attributes List) (see below for nested schema) + """ + nvlink: NvlinkModel | None = None + """ + (Attributes) NVLinkSpec configures NVLink settings for the NodeGroup. (see below for nested schema) + """ + os: str | None = None + """ + (String) : + : + + OS version that will be used to create the boot disk of Compute Instances in the NodeGroup. + Supported platform / Kubernetes version / OS / driver presets combinations + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`, `cpu-e1`, `cpu-e2`, `cpu-d3`: + * `drivers_preset`: `""` + * `version`: 1.30 → `"ubuntu22.04"` + * `version`: 1.31 → `"ubuntu22.04"` (default), `"ubuntu24.04"` + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`: + * `drivers_preset`: `"cuda12"` (CUDA 12.4) + * `version`: 1.30, 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.4"` + * `version`: 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm`: + * `drivers_preset`: `""` + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12"` (CUDA 12.8) + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm-a`: + * `drivers_preset`: `""` + * `version`: 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + """ + preemptible: dict[str, Any] | None = None + """ + (Attributes) : + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) : + """ + resources: Resources | None = None + """ + (Attributes) Resources that will have Nebius Compute Instance where Node kubelet will run. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + the Nebius service account whose credentials will be available on the nodes of the group. + With these credentials, it is possible to make `nebius` CLI or public API requests from the nodes + without the need for extra authentication. + This service account is also used to make requests to container registry. + + `resource.serviceaccount.issueAccessToken` permission is required to use this field. + """ + taints: list[Taint] | None = None + """ + (Attributes List) : + """ + + +class AtProvider(BaseModel): + autoRepair: AutoRepair | None = None + """ + (Attributes) Parameters for nodes auto repair. (see below for nested schema) + """ + autoscaling: Autoscaling | None = None + """ + (Attributes) : + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + fixedNodeCount: float | None = None + """ + (Number) : + : + + Number of nodes in the group. Can be changed manually at any time. + + *Cannot be set alongside autoscaling.* + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + template: TemplateModel | None = None + """ + (Attributes) : + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + version: str | None = None + """ + (String) : + : + + Version is desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + By default the cluster control plane `.` version will be used. + """ + + +class ConditionModel(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[ConditionModel] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class NodeGroup(BaseModel): + apiVersion: Literal['mk8s.nebius.m.upbound.io/v1beta1'] | None = ( + 'mk8s.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['NodeGroup'] | None = 'NodeGroup' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NodeGroupSpec defines the desired state of NodeGroup + """ + status: StatusModel | None = None + """ + NodeGroupStatus defines the observed state of NodeGroup. + """ + + +class NodeGroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[NodeGroup] + """ + List of nodegroups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/mysterybox/__init__.py b/schemas/python/models/io/upbound/m/nebius/mysterybox/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/mysterybox/secret/__init__.py b/schemas/python/models/io/upbound/m/nebius/mysterybox/secret/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/mysterybox/secret/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/mysterybox/secret/v1beta1.py new file mode 100644 index 000000000..a77f8ca9c --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/mysterybox/secret/v1beta1.py @@ -0,0 +1,344 @@ +# generated by datamodel-codegen: +# filename: workdir/mysterybox_nebius_m_upbound_io_v1beta1_secret.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) Description of the secret. + Description of the secret. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) Description of the secret. + Description of the secret. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class SecretVersion(BaseModel): + description: str | None = None + """ + (String) Description of the secret. + Description of the version. + """ + payload: list[dict[str, Any]] | None = None + """ + (Attributes List) : + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + (String) : + : + + # Time when user called soft delete method + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + effectiveKmsKeyId: str | None = None + """ + (String) + """ + purgeAt: str | None = None + """ + (String) : + : + + # Time when key should be totally deleted from DB + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + (String) : + : + + State (ACTIVE, SCHEDULED_FOR_DELETION) + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` - Resource is active, ready for use + - `SCHEDULED_FOR_DELETION` - Resource was marked as soft deleted + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) Description of the secret. + Description of the secret. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + primaryVersionId: str | None = None + """ + (String) Specifies the primary version of the secret to update its payload. This parameter should only be provided during update operations. + Specifies the primary version of the secret to update its payload. This parameter should only be provided during update operations. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + secretVersion: SecretVersion | None = None + """ + (Attributes) : + """ + status: Status | None = None + """ + (Attributes) The status of the secret. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Secret(BaseModel): + apiVersion: Literal['mysterybox.nebius.m.upbound.io/v1beta1'] | None = ( + 'mysterybox.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Secret'] | None = 'Secret' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecretSpec defines the desired state of Secret + """ + status: StatusModel | None = None + """ + SecretStatus defines the observed state of Secret. + """ + + +class SecretList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Secret] + """ + List of secrets. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/mysterybox/secretversion/__init__.py b/schemas/python/models/io/upbound/m/nebius/mysterybox/secretversion/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/mysterybox/secretversion/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/mysterybox/secretversion/v1beta1.py new file mode 100644 index 000000000..cf1057ace --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/mysterybox/secretversion/v1beta1.py @@ -0,0 +1,457 @@ +# generated by datamodel-codegen: +# filename: workdir/mysterybox_nebius_m_upbound_io_v1beta1_secretversion.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class BinaryValueSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class StringValueSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class PayloadItem(BaseModel): + binaryValueSecretRef: BinaryValueSecretRef | None = None + """ + (String, Sensitive) : + : + + The binary data to encrypt and store in the version of the secret. + + *Cannot be set alongside string_value.* + """ + key: str | None = None + """ + confidential key of the payload entry. + Non-confidential key of the payload entry. + """ + stringValueSecretRef: StringValueSecretRef | None = None + """ + (String, Sensitive) : + : + + The text data to encrypt and store in the version of the secret. + + *Cannot be set alongside binary_value.* + """ + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) Description of the version. + Description of the version. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Secret in mysterybox to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Secret in mysterybox to populate parentId. + """ + payload: list[PayloadItem] | None = None + """ + (Attributes List) : + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) Description of the version. + Description of the version. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Secret in mysterybox to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Secret in mysterybox to populate parentId. + """ + payload: list[PayloadItem] | None = None + """ + (Attributes List) : + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class PayloadItemModel(BaseModel): + key: str | None = None + """ + confidential key of the payload entry. + Non-confidential key of the payload entry. + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + (String) : + : + + # Time when user called soft delete method + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + purgeAt: str | None = None + """ + (String) : + : + + # Time when key should be totally deleted from DB + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + (String) : + : + + State (ACTIVE, SCHEDULED_FOR_DELETION) + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` - Resource is active, ready for use + - `SCHEDULED_FOR_DELETION` - Resource was marked as soft deleted + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) Description of the version. + Description of the version. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + payload: list[PayloadItemModel] | None = None + """ + (Attributes List) : + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + status: Status | None = None + """ + (Attributes) The status of the secret version. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SecretVersion(BaseModel): + apiVersion: Literal['mysterybox.nebius.m.upbound.io/v1beta1'] | None = ( + 'mysterybox.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SecretVersion'] | None = 'SecretVersion' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecretVersionSpec defines the desired state of SecretVersion + """ + status: StatusModel | None = None + """ + SecretVersionStatus defines the observed state of SecretVersion. + """ + + +class SecretVersionList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SecretVersion] + """ + List of secretversions. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/providerconfig/__init__.py b/schemas/python/models/io/upbound/m/nebius/providerconfig/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/providerconfig/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/providerconfig/v1beta1.py new file mode 100644 index 000000000..265acb80e --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/providerconfig/v1beta1.py @@ -0,0 +1,198 @@ +# generated by datamodel-codegen: +# filename: workdir/nebius_m_upbound_io_v1beta1_providerconfig.yaml + +from __future__ import annotations + +from typing import Literal + +from pydantic import AwareDatetime, BaseModel + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Env(BaseModel): + name: str + """ + Name is the name of an environment variable. + """ + + +class Fs(BaseModel): + path: str + """ + Path is a filesystem path. + """ + + +class SecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class Credentials(BaseModel): + env: Env | None = None + """ + Env is a reference to an environment variable that contains credentials + that must be used to connect to the provider. + """ + fs: Fs | None = None + """ + Fs is a reference to a filesystem location that contains credentials that + must be used to connect to the provider. + """ + secretRef: SecretRef | None = None + """ + A SecretRef is a reference to a secret key in the same namespace as the + referencing managed resource that contains the credentials that must be + used to connect to the provider. + """ + source: Literal['None', 'Secret', 'InjectedIdentity', 'Environment', 'Filesystem'] + """ + Source of the provider credentials. + """ + + +class Identity(BaseModel): + type: Literal['Token', 'ServiceAccount'] + """ + Type specifies the authentication method. + Token: authenticate using a static IAM token from the credentials secret key "token". + ServiceAccount: authenticate using a service-account key (account_id, public_key_id, + private_key) from the credentials secret. + """ + + +class ExponentialFailureRateLimiter(BaseModel): + baseDelay: str | None = None + """ + BaseDelay is the initial delay between retries. + """ + maxDelay: str | None = None + """ + MaxDelay is the maximum delay between retries. + """ + + +class ReconciliationPolicy(BaseModel): + exponentialFailureRateLimiter: ExponentialFailureRateLimiter | None = None + """ + ExponentialFailureRateLimiter, when set, overrides the parameters of the + exponential failure rate limiter used to schedule retries for the + managed resource that this policy applies to. + """ + + +class Spec(BaseModel): + credentials: Credentials + """ + Credentials required to authenticate to this provider. + """ + identity: Identity + """ + Identity specifies the authentication identity configuration. + """ + projectID: str | None = None + """ + ProjectID is the Nebius project ID used as the default parent for + project-parented resources. Individual resources may override it via + spec.forProvider.parentId. Optional. + """ + reconciliationPolicy: ReconciliationPolicy | None = None + """ + ReconciliationPolicy configures how a managed resource is reconciled. + It currently allows overriding the controller's failure rate limiter + parameters on a per-resource basis via ExponentialFailureRateLimiter. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + users: int | None = None + """ + Users of this provider configuration. + """ + + +class ProviderConfig(BaseModel): + apiVersion: Literal['nebius.m.upbound.io/v1beta1'] | None = ( + 'nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ProviderConfig'] | None = 'ProviderConfig' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + A NamespacedProviderConfigSpec defines the desired state of a namespaced + ProviderConfig. It mirrors ProviderConfigSpec but its credential secret + references omit the namespace: they implicitly resolve to the namespace of + the referencing managed resource. + """ + status: Status | None = None + """ + A ProviderConfigStatus reflects the observed state of a ProviderConfig. + """ + + +class ProviderConfigList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ProviderConfig] + """ + List of providerconfigs. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/providerconfigusage/__init__.py b/schemas/python/models/io/upbound/m/nebius/providerconfigusage/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/providerconfigusage/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/providerconfigusage/v1beta1.py new file mode 100644 index 000000000..2f12129ba --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/providerconfigusage/v1beta1.py @@ -0,0 +1,84 @@ +# generated by datamodel-codegen: +# filename: workdir/nebius_m_upbound_io_v1beta1_providerconfigusage.yaml + +from __future__ import annotations + +from typing import Literal + +from pydantic import BaseModel + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class ResourceRef(BaseModel): + apiVersion: str + """ + APIVersion of the referenced object. + """ + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + uid: str | None = None + """ + UID of the referenced object. + """ + + +class ProviderConfigUsage(BaseModel): + apiVersion: Literal['nebius.m.upbound.io/v1beta1'] | None = ( + 'nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ProviderConfigUsage'] | None = 'ProviderConfigUsage' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + providerConfigRef: ProviderConfigRef + """ + ProviderConfigReference to the provider config being used. + """ + resourceRef: ResourceRef + """ + ResourceReference to the managed resource using the provider config. + """ + + +class ProviderConfigUsageList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ProviderConfigUsage] + """ + List of providerconfigusages. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/quotas/__init__.py b/schemas/python/models/io/upbound/m/nebius/quotas/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/quotas/quotaallowance/__init__.py b/schemas/python/models/io/upbound/m/nebius/quotas/quotaallowance/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/quotas/quotaallowance/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/quotas/quotaallowance/v1beta1.py new file mode 100644 index 000000000..739827add --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/quotas/quotaallowance/v1beta1.py @@ -0,0 +1,390 @@ +# generated by datamodel-codegen: +# filename: workdir/quotas_nebius_m_upbound_io_v1beta1_quotaallowance.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limit: float | None = None + """ + (Number) Total amount of resources allocated. + Total amount of resources allocated. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + (String) : + : + + Name of the region where the quota is allocated. + Example: "eu-north1". + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limit: float | None = None + """ + (Number) Total amount of resources allocated. + Total amount of resources allocated. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + (String) : + : + + Name of the region where the quota is allocated. + Example: "eu-north1". + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + description: str | None = None + """ + (String) : + : + + Human-readable description of the quota. + Example: "Total RAM across VMs". + """ + service: str | None = None + """ + (String) : + : + + Service in which the quota is allocated. + Example: "mk8s". + """ + serviceDescription: str | None = None + """ + (String) : + : + + Human-readable name of the service managing the quota. + Example: "Managed Kubernetes®". + """ + state: str | None = None + """ + (String) : + : + + Current state of the quota. + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `STATE_PROVISIONING` - Quota is being allocated; the process can take up to several minutes. + - `STATE_ACTIVE` - Quota is allocated and can be used. + - `STATE_FROZEN` - Quota is allocated but cannot be used any longer + - `STATE_DELETED` - Quota has been removed and is no longer allocated. + """ + unit: str | None = None + """ + (String) : + : + + Quota unit. + Example: "byte". + """ + usage: float | None = None + """ + (Number) Current quota usage. + Current quota usage. + """ + usagePercentage: str | None = None + """ + (String) : + : + + Current quota usage as a percentage. + Values range from 0.0 to 1.0, representing 0% to 100%. + Values can exceed 1.0 if usage exceeds the limit. + Example: "0.12". + """ + usageState: str | None = None + """ + (String) : + : + + Current state of the quota usage. + + #### Supported values + + Possible values: + + - `USAGE_STATE_UNSPECIFIED` + - `USAGE_STATE_USED` - Quota is actively in use. + - `USAGE_STATE_NOT_USED` - Quota is not currently in use. + - `USAGE_STATE_UNKNOWN`: + Quota region is unreachable, the current usage is therefore unknown. + Please, retry the request later. + + - `USAGE_STATE_NOT_APPLICABLE` - Quota usage is not applicable + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limit: float | None = None + """ + (Number) Total amount of resources allocated. + Total amount of resources allocated. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + (String) : + : + + Name of the region where the quota is allocated. + Example: "eu-north1". + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class QuotaAllowance(BaseModel): + apiVersion: Literal['quotas.nebius.m.upbound.io/v1beta1'] | None = ( + 'quotas.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['QuotaAllowance'] | None = 'QuotaAllowance' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + QuotaAllowanceSpec defines the desired state of QuotaAllowance + """ + status: StatusModel | None = None + """ + QuotaAllowanceStatus defines the observed state of QuotaAllowance. + """ + + +class QuotaAllowanceList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[QuotaAllowance] + """ + List of quotaallowances. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/registry/__init__.py b/schemas/python/models/io/upbound/m/nebius/registry/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/registry/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/registry/v1beta1.py new file mode 100644 index 000000000..c8141b636 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/registry/v1beta1.py @@ -0,0 +1,307 @@ +# generated by datamodel-codegen: +# filename: workdir/registry_nebius_m_upbound_io_v1beta1_registry.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + imagesCount: float | None = None + """ + (Number) Registry.Type type = 2; + """ + registryFqdn: str | None = None + """ + north1.nebius.cloud" + regional fqdn "cr.eu-north1.nebius.cloud" + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `CREATING` + - `ACTIVE` + - `DELETING` + - `SUSPENDED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + imagesCount: float | None = None + """ + (Number) Registry.Type type = 2; + Registry.Type type = 2; + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) This is filled in by the server and reports the current state of the system. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Registry(BaseModel): + apiVersion: Literal['registry.nebius.m.upbound.io/v1beta1'] | None = ( + 'registry.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Registry'] | None = 'Registry' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RegistrySpec defines the desired state of Registry + """ + status: StatusModel | None = None + """ + RegistryStatus defines the observed state of Registry. + """ + + +class RegistryList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Registry] + """ + List of registries. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/storage/__init__.py b/schemas/python/models/io/upbound/m/nebius/storage/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/storage/bucket/__init__.py b/schemas/python/models/io/upbound/m/nebius/storage/bucket/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/storage/bucket/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/storage/bucket/v1beta1.py new file mode 100644 index 000000000..46e24cd3b --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/storage/bucket/v1beta1.py @@ -0,0 +1,1252 @@ +# generated by datamodel-codegen: +# filename: workdir/storage_nebius_m_upbound_io_v1beta1_bucket.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Rule(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) : + """ + groupId: str | None = None + """ + (String) : + : + + Group ID to grant access to. + + *Cannot be set alongside anonymous.* + """ + paths: list[str] | None = None + """ + (List of String) : + : + + A list of paths each of which is either a full object key or a prefix ending with a + single "*" wildcard character. A rule is only applied to objects matching any of paths. + If there is a path equal to "*", a rule applies to a whole bucket. + """ + roles: list[str] | None = None + """ + (List of String) A set of roles which a subject will have. All storage.* roles are supported. + A set of roles which a subject will have. All `storage.*` roles are supported. + """ + + +class BucketPolicy(BaseModel): + rules: list[Rule] | None = None + """ + (Attributes List) : + """ + + +class RuleModel(BaseModel): + allowedHeaders: list[str] | None = None + """ + Control-Request-Headers header + Headers that are allowed in a preflight request through the Access-Control-Request-Headers header + """ + allowedMethods: list[str] | None = None + """ + (List of String) HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + """ + allowedOrigins: list[str] | None = None + """ + domain requests from. Single wildcard * is allowed. + The origins that you want to allow cross-domain requests from. Single wildcard * is allowed. + """ + exposeHeaders: list[str] | None = None + """ + (List of String) Headers in the response that you want customers to be able to access from their applications. + Headers in the response that you want customers to be able to access from their applications. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Optional rule identifier. + """ + maxAgeSeconds: float | None = None + """ + (Number) Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + """ + + +class Cors(BaseModel): + rules: list[RuleModel] | None = None + """ + (Attributes List) : + """ + + +class Condition(BaseModel): + methods: list[str] | None = None + """ + (List of String) : + : + + The s3 methods to match. + An empty list matches all methods + + #### Supported values + + Possible values: + + - `METHOD_UNSPECIFIED` + - `GET_OBJECT` + - `HEAD_OBJECT` + - `GET_OBJECT_TAGGING` + - `COPY_OBJECT`: + Copy object method reads the source object. + We account for those operations as source object accesses when calculating `days_since_last_access` for source object. + + - `UPLOAD_PART_COPY`: + Upload part copy method reads the source object. + We account for those operations as source object accesses when calculating `days_since_last_access` for source object. + """ + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `TYPE_UNSPECIFIED` + - `INCLUDE`: + If an include type condition is the first condition that the request match, the request will be included in + `days_since_last_access` calculation. + + - `EXCLUDE`: + If an exclude type condition is the first condition that the request match, the request will be ignored in `days_since_last_access` + calculation. + """ + userAgents: list[str] | None = None + """ + (List of String) : + : + + User agents to match. Condition is satisfied if the request's user agent contains any of these substrings. + An empty list matches all user agents. + """ + + +class LastAccessFilter(BaseModel): + conditions: list[Condition] | None = None + """ + (Attributes List) : + """ + + +class AbortIncompleteMultipartUpload(BaseModel): + daysAfterInitiation: float | None = None + """ + (Number) : + : + + Specifies the days since the initiation of an incomplete multipart upload that + the system will wait before permanently removing all parts of the upload. + """ + + +class Expiration(BaseModel): + date: str | None = None + """ + (String) : + : + + Indicates at what date the object will be deleted. The time is always midnight UTC. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + + *Cannot be set alongside days.* + """ + days: float | None = None + """ + (Number) : + : + + Indicates the lifetime, in days, of the objects that are subject to the rule. + The value must be a non-zero positive integer. + + *Cannot be set alongside date.* + """ + expiredObjectDeleteMarker: bool | None = None + """ + (Boolean) : + : + + Indicates whether the system will remove a "delete marker" with no noncurrent versions. + If set to true, the "delete marker" will be permanently removed. + If set to false the policy takes no action. + This cannot be specified with Days or Date in a LifecycleExpiration Policy. + """ + + +class Tag(BaseModel): + key: str | None = None + """ + (String) + """ + value: str | None = None + """ + (String) + """ + + +class Filter(BaseModel): + objectSizeGreaterThanBytes: float | None = None + """ + (Number) Minimum object size to which the rule applies. + Minimum object size to which the rule applies. + """ + objectSizeLessThanBytes: float | None = None + """ + (Number) Maximum object size to which the rule applies. + Maximum object size to which the rule applies. + """ + prefix: str | None = None + """ + (String) : + : + + Prefix identifying one or more objects to which the rule applies. + If prefix is empty, the rule applies to all objects in the bucket. + """ + tags: list[Tag] | None = None + """ + (Attributes List) : + """ + + +class NoncurrentVersionExpiration(BaseModel): + newerNoncurrentVersions: float | None = None + """ + (Number) Specifies how many noncurrent versions the system will retain. + Specifies how many noncurrent versions the system will retain. + """ + noncurrentDays: float | None = None + """ + (Number) Specifies the number of days an object is noncurrent before the system will expire it. + Specifies the number of days an object is noncurrent before the system will expire it. + """ + + +class NoncurrentVersionTransition(BaseModel): + newerNoncurrentVersions: float | None = None + """ + (Number) Specifies how many noncurrent versions the system will retain. + Specifies how many noncurrent versions the system will retain without transition. + """ + noncurrentDays: float | None = None + """ + (Number) Specifies the number of days an object is noncurrent before the system will expire it. + Specifies the number of days an object is noncurrent before the system will transit it. + """ + storageClass: str | None = None + """ + (String) : + : + + Target storage class to transit to. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + + +class Transition(BaseModel): + date: str | None = None + """ + (String) : + : + + Indicates at what date the object will be transited. The time is always midnight UTC. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + + *Cannot be set alongside days or days_since_last_access.* + """ + days: float | None = None + """ + (Number) : + : + + Amount of days since object was uploaded before it's transited to a new storage class. + The value must be a non-zero positive integer. + + *Cannot be set alongside date or days_since_last_access.* + """ + daysSinceLastAccess: float | None = None + """ + calculations for all transition rules. + : + + The number of days since the object was last accessed before it is transitioned. + + *Cannot be set alongside date or days.* + """ + storageClass: str | None = None + """ + (String) : + : + + Target storage class to transit to. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + + +class RuleModel1(BaseModel): + abortIncompleteMultipartUpload: AbortIncompleteMultipartUpload | None = None + """ + (Attributes) : + """ + expiration: Expiration | None = None + """ + (Attributes) : + """ + filter: Filter | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Unique identifier for the rule per configuration. + The value cannot be longer than 255 characters. + """ + noncurrentVersionExpiration: NoncurrentVersionExpiration | None = None + """ + (Attributes) : + """ + noncurrentVersionTransition: NoncurrentVersionTransition | None = None + """ + (Attributes) : + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + #### Supported values + + Possible values: + + - `STATUS_UNSPECIFIED` + - `ENABLED` + - `DISABLED` + """ + transition: Transition | None = None + """ + (Attributes) : + """ + + +class LifecycleConfiguration(BaseModel): + lastAccessFilter: LastAccessFilter | None = None + """ + (Attributes) : + """ + rules: list[RuleModel1] | None = None + """ + (Attributes List) : + """ + + +class ForProvider(BaseModel): + bucketPolicy: BucketPolicy | None = None + """ + (Attributes) : + """ + cors: Cors | None = None + """ + (Attributes) : + """ + defaultStorageClass: str | None = None + """ + (String) : + : + + Storage class to use by default for uploads to the bucket. It may be overridden by `x-amz-storage-class` header. + If not set - STANDARD is used as a default storage class. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + forceStorageClass: bool | None = None + """ + amz-storage-class header. + Flag to force usage of default_storage_class, ignoring `x-amz-storage-class` header. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + lifecycleConfiguration: LifecycleConfiguration | None = None + """ + (Attributes) : + """ + maxSizeBytes: float | None = None + """ + (Number) : + : + + Maximum bucket size. + Zero means unlimited. + Actual limit can be lower if customer doesn't have enough quota. + Real bucket size can go a little higher if customer writes too fast. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + objectAuditLogging: str | None = None + """ + (String) : + : + + Object audit logging specifies which requests must be logged - none, all or mutational only. + + #### Supported values + + Possible values: + + - `OBJECT_AUDIT_LOGGING_UNSPECIFIED` + - `NONE` - Logging is disabled. + - `MUTATE_ONLY` - Logging enabled only for mutating requests. + - `ALL` - Logging enabled for all requests. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + versioningPolicy: str | None = None + """ + (String) : + : + + Supports transitions: + * disabled -\\> enabled + * disabled -\\> suspended + * enabled \\<-\\> suspended + + #### Supported values + + Possible values: + + - `VERSIONING_POLICY_UNSPECIFIED` + - `DISABLED` + - `ENABLED` + - `SUSPENDED` + """ + + +class RuleModel2(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) : + """ + groupId: str | None = None + """ + (String) : + : + + Group ID to grant access to. + + *Cannot be set alongside anonymous.* + """ + paths: list[str] | None = None + """ + (List of String) : + : + + A list of paths each of which is either a full object key or a prefix ending with a + single "*" wildcard character. A rule is only applied to objects matching any of paths. + If there is a path equal to "*", a rule applies to a whole bucket. + """ + roles: list[str] | None = None + """ + (List of String) A set of roles which a subject will have. All storage.* roles are supported. + A set of roles which a subject will have. All `storage.*` roles are supported. + """ + + +class RuleModel3(BaseModel): + allowedHeaders: list[str] | None = None + """ + Control-Request-Headers header + Headers that are allowed in a preflight request through the Access-Control-Request-Headers header + """ + allowedMethods: list[str] | None = None + """ + (List of String) HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + """ + allowedOrigins: list[str] | None = None + """ + domain requests from. Single wildcard * is allowed. + The origins that you want to allow cross-domain requests from. Single wildcard * is allowed. + """ + exposeHeaders: list[str] | None = None + """ + (List of String) Headers in the response that you want customers to be able to access from their applications. + Headers in the response that you want customers to be able to access from their applications. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Optional rule identifier. + """ + maxAgeSeconds: float | None = None + """ + (Number) Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + """ + + +class RuleModel4(BaseModel): + abortIncompleteMultipartUpload: AbortIncompleteMultipartUpload | None = None + """ + (Attributes) : + """ + expiration: Expiration | None = None + """ + (Attributes) : + """ + filter: Filter | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Unique identifier for the rule per configuration. + The value cannot be longer than 255 characters. + """ + noncurrentVersionExpiration: NoncurrentVersionExpiration | None = None + """ + (Attributes) : + """ + noncurrentVersionTransition: NoncurrentVersionTransition | None = None + """ + (Attributes) : + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + #### Supported values + + Possible values: + + - `STATUS_UNSPECIFIED` + - `ENABLED` + - `DISABLED` + """ + transition: Transition | None = None + """ + (Attributes) : + """ + + +class InitProvider(BaseModel): + bucketPolicy: BucketPolicy | None = None + """ + (Attributes) : + """ + cors: Cors | None = None + """ + (Attributes) : + """ + defaultStorageClass: str | None = None + """ + (String) : + : + + Storage class to use by default for uploads to the bucket. It may be overridden by `x-amz-storage-class` header. + If not set - STANDARD is used as a default storage class. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + forceStorageClass: bool | None = None + """ + amz-storage-class header. + Flag to force usage of default_storage_class, ignoring `x-amz-storage-class` header. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + lifecycleConfiguration: LifecycleConfiguration | None = None + """ + (Attributes) : + """ + maxSizeBytes: float | None = None + """ + (Number) : + : + + Maximum bucket size. + Zero means unlimited. + Actual limit can be lower if customer doesn't have enough quota. + Real bucket size can go a little higher if customer writes too fast. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + objectAuditLogging: str | None = None + """ + (String) : + : + + Object audit logging specifies which requests must be logged - none, all or mutational only. + + #### Supported values + + Possible values: + + - `OBJECT_AUDIT_LOGGING_UNSPECIFIED` + - `NONE` - Logging is disabled. + - `MUTATE_ONLY` - Logging enabled only for mutating requests. + - `ALL` - Logging enabled for all requests. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + versioningPolicy: str | None = None + """ + (String) : + : + + Supports transitions: + * disabled -\\> enabled + * disabled -\\> suspended + * enabled \\<-\\> suspended + + #### Supported values + + Possible values: + + - `VERSIONING_POLICY_UNSPECIFIED` + - `DISABLED` + - `ENABLED` + - `SUSPENDED` + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class RuleModel5(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) : + """ + groupId: str | None = None + """ + (String) : + : + + Group ID to grant access to. + + *Cannot be set alongside anonymous.* + """ + paths: list[str] | None = None + """ + (List of String) : + : + + A list of paths each of which is either a full object key or a prefix ending with a + single "*" wildcard character. A rule is only applied to objects matching any of paths. + If there is a path equal to "*", a rule applies to a whole bucket. + """ + roles: list[str] | None = None + """ + (List of String) A set of roles which a subject will have. All storage.* roles are supported. + A set of roles which a subject will have. All `storage.*` roles are supported. + """ + + +class RuleModel6(BaseModel): + allowedHeaders: list[str] | None = None + """ + Control-Request-Headers header + Headers that are allowed in a preflight request through the Access-Control-Request-Headers header + """ + allowedMethods: list[str] | None = None + """ + (List of String) HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + """ + allowedOrigins: list[str] | None = None + """ + domain requests from. Single wildcard * is allowed. + The origins that you want to allow cross-domain requests from. Single wildcard * is allowed. + """ + exposeHeaders: list[str] | None = None + """ + (List of String) Headers in the response that you want customers to be able to access from their applications. + Headers in the response that you want customers to be able to access from their applications. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Optional rule identifier. + """ + maxAgeSeconds: float | None = None + """ + (Number) Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + """ + + +class RuleModel7(BaseModel): + abortIncompleteMultipartUpload: AbortIncompleteMultipartUpload | None = None + """ + (Attributes) : + """ + expiration: Expiration | None = None + """ + (Attributes) : + """ + filter: Filter | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Unique identifier for the rule per configuration. + The value cannot be longer than 255 characters. + """ + noncurrentVersionExpiration: NoncurrentVersionExpiration | None = None + """ + (Attributes) : + """ + noncurrentVersionTransition: NoncurrentVersionTransition | None = None + """ + (Attributes) : + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + #### Supported values + + Possible values: + + - `STATUS_UNSPECIFIED` + - `ENABLED` + - `DISABLED` + """ + transition: Transition | None = None + """ + (Attributes) : + """ + + +class Counters(BaseModel): + inflightPartsQuantity: float | None = None + """ + (Number) + """ + inflightPartsSize: float | None = None + """ + (Number) + """ + multipartObjectsQuantity: float | None = None + """ + (Number) + """ + multipartObjectsSize: float | None = None + """ + (Number) + """ + multipartUploadsQuantity: float | None = None + """ + (Number) + """ + simpleObjectsQuantity: float | None = None + """ + (Number) + """ + simpleObjectsSize: float | None = None + """ + (Number) + """ + + +class NonCurrentCounters(BaseModel): + multipartObjectsQuantity: float | None = None + """ + (Number) + """ + multipartObjectsSize: float | None = None + """ + (Number) + """ + simpleObjectsQuantity: float | None = None + """ + (Number) + """ + simpleObjectsSize: float | None = None + """ + (Number) + """ + + +class Counter(BaseModel): + counters: Counters | None = None + """ + (Attributes List) (see below for nested schema) + """ + nonCurrentCounters: NonCurrentCounters | None = None + """ + (Attributes) : + """ + storageClass: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + + +class Status(BaseModel): + anonymousAccessEnabled: bool | None = None + """ + (Boolean) : + : + + Indicator flag showing whether the bucket has any BucketPolicy rule + that grants anonymous access to any object, prefix, or the entire bucket. + """ + counters: list[Counter] | None = None + """ + (Attributes List) (see below for nested schema) + """ + deletedAt: str | None = None + """ + (String) : + : + + The time when the bucket was deleted (or scheduled for deletion). + It resets to null if the bucket is undeleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + domainName: str | None = None + """ + (String) : + : + + The domain of the endpoint where the bucket can be accessed. It omits the scheme (HTTPS) and the port (443) + and contains only the FQDN address. + """ + purgeAt: str | None = None + """ + (String) : + : + + The time when the bucket will be automatically purged in case it was soft-deleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + region: str | None = None + """ + west1". + The name of the region where the bucket is located for use with S3 clients, i.e. "eu-west1". + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `CREATING` - Bucket is under creation and cannot be used yet. + - `ACTIVE` - Bucket is active and ready for usage. + - `UPDATING`: + Bucket is being updated. + It can be used, but some settings are being modified and you can observe their inconsistency. + + - `SCHEDULED_FOR_DELETION`: + Bucket is scheduled for deletion. + It cannot be used in s3 api anymore. + """ + suspensionState: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `SUSPENSION_STATE_UNSPECIFIED` + - `NOT_SUSPENDED` + - `SUSPENDED` + """ + + +class AtProvider(BaseModel): + bucketPolicy: BucketPolicy | None = None + """ + (Attributes) : + """ + cors: Cors | None = None + """ + (Attributes) : + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + defaultStorageClass: str | None = None + """ + (String) : + : + + Storage class to use by default for uploads to the bucket. It may be overridden by `x-amz-storage-class` header. + If not set - STANDARD is used as a default storage class. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + forceStorageClass: bool | None = None + """ + amz-storage-class header. + Flag to force usage of default_storage_class, ignoring `x-amz-storage-class` header. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + lifecycleConfiguration: LifecycleConfiguration | None = None + """ + (Attributes) : + """ + maxSizeBytes: float | None = None + """ + (Number) : + : + + Maximum bucket size. + Zero means unlimited. + Actual limit can be lower if customer doesn't have enough quota. + Real bucket size can go a little higher if customer writes too fast. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + objectAuditLogging: str | None = None + """ + (String) : + : + + Object audit logging specifies which requests must be logged - none, all or mutational only. + + #### Supported values + + Possible values: + + - `OBJECT_AUDIT_LOGGING_UNSPECIFIED` + - `NONE` - Logging is disabled. + - `MUTATE_ONLY` - Logging enabled only for mutating requests. + - `ALL` - Logging enabled for all requests. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + versioningPolicy: str | None = None + """ + (String) : + : + + Supports transitions: + * disabled -\\> enabled + * disabled -\\> suspended + * enabled \\<-\\> suspended + + #### Supported values + + Possible values: + + - `VERSIONING_POLICY_UNSPECIFIED` + - `DISABLED` + - `ENABLED` + - `SUSPENDED` + """ + + +class ConditionModel(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[ConditionModel] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Bucket(BaseModel): + apiVersion: Literal['storage.nebius.m.upbound.io/v1beta1'] | None = ( + 'storage.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Bucket'] | None = 'Bucket' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + BucketSpec defines the desired state of Bucket + """ + status: StatusModel | None = None + """ + BucketStatus defines the observed state of Bucket. + """ + + +class BucketList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Bucket] + """ + List of buckets. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/storage/transfer/__init__.py b/schemas/python/models/io/upbound/m/nebius/storage/transfer/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/storage/transfer/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/storage/transfer/v1beta1.py new file mode 100644 index 000000000..6d493d5aa --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/storage/transfer/v1beta1.py @@ -0,0 +1,1185 @@ +# generated by datamodel-codegen: +# filename: workdir/storage_nebius_m_upbound_io_v1beta1_transfer.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class AfterNEmptyIterations(BaseModel): + emptyIterationsThreshold: float | None = None + """ + (Number) Number of consecutive iterations with zero transferred objects required to stop transfer. + Number of consecutive iterations with zero transferred objects required to stop transfer. + """ + + +class AccessKeyIdSecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class SecretAccessKeySecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class AccessKey(BaseModel): + accessKeyIdSecretRef: AccessKeyIdSecretRef | None = None + """ + (String) Access key ID. + Access key ID. + """ + secretAccessKeySecretRef: SecretAccessKeySecretRef | None = None + """ + (String, Sensitive) Secret access key. + Secret access key. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class BucketNameRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class BucketNameSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Nebius(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the destination bucket is located. + """ + + +class S3Compatible(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where destination bucket is located. + """ + + +class Destination(BaseModel): + nebius: Nebius | None = None + """ + (Attributes) Cannot be set alongside s3_compatible. (see below for nested schema) + """ + prefix: str | None = None + """ + (String) : + : + + Prefix to add to the beginning of each transferred object key in the destination. + During transfer, the resulting object key in the destination is computed + by removing source.prefix (if provided) from the original key and then prepending destination.prefix. + Important: This transformation may result in an empty object key or one that exceeds allowed length limits. + Use prefixes that guarantee valid resulting object keys for your objects after transformation. + """ + s3Compatible: S3Compatible | None = None + """ + (Attributes) Cannot be set alongside nebius. (see below for nested schema) + """ + + +class Limiters(BaseModel): + bandwidthBytesPerSecond: float | None = None + """ + (Number) Maximum bandwidth in bytes per second. If set to zero, default limit will be applied. + Maximum bandwidth in bytes per second. If set to zero, default limit will be applied. + """ + requestsPerSecond: float | None = None + """ + (Number) Maximum number of requests per second. If set to zero, default limit will be applied. + Maximum number of requests per second. If set to zero, default limit will be applied. + """ + + +class AccessKeySecretRef(BaseModel): + key: str + name: str + """ + Name of the secret. + """ + + +class AzureStorageAccount(BaseModel): + accessKeySecretRef: AccessKeySecretRef | None = None + """ + (Attributes) (see below for nested schema) + Storage account access key. + """ + accountName: str | None = None + """ + (String) Storage account name. + Storage account name. + """ + + +class AzureBlobStorage(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + azureStorageAccount: AzureStorageAccount | None = None + """ + (Attributes) Cannot be set alongside anonymous. (see below for nested schema) + """ + containerName: str | None = None + """ + (String) Name of the source Azure Blob Storage container. + Name of the source Azure Blob Storage container. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storageaccountname.blob.core.windows.net". + """ + + +class NebiusModel(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the source bucket is located. + """ + + +class S3CompatibleModel(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where source bucket is located. + """ + + +class Source(BaseModel): + azureBlobStorage: AzureBlobStorage | None = None + """ + (Attributes) Cannot be set alongside nebius or s3_compatible. (see below for nested schema) + """ + nebius: NebiusModel | None = None + """ + (Attributes) Cannot be set alongside s3_compatible. (see below for nested schema) + """ + prefix: str | None = None + """ + (String) : + : + + Prefix to filter objects in the source. Only objects whose keys start with this prefix will be transferred. + During transfer, the resulting object key in the destination is computed + by removing source.prefix from the original key and then prepending destination.prefix (if provided). + Important: This transformation may result in an empty object key or one that exceeds allowed length limits. + Use prefixes that guarantee valid resulting object keys for your objects after transformation. + """ + s3Compatible: S3CompatibleModel | None = None + """ + (Attributes) Cannot be set alongside nebius. (see below for nested schema) + """ + + +class ForProvider(BaseModel): + afterNEmptyIterations: AfterNEmptyIterations | None = None + """ + (Attributes) Cannot be set alongside after_one_iteration or infinite. (see below for nested schema) + """ + afterOneIteration: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside after_n_empty_iterations or infinite. (see below for nested schema) + """ + destination: Destination | None = None + """ + (Attributes) Destination to which the transfer writes data. (see below for nested schema) + """ + enableDeletesInDestination: bool | None = None + """ + (Boolean) : + : + + If enable_deletes_in_destination flag is set, service will delete objects that exist in destination, but don't exist in source. + If touch_unmanaged flag isn't set, we do not delete objects that haven't been created by Data Transfer service. + """ + infinite: dict[str, Any] | None = None + """ + (Attributes) : + """ + interIterationInterval: str | None = None + """ + (String) : + : + + The time to wait since the previous iteration before starting the next one. + Default is 15 minutes if not specified. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limiters: Limiters | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + overwriteStrategy: str | None = None + """ + (String) : + : + + Overwrite strategy set logic of overwrite already existed objects in destination bucket. + + #### Supported values + + Possible values: + + - `OVERWRITE_STRATEGY_UNSPECIFIED` + - `NEVER`: + Never overwrite objects that exist in the destination. + If object exists in destination bucket, skip it. + Safest option to prevent any data loss. + + - `IF_NEWER`: + Overwrite only if source object is newer than destination. + Comparison based on Last-Modified timestamp. + Recommended for incremental sync scenarios. + If touch_unmanaged flag isn't set, we do not overwrite objects that haven't been created by Data Transfer service. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + source: Source | None = None + """ + (Attributes) Source from which the transfer reads data. (see below for nested schema) + """ + touchUnmanaged: bool | None = None + """ + (Boolean) : + : + + If touch_unmanaged flag is set, service will be allowed to overwrite and delete from destination objects that were not + created by Data Transfer Service. If this flag is false, Data Transfer Service will never overwrite or delete objects + that haven't been created by Data Transfer service. + """ + + +class AccessKeyModel(BaseModel): + accessKeyIdSecretRef: AccessKeyIdSecretRef + """ + (String) Access key ID. + Access key ID. + """ + secretAccessKeySecretRef: SecretAccessKeySecretRef | None = None + """ + (String, Sensitive) Secret access key. + Secret access key. + """ + + +class NebiusModel1(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the destination bucket is located. + """ + + +class S3CompatibleModel1(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where destination bucket is located. + """ + + +class NebiusModel2(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the source bucket is located. + """ + + +class S3CompatibleModel2(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where source bucket is located. + """ + + +class InitProvider(BaseModel): + afterNEmptyIterations: AfterNEmptyIterations | None = None + """ + (Attributes) Cannot be set alongside after_one_iteration or infinite. (see below for nested schema) + """ + afterOneIteration: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside after_n_empty_iterations or infinite. (see below for nested schema) + """ + destination: Destination | None = None + """ + (Attributes) Destination to which the transfer writes data. (see below for nested schema) + """ + enableDeletesInDestination: bool | None = None + """ + (Boolean) : + : + + If enable_deletes_in_destination flag is set, service will delete objects that exist in destination, but don't exist in source. + If touch_unmanaged flag isn't set, we do not delete objects that haven't been created by Data Transfer service. + """ + infinite: dict[str, Any] | None = None + """ + (Attributes) : + """ + interIterationInterval: str | None = None + """ + (String) : + : + + The time to wait since the previous iteration before starting the next one. + Default is 15 minutes if not specified. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limiters: Limiters | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + overwriteStrategy: str | None = None + """ + (String) : + : + + Overwrite strategy set logic of overwrite already existed objects in destination bucket. + + #### Supported values + + Possible values: + + - `OVERWRITE_STRATEGY_UNSPECIFIED` + - `NEVER`: + Never overwrite objects that exist in the destination. + If object exists in destination bucket, skip it. + Safest option to prevent any data loss. + + - `IF_NEWER`: + Overwrite only if source object is newer than destination. + Comparison based on Last-Modified timestamp. + Recommended for incremental sync scenarios. + If touch_unmanaged flag isn't set, we do not overwrite objects that haven't been created by Data Transfer service. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + source: Source | None = None + """ + (Attributes) Source from which the transfer reads data. (see below for nested schema) + """ + touchUnmanaged: bool | None = None + """ + (Boolean) : + : + + If touch_unmanaged flag is set, service will be allowed to overwrite and delete from destination objects that were not + created by Data Transfer Service. If this flag is false, Data Transfer Service will never overwrite or delete objects + that haven't been created by Data Transfer service. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AccessKeyModel1(BaseModel): + accessKeyIdSecretRef: AccessKeyIdSecretRef | None = None + """ + (String) Access key ID. + Access key ID. + """ + secretAccessKeySecretRef: SecretAccessKeySecretRef | None = None + """ + (String, Sensitive) Secret access key. + Secret access key. + """ + + +class NebiusModel3(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the destination bucket is located. + """ + + +class S3CompatibleModel3(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where destination bucket is located. + """ + + +class AzureStorageAccountModel(BaseModel): + accountName: str | None = None + """ + (String) Storage account name. + Storage account name. + """ + + +class NebiusModel4(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the source bucket is located. + """ + + +class S3CompatibleModel4(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where source bucket is located. + """ + + +class Error(BaseModel): + code: str | None = None + """ + (String) Error code, usually taken from the endpoint response. + Error code, usually taken from the endpoint response. + """ + message: str | None = None + """ + (String) Error message, usually taken from the endpoint response. + Error message, usually taken from the endpoint response. + """ + origin: str | None = None + """ + (String) : + : + + Endpoint where the error occurred. + + #### Supported values + + Possible values: + + - `ORIGIN_UNSPECIFIED` + - `SOURCE` - Error originated from the source. + - `DESTINATION` - Error originated from the destination. + """ + + +class LastIteration(BaseModel): + averageThroughputBytes: float | None = None + """ + (Number) Average throughput in bytes per second during the iteration. + Average throughput in bytes per second during the iteration. + """ + endTime: str | None = None + """ + (String) : + : + + Iteration end time. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + error: Error | None = None + """ + (Attributes) Error information if the transfer has failed. (see below for nested schema) + """ + objectsDeletedCount: float | None = None + """ + (Number) Number of objects deleted from destination bucket during this iteration. + Number of objects deleted from destination bucket during this iteration. + """ + objectsTransferredCount: float | None = None + """ + (Number) Number of objects transferred during this iteration. + Number of objects transferred during this iteration. + """ + objectsTransferredSize: float | None = None + """ + (Number) Total size of objects transferred during this iteration. + Total size of objects transferred during this iteration. + """ + sequenceNumber: float | None = None + """ + (Number) Sequence number of the iteration in the transfer, starting from 1. + Sequence number of the iteration in the transfer, starting from 1. + """ + startTime: str | None = None + """ + (String) : + : + + Iteration start time. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + (String) : + : + + Current iteration state. + + #### Supported values + + Iteration state. + Possible values: + + - `STATE_UNSPECIFIED` + - `IN_PROGRESS` + - `COMPLETED` + - `INTERRUPTED` + - `FAILED` + """ + + +class Status(BaseModel): + error: Error | None = None + """ + (Attributes) Error information if the transfer has failed. (see below for nested schema) + """ + lastIteration: LastIteration | None = None + """ + (Attributes) : + """ + state: str | None = None + """ + (String) : + : + + Current transfer state. + + #### Supported values + + Transfer state. + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `STOPPING` + - `STOPPED` + - `FAILING` + - `FAILED` + - `DELETING` + """ + suspensionState: str | None = None + """ + (String) : + : + + If the transfer is suspended, transfer's suspension state becomes SUSPENDED. + + #### Supported values + + Transfer suspension state. + Possible values: + + - `SUSPENSION_STATE_UNSPECIFIED` + - `NOT_SUSPENDED` + - `SUSPENDED` + """ + + +class AtProvider(BaseModel): + afterNEmptyIterations: AfterNEmptyIterations | None = None + """ + (Attributes) Cannot be set alongside after_one_iteration or infinite. (see below for nested schema) + """ + afterOneIteration: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside after_n_empty_iterations or infinite. (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + destination: Destination | None = None + """ + (Attributes) Destination to which the transfer writes data. (see below for nested schema) + """ + enableDeletesInDestination: bool | None = None + """ + (Boolean) : + : + + If enable_deletes_in_destination flag is set, service will delete objects that exist in destination, but don't exist in source. + If touch_unmanaged flag isn't set, we do not delete objects that haven't been created by Data Transfer service. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + infinite: dict[str, Any] | None = None + """ + (Attributes) : + """ + interIterationInterval: str | None = None + """ + (String) : + : + + The time to wait since the previous iteration before starting the next one. + Default is 15 minutes if not specified. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limiters: Limiters | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + overwriteStrategy: str | None = None + """ + (String) : + : + + Overwrite strategy set logic of overwrite already existed objects in destination bucket. + + #### Supported values + + Possible values: + + - `OVERWRITE_STRATEGY_UNSPECIFIED` + - `NEVER`: + Never overwrite objects that exist in the destination. + If object exists in destination bucket, skip it. + Safest option to prevent any data loss. + + - `IF_NEWER`: + Overwrite only if source object is newer than destination. + Comparison based on Last-Modified timestamp. + Recommended for incremental sync scenarios. + If touch_unmanaged flag isn't set, we do not overwrite objects that haven't been created by Data Transfer service. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + source: Source | None = None + """ + (Attributes) Source from which the transfer reads data. (see below for nested schema) + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + touchUnmanaged: bool | None = None + """ + (Boolean) : + : + + If touch_unmanaged flag is set, service will be allowed to overwrite and delete from destination objects that were not + created by Data Transfer Service. If this flag is false, Data Transfer Service will never overwrite or delete objects + that haven't been created by Data Transfer service. + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Transfer(BaseModel): + apiVersion: Literal['storage.nebius.m.upbound.io/v1beta1'] | None = ( + 'storage.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Transfer'] | None = 'Transfer' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + TransferSpec defines the desired state of Transfer + """ + status: StatusModel | None = None + """ + TransferStatus defines the observed state of Transfer. + """ + + +class TransferList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Transfer] + """ + List of transfers. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/tunnel/__init__.py b/schemas/python/models/io/upbound/m/nebius/tunnel/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/tunnel/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/tunnel/v1beta1.py new file mode 100644 index 000000000..f669114fb --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/tunnel/v1beta1.py @@ -0,0 +1,279 @@ +# generated by datamodel-codegen: +# filename: workdir/tunnel_nebius_m_upbound_io_v1beta1_tunnel.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + Arbitrary description of the tunnel provided by the user. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + title: str | None = None + """ + Human-readable display name for the tunnel. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + Arbitrary description of the tunnel provided by the user. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + title: str | None = None + """ + Human-readable display name for the tunnel. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + state: str | None = None + """ + : + + Current lifecycle state of the tunnel. + + #### Supported values + + State represents the lifecycle state of the tunnel. + Possible values: + + - `UNSPECIFIED` - Default unspecified state. + - `CREATED` - The tunnel has been created and is active. + - `DELETED` - The tunnel has been deleted. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Arbitrary description of the tunnel provided by the user. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + title: str | None = None + """ + Human-readable display name for the tunnel. + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Tunnel(BaseModel): + apiVersion: Literal['tunnel.nebius.m.upbound.io/v1beta1'] | None = ( + 'tunnel.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Tunnel'] | None = 'Tunnel' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + TunnelSpec defines the desired state of Tunnel + """ + status: StatusModel | None = None + """ + TunnelStatus defines the observed state of Tunnel. + """ + + +class TunnelList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Tunnel] + """ + List of tunnels. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/allocation/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/allocation/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/allocation/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/allocation/v1beta1.py new file mode 100644 index 000000000..85bf3b3ae --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/allocation/v1beta1.py @@ -0,0 +1,670 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_allocation.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class PoolIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class PoolIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Ipv4Private(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g 10.1.2.1), a CIDR block (e.g., "10.1.2.0/24") or + a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + poolIdRef: PoolIdRef | None = None + """ + Reference to a Pool in vpc to populate poolId. + """ + poolIdSelector: PoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate poolId. + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated + with this subnet. + In order to assign an allocation to a resource (i.e. network interface) + both must be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class Ipv4Public(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g. 1.2.3.4), a CIDR block (e.g., "1.2.3.4/24") + or a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + poolIdRef: PoolIdRef | None = None + """ + Reference to a Pool in vpc to populate poolId. + """ + poolIdSelector: PoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate poolId. + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated with + this subnet. + Assigning an allocation to a resource (i.e. network interface) requires + both to be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class ForProvider(BaseModel): + ipv4Private: Ipv4Private | None = None + """ + (Attributes) : + """ + ipv4Public: Ipv4Public | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + ipv4Private: Ipv4Private | None = None + """ + (Attributes) : + """ + ipv4Public: Ipv4Public | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Ipv4PrivateModel(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g 10.1.2.1), a CIDR block (e.g., "10.1.2.0/24") or + a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated + with this subnet. + In order to assign an allocation to a resource (i.e. network interface) + both must be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + + +class Ipv4PublicModel(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g. 1.2.3.4), a CIDR block (e.g., "1.2.3.4/24") + or a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated with + this subnet. + Assigning an allocation to a resource (i.e. network interface) requires + both to be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + + +class LoadBalancer(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the Load Balancer. + """ + + +class NetworkInterface(BaseModel): + instanceId: str | None = None + """ + (String) ID of the Compute instance network interface belongs to. + ID of the Compute instance network interface belongs to. + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Network interface name + """ + type: str | None = None + """ + (String) : + : + + Type of allocation attachment on the network interface. + + #### Supported values + + Possible values: + + - `TYPE_UNSPECIFIED` + - `PRIMARY` - Allocation is attached as the interface private IPv4 address. + - `ALIAS` - Allocation is attached as an IP alias. + - `PUBLIC` - Allocation is attached as the interface public IPv4 address. + """ + + +class Assignment(BaseModel): + loadBalancer: LoadBalancer | None = None + """ + (Attributes) Cannot be set alongside network_interface. (see below for nested schema) + """ + networkInterface: NetworkInterface | None = None + """ + (Attributes) Cannot be set alongside load_balancer. (see below for nested schema) + """ + + +class Details(BaseModel): + allocatedCidr: str | None = None + """ + (String) The actual CIDR block that has been allocated. + The actual CIDR block that has been allocated. + """ + poolId: str | None = None + """ + (String) : + ID of the pool from which this allocation was made. + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet associated with this allocation. + Populated when created with explicit subnet_id, from a subnet-specific pool, + or when assigned to a resource. + """ + version: str | None = None + """ + (String) : + : + + The IP version of this allocation (IPv4 or IPv6). + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + + +class Status(BaseModel): + assignment: Assignment | None = None + """ + (Attributes) : + """ + details: Details | None = None + """ + (Attributes) : + """ + state: str | None = None + """ + (String) : + : + + This field represents the current state of the allocation. + + #### Supported values + + Enumeration of possible states of the Allocation. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `CREATING` - Allocation is being created. + - `ALLOCATED` - Allocation is ready for use. + - `ASSIGNED` - Allocation is used. + - `DELETING` - Allocation is being deleted. + """ + static: bool | None = None + """ + Lifecycle of allocation depends on resource that using it. + If false - Lifecycle of allocation depends on resource that using it. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ipv4Private: Ipv4PrivateModel | None = None + """ + (Attributes) : + """ + ipv4Public: Ipv4PublicModel | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) : + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Allocation(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Allocation'] | None = 'Allocation' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AllocationSpec defines the desired state of Allocation + """ + status: StatusModel | None = None + """ + AllocationStatus defines the observed state of Allocation. + """ + + +class AllocationList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Allocation] + """ + List of allocations. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/network/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/network/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/network/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/network/v1beta1.py new file mode 100644 index 000000000..feca4ec27 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/network/v1beta1.py @@ -0,0 +1,403 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_network.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Pool(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the pool. + """ + idRef: IdRef | None = None + """ + Reference to a Pool in vpc to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Pool in vpc to populate id. + """ + + +class Ipv4PrivatePools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) (see below for nested schema) + """ + + +class Ipv4PublicPools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) (see below for nested schema) + """ + + +class ForProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class PoolModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the pool. + """ + + +class Status(BaseModel): + defaultRouteTableId: str | None = None + """ + (String) ID of the network's default route table. + ID of the network's default route table. + """ + state: str | None = None + """ + (String) : + : + + Current state of the network. + + #### Supported values + + Enumeration of possible states of the network. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `CREATING` - Network is being created. + - `READY` - Network is ready for use. + - `DELETING` - Network is being deleted. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) Status of the network. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Network(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Network'] | None = 'Network' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NetworkSpec defines the desired state of Network + """ + status: StatusModel | None = None + """ + NetworkStatus defines the observed state of Network. + """ + + +class NetworkList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Network] + """ + List of networks. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/pool/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/pool/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/pool/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/pool/v1beta1.py new file mode 100644 index 000000000..0f3693dd1 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/pool/v1beta1.py @@ -0,0 +1,546 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_pool.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Cidr(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A CIDR block (e.g., "10.1.2.0/24") or a prefix length (e.g., "/24"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the parent pool. + """ + maxMaskLength: float | None = None + """ + (Number) : + : + + Maximum mask length for this pool child pools and allocations. + Default max_mask_length is 32 for IPv4. + """ + state: str | None = None + """ + (String) : + : + + Controls provisioning of IP addresses from the CIDR block to other pools + or allocations. Defaults to AVAILABLE. + + #### Supported values + + Controls provisioning of IP addresses from this pool to other pools + or allocations. Defaults to AVAILABLE. + Possible values: + + - `STATE_UNSPECIFIED` - Not used, mandated by the protocol. + - `AVAILABLE` - Default state. Provision of the IP addresses from this CIDR block is allowed. + - `DISABLED` - Provision of the IP addresses from this CIDR block is denied. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class SourcePoolIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SourcePoolIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + cidrs: list[Cidr] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sourcePoolId: str | None = None + """ + (String) : + : + + ID of the source pool. + CIDR blocks of a pool must be within the range defined by its source pool. + """ + sourcePoolIdRef: SourcePoolIdRef | None = None + """ + Reference to a Pool in vpc to populate sourcePoolId. + """ + sourcePoolIdSelector: SourcePoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate sourcePoolId. + """ + version: str | None = None + """ + (String) : + : + + IP version of the pool. + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + visibility: str | None = None + """ + (String) : + : + + Configures whether the pool is private or public. + Only public pools IP addresses are routable in the Internet. + + #### Supported values + + Possible values: + + - `IP_VISIBILITY_UNSPECIFIED` - Default, unspecified IP visibility. + - `PRIVATE` - Private address. + - `PUBLIC` - Public address. + """ + + +class InitProvider(BaseModel): + cidrs: list[Cidr] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sourcePoolId: str | None = None + """ + (String) : + : + + ID of the source pool. + CIDR blocks of a pool must be within the range defined by its source pool. + """ + sourcePoolIdRef: SourcePoolIdRef | None = None + """ + Reference to a Pool in vpc to populate sourcePoolId. + """ + sourcePoolIdSelector: SourcePoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate sourcePoolId. + """ + version: str | None = None + """ + (String) : + : + + IP version of the pool. + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + visibility: str | None = None + """ + (String) : + : + + Configures whether the pool is private or public. + Only public pools IP addresses are routable in the Internet. + + #### Supported values + + Possible values: + + - `IP_VISIBILITY_UNSPECIFIED` - Default, unspecified IP visibility. + - `PRIVATE` - Private address. + - `PUBLIC` - Public address. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Assignment(BaseModel): + networks: list[str] | None = None + """ + (List of String) IDs of Networks to which the Pool is assigned. + IDs of Networks to which the Pool is assigned. + """ + subnets: list[str] | None = None + """ + (List of String) IDs of Subnets to which the Pool is assigned. + IDs of Subnets to which the Pool is assigned. + """ + + +class Status(BaseModel): + assignment: Assignment | None = None + """ + (Attributes) Assignment details for this Pool (see below for nested schema) + """ + cidrs: list[str] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + CIDR blocks. + """ + scopeId: str | None = None + """ + (String) Scope is the unique identifier for single pool tree. + Scope is the unique identifier for single pool tree. + """ + state: str | None = None + """ + (String) : + : + + Current state of the Pool. + + #### Supported values + + Possible states of the Pool. + Possible values: + + - `STATE_UNSPECIFIED` - Default, unspecified state. + - `CREATING` - Pool is being created. + - `READY` - Pool is ready for use. + - `DELETING` - Pool is being deleted. + """ + + +class AtProvider(BaseModel): + cidrs: list[Cidr] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + sourcePoolId: str | None = None + """ + (String) : + : + + ID of the source pool. + CIDR blocks of a pool must be within the range defined by its source pool. + """ + status: Status | None = None + """ + (Attributes) Status information for the Pool. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + version: str | None = None + """ + (String) : + : + + IP version of the pool. + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + visibility: str | None = None + """ + (String) : + : + + Configures whether the pool is private or public. + Only public pools IP addresses are routable in the Internet. + + #### Supported values + + Possible values: + + - `IP_VISIBILITY_UNSPECIFIED` - Default, unspecified IP visibility. + - `PRIVATE` - Private address. + - `PUBLIC` - Public address. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Pool(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Pool'] | None = 'Pool' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + PoolSpec defines the desired state of Pool + """ + status: StatusModel | None = None + """ + PoolStatus defines the observed state of Pool. + """ + + +class PoolList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Pool] + """ + List of pools. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/route/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/route/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/route/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/route/v1beta1.py new file mode 100644 index 000000000..48707da18 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/route/v1beta1.py @@ -0,0 +1,458 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_route.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Destination(BaseModel): + cidr: str | None = None + """ + : + + Destination CIDR block in IPv4 format (e.g., "0.0.0.0/0" for default route, "192.168.100.0/24" for specific subnet). + The CIDR notation specifies the range of IP addresses that this route will match. + Must be unique within a route table. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Allocation(BaseModel): + id: str | None = None + """ + ID of the IP allocation to use as the next hop. + """ + idRef: IdRef | None = None + """ + Reference to a Allocation in vpc to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Allocation in vpc to populate id. + """ + + +class NextHop(BaseModel): + allocation: Allocation | None = None + defaultEgressGateway: bool | None = None + """ + : + + Use the default egress gateway for outbound traffic. + Note: For VMs with public addresses (Floating IPs/FIPs), the FIP-specific route + takes precedence over this default egress gateway route. + + *Cannot be set alongside allocation.* + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + description: str | None = None + """ + Optional description of the route. + """ + destination: Destination | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + nextHop: NextHop | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a RouteTable in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate parentId. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + Optional description of the route. + """ + destination: Destination | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + nextHop: NextHop | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a RouteTable in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate parentId. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AllocationModel(BaseModel): + id: str | None = None + """ + ID of the IP allocation to use as the next hop. + """ + + +class AllocationModel1(BaseModel): + cidr: str | None = None + """ + The CIDR of the allocation being used as the next hop. + """ + + +class NextHopModel(BaseModel): + allocation: AllocationModel1 | None = None + defaultEgressGateway: dict[str, Any] | None = None + + +class Status(BaseModel): + nextHop: NextHopModel | None = None + priority: float | None = None + """ + : + + Indicates priority of the route. + That is 0 or a positive number. + Lower value = higher priority; 0 is the highest priority. + """ + state: str | None = None + """ + : + + Current state of the route. + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` - The state is unknown or not yet set. + - `READY` - The route is configured and operational. + """ + type: str | None = None + """ + : + + Indicates the route type. + REDISTRIBUTED routes cannot be deleted directly. + + #### Supported values + + Route type. + Possible values: + + - `TYPE_UNSPECIFIED` + - `STATIC` + - `REDISTRIBUTED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Optional description of the route. + """ + destination: Destination | None = None + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + nextHop: NextHop | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Route(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Route'] | None = 'Route' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RouteSpec defines the desired state of Route + """ + status: StatusModel | None = None + """ + RouteStatus defines the observed state of Route. + """ + + +class RouteList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Route] + """ + List of routes. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/routetable/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/routetable/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/routetable/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/routetable/v1beta1.py new file mode 100644 index 000000000..cc77d02f5 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/routetable/v1beta1.py @@ -0,0 +1,349 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_routetable.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class NetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + networkId: str | None = None + """ + ID of the VPC network this route table belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + networkId: str | None = None + """ + ID of the VPC network this route table belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Assignment(BaseModel): + subnets: list[str] | None = None + """ + List of subnet IDs that use this route table for their routing configuration. + """ + + +class Status(BaseModel): + assignment: Assignment | None = None + default: bool | None = None + """ + : + + Indicates if this is the default route table for the network. + Only one route table can be default per network. + """ + state: str | None = None + """ + : + + Current state of the route table. + + #### Supported values + + State indicates the current operational state of the route table. + Possible values: + + - `STATE_UNSPECIFIED` - The state is unknown or not yet set. + - `READY` - The route table is configured and operational. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + networkId: str | None = None + """ + ID of the VPC network this route table belongs to. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class RouteTable(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['RouteTable'] | None = 'RouteTable' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RouteTableSpec defines the desired state of RouteTable + """ + status: StatusModel | None = None + """ + RouteTableStatus defines the observed state of RouteTable. + """ + + +class RouteTableList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[RouteTable] + """ + List of routetables. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/securitygroup/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/securitygroup/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/securitygroup/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/securitygroup/v1beta1.py new file mode 100644 index 000000000..5817fcbba --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/securitygroup/v1beta1.py @@ -0,0 +1,374 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_securitygroup.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class NetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the VPC network this security group belongs to. + ID of the VPC network this security group belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the VPC network this security group belongs to. + ID of the VPC network this security group belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + default: bool | None = None + """ + (Boolean) : + : + + Indicates if this is the default security group for the network. + Only one security group can be default per network. + Will be used on the interface if no other is specified. + """ + state: str | None = None + """ + (String) : + : + + Current state of the security group. + + #### Supported values + + Enumeration of possible states of the security group. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `READY` - Security group is ready for use. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the VPC network this security group belongs to. + ID of the VPC network this security group belongs to. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) Current status of the security group. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SecurityGroup(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SecurityGroup'] | None = 'SecurityGroup' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecurityGroupSpec defines the desired state of SecurityGroup + """ + status: StatusModel | None = None + """ + SecurityGroupStatus defines the observed state of SecurityGroup. + """ + + +class SecurityGroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SecurityGroup] + """ + List of securitygroups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/securityrule/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/securityrule/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/securityrule/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/securityrule/v1beta1.py new file mode 100644 index 000000000..c3b78d8f2 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/securityrule/v1beta1.py @@ -0,0 +1,839 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_securityrule.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class DestinationSecurityGroupIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class DestinationSecurityGroupIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Egress(BaseModel): + destinationCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the destination. + Optional. Empty list means any address. + Must be a valid IPv4. + Maximum of 8 CIDRs can be specified. + """ + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + destinationSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the destination. + ID of the referenced Security Group as the destination. + """ + destinationSecurityGroupIdRef: DestinationSecurityGroupIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate destinationSecurityGroupId. + """ + destinationSecurityGroupIdSelector: DestinationSecurityGroupIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate destinationSecurityGroupId. + """ + + +class SourceSecurityGroupIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SourceSecurityGroupIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Ingress(BaseModel): + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of destination ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + sourceCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the source. + Optional. Empty list means any address. + Must be a valid IPv4 + Maximum of 8 CIDRs can be specified. + """ + sourceSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the source. + ID of the referenced Security Group as the source. + """ + sourceSecurityGroupIdRef: SourceSecurityGroupIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate sourceSecurityGroupId. + """ + sourceSecurityGroupIdSelector: SourceSecurityGroupIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate sourceSecurityGroupId. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + access: str | None = None + """ + (String) : + : + + Access action for the rule. + Required. Determines whether matching traffic is allowed or denied. + + #### Supported values + + Access specifies action on matching traffic: ALLOW or DENY. + Possible values: + + - `ACCESS_UNSPECIFIED` + - `ALLOW` + - `DENY` + """ + egress: Egress | None = None + """ + (Attributes) : + """ + ingress: Ingress | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate parentId. + """ + priority: float | None = None + """ + (Number) : + : + + Priority of the rule. Valid range: 0-1000. + Optional. If not specified or set to 0, defaults to 500. + Rules are evaluated in priority order (lower numbers first) using a first-match algorithm: + only the first matching rule takes effect (ALLOW or DENY), and subsequent rules are skipped. + + When multiple rules share the same priority, DENY rules are evaluated before ALLOW rules. + The final evaluation order is reflected in 'effective_priority' (see SecurityRuleStatus). + """ + protocol: str | None = None + """ + (String) : + : + + Protocol used in the rule. + Supported values: ANY, TCP, UDP, ICMP. + + #### Supported values + + Protocol specifies traffic protocol. + Possible values: + + - `PROTOCOL_UNSPECIFIED` + - `ANY` + - `TCP` + - `UDP` + - `ICMP` + """ + type: str | None = None + """ + (String) : + : + + Type of the rule (STATEFUL or STATELESS) + Default value is STATEFUL + + #### Supported values + + RuleType specifies whether the security rule is stateful or stateless. + Possible values: + + - `RULE_TYPE_UNSPECIFIED` + - `STATEFUL` + - `STATELESS` + """ + + +class InitProvider(BaseModel): + access: str | None = None + """ + (String) : + : + + Access action for the rule. + Required. Determines whether matching traffic is allowed or denied. + + #### Supported values + + Access specifies action on matching traffic: ALLOW or DENY. + Possible values: + + - `ACCESS_UNSPECIFIED` + - `ALLOW` + - `DENY` + """ + egress: Egress | None = None + """ + (Attributes) : + """ + ingress: Ingress | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate parentId. + """ + priority: float | None = None + """ + (Number) : + : + + Priority of the rule. Valid range: 0-1000. + Optional. If not specified or set to 0, defaults to 500. + Rules are evaluated in priority order (lower numbers first) using a first-match algorithm: + only the first matching rule takes effect (ALLOW or DENY), and subsequent rules are skipped. + + When multiple rules share the same priority, DENY rules are evaluated before ALLOW rules. + The final evaluation order is reflected in 'effective_priority' (see SecurityRuleStatus). + """ + protocol: str | None = None + """ + (String) : + : + + Protocol used in the rule. + Supported values: ANY, TCP, UDP, ICMP. + + #### Supported values + + Protocol specifies traffic protocol. + Possible values: + + - `PROTOCOL_UNSPECIFIED` + - `ANY` + - `TCP` + - `UDP` + - `ICMP` + """ + type: str | None = None + """ + (String) : + : + + Type of the rule (STATEFUL or STATELESS) + Default value is STATEFUL + + #### Supported values + + RuleType specifies whether the security rule is stateful or stateless. + Possible values: + + - `RULE_TYPE_UNSPECIFIED` + - `STATEFUL` + - `STATELESS` + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class EgressModel(BaseModel): + destinationCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the destination. + Optional. Empty list means any address. + Must be a valid IPv4. + Maximum of 8 CIDRs can be specified. + """ + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + destinationSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the destination. + ID of the referenced Security Group as the destination. + """ + + +class IngressModel(BaseModel): + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of destination ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + sourceCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the source. + Optional. Empty list means any address. + Must be a valid IPv4 + Maximum of 8 CIDRs can be specified. + """ + sourceSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the source. + ID of the referenced Security Group as the source. + """ + + +class Destination(BaseModel): + cidrs: list[str] | None = None + """ + (List of String) List of CIDR blocks. + List of CIDR blocks. + """ + ports: list[float] | None = None + """ + (List of Number) List of ports. + List of ports. + """ + securityGroupId: str | None = None + """ + (String) ID of the Security Group. + ID of the Security Group. + """ + + +class Source(BaseModel): + cidrs: list[str] | None = None + """ + (List of String) List of CIDR blocks. + List of CIDR blocks. + """ + ports: list[float] | None = None + """ + (List of Number) List of ports. + List of ports. + """ + securityGroupId: str | None = None + """ + (String) ID of the Security Group. + ID of the Security Group. + """ + + +class Status(BaseModel): + destination: Destination | None = None + """ + (Attributes) Destination of the traffic that matched the rule. (see below for nested schema) + """ + direction: str | None = None + """ + (String) : + : + + Direction of traffic affected by the rule. + + #### Supported values + + Direction specifies whether traffic is INGRESS (incoming) or EGRESS (outgoing). + Possible values: + + - `DIRECTION_UNSPECIFIED` + - `INGRESS` + - `EGRESS` + """ + effectivePriority: float | None = None + """ + (Number) : + : + + Effective priority used for rule evaluation order, calculated by the system. + This value is computed from the user-specified 'priority' (SecurityRuleSpec). + Rules are evaluated in ascending order of effective_priority using a first-match algorithm. + """ + source: Source | None = None + """ + (Attributes) Source of the traffic that matched the rule. (see below for nested schema) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + State describes lifecycle phases of a security rule. + Possible values: + + - `STATE_UNSPECIFIED` + - `CREATING` + - `READY` + - `DELETING` + """ + + +class AtProvider(BaseModel): + access: str | None = None + """ + (String) : + : + + Access action for the rule. + Required. Determines whether matching traffic is allowed or denied. + + #### Supported values + + Access specifies action on matching traffic: ALLOW or DENY. + Possible values: + + - `ACCESS_UNSPECIFIED` + - `ALLOW` + - `DENY` + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + egress: EgressModel | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ingress: IngressModel | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + priority: float | None = None + """ + (Number) : + : + + Priority of the rule. Valid range: 0-1000. + Optional. If not specified or set to 0, defaults to 500. + Rules are evaluated in priority order (lower numbers first) using a first-match algorithm: + only the first matching rule takes effect (ALLOW or DENY), and subsequent rules are skipped. + + When multiple rules share the same priority, DENY rules are evaluated before ALLOW rules. + The final evaluation order is reflected in 'effective_priority' (see SecurityRuleStatus). + """ + protocol: str | None = None + """ + (String) : + : + + Protocol used in the rule. + Supported values: ANY, TCP, UDP, ICMP. + + #### Supported values + + Protocol specifies traffic protocol. + Possible values: + + - `PROTOCOL_UNSPECIFIED` + - `ANY` + - `TCP` + - `UDP` + - `ICMP` + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) Current status of the security rule. (see below for nested schema) + """ + type: str | None = None + """ + (String) : + : + + Type of the rule (STATEFUL or STATELESS) + Default value is STATEFUL + + #### Supported values + + RuleType specifies whether the security rule is stateful or stateless. + Possible values: + + - `RULE_TYPE_UNSPECIFIED` + - `STATEFUL` + - `STATELESS` + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SecurityRule(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SecurityRule'] | None = 'SecurityRule' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecurityRuleSpec defines the desired state of SecurityRule + """ + status: StatusModel | None = None + """ + SecurityRuleStatus defines the observed state of SecurityRule. + """ + + +class SecurityRuleList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SecurityRule] + """ + List of securityrules. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/subnet/__init__.py b/schemas/python/models/io/upbound/m/nebius/vpc/subnet/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/m/nebius/vpc/subnet/v1beta1.py b/schemas/python/models/io/upbound/m/nebius/vpc/subnet/v1beta1.py new file mode 100644 index 000000000..225a84875 --- /dev/null +++ b/schemas/python/models/io/upbound/m/nebius/vpc/subnet/v1beta1.py @@ -0,0 +1,608 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_m_upbound_io_v1beta1_subnet.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ......k8s.apimachinery.pkg.apis.meta import v1 + + +class Cidr(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A CIDR block (e.g., "10.1.2.0/24") or a prefix length (e.g., "/24"). + If prefix length is specified, the CIDR block will be auto-allocated + from the network's available space. + """ + maxMaskLength: float | None = None + """ + (Number) Maximum mask length for an allocation from this block. Defaults to /32 for IPv4. + Maximum mask length for an allocation from this block. Defaults to /32 for IPv4. + """ + state: str | None = None + """ + (String) : + : + + Controls provisioning of IP addresses from the CIDR block. Defaults to AVAILABLE. + + #### Supported values + + Controls provisioning of IP addresses from this pool to other pools + or allocations. Defaults to AVAILABLE. + Possible values: + + - `STATE_UNSPECIFIED` - Not used, mandated by the protocol. + - `AVAILABLE` - Default state. Provision of the IP addresses from this CIDR block is allowed. + - `DISABLED` - Provision of the IP addresses from this CIDR block is denied. + """ + + +class Pool(BaseModel): + cidrs: list[Cidr] | None = None + """ + instead. + """ + + +class Ipv4PrivatePools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) : + """ + useNetworkPools: bool | None = None + """ + is true. (see below for nested schema) + : + + If true, inherit private IPv4 pools from the network. Defaults to true. + Must be false if `pools` is specified. + """ + + +class Ipv4PublicPools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) : + """ + useNetworkPools: bool | None = None + """ + is true. (see below for nested schema) + : + + If true, inherit public IPv4 pools from the network. + Must be false if `pools` is specified. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class NetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class RouteTableIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + namespace: str | None = None + """ + Namespace of the referenced object + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class RouteTableIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + namespace: str | None = None + """ + Namespace for the selector + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the network this subnet belongs to. + ID of the network this subnet belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + routeTableId: str | None = None + """ + (String) : + : + + ID of the route table to associate with the subnet. + If unspecified, the network's default route table is used. + """ + routeTableIdRef: RouteTableIdRef | None = None + """ + Reference to a RouteTable in vpc to populate routeTableId. + """ + routeTableIdSelector: RouteTableIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate routeTableId. + """ + + +class InitProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the network this subnet belongs to. + ID of the network this subnet belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + routeTableId: str | None = None + """ + (String) : + : + + ID of the route table to associate with the subnet. + If unspecified, the network's default route table is used. + """ + routeTableIdRef: RouteTableIdRef | None = None + """ + Reference to a RouteTable in vpc to populate routeTableId. + """ + routeTableIdSelector: RouteTableIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate routeTableId. + """ + + +class ProviderConfigRef(BaseModel): + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + + +class Spec(BaseModel): + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'kind': 'ClusterProviderConfig', 'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Ipv4PrivatePool(BaseModel): + cidrs: list[str] | None = None + """ + instead. + CIDR blocks sourced from this pool. + """ + poolId: str | None = None + """ + (String) ID of the pool available for allocations in this subnet. + ID of the pool available for allocations in this subnet. + """ + + +class Ipv4PublicPool(BaseModel): + cidrs: list[str] | None = None + """ + instead. + CIDR blocks sourced from this pool. + """ + poolId: str | None = None + """ + (String) ID of the pool available for allocations in this subnet. + ID of the pool available for allocations in this subnet. + """ + + +class RouteTable(BaseModel): + default: bool | None = None + """ + (Boolean) : + : + + Indicates whether this is the network's default route table. + If true, this is the default route table inherited from the network. + If false, this is a custom route table explicitly associated with the subnet via spec. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the route table. + """ + + +class Status(BaseModel): + ipv4PrivateCidrs: list[str] | None = None + """ + (List of String, Deprecated) : + : + + CIDR blocks. + Deprecated: Use `ipv4_private_pools.cidrs` instead. + """ + ipv4PrivatePools: list[Ipv4PrivatePool] | None = None + """ + (Attributes) : + """ + ipv4PublicCidrs: list[str] | None = None + """ + (List of String, Deprecated) : + : + + CIDR blocks. + Deprecated: Use `ipv4_public_pools.cidrs` instead. + """ + ipv4PublicPools: list[Ipv4PublicPool] | None = None + """ + (Attributes) : + """ + routeTable: RouteTable | None = None + """ + (Attributes) : + """ + state: str | None = None + """ + (String) : + : + + Current state of the subnet. + + #### Supported values + + Enumeration of possible states of the subnet. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `CREATING` - Subnet is being created. + - `READY` - Subnet is ready for use. + - `DELETING` - Subnet is being deleted. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the network this subnet belongs to. + ID of the network this subnet belongs to. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + routeTableId: str | None = None + """ + (String) : + : + + ID of the route table to associate with the subnet. + If unspecified, the network's default route table is used. + """ + status: Status | None = None + """ + (Attributes) Status of the subnet. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Subnet(BaseModel): + apiVersion: Literal['vpc.nebius.m.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.m.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Subnet'] | None = 'Subnet' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SubnetSpec defines the desired state of Subnet + """ + status: StatusModel | None = None + """ + SubnetStatus defines the observed state of Subnet. + """ + + +class SubnetList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Subnet] + """ + List of subnets. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/__init__.py b/schemas/python/models/io/upbound/nebius/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/__init__.py b/schemas/python/models/io/upbound/nebius/compute/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/disk/__init__.py b/schemas/python/models/io/upbound/nebius/compute/disk/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/disk/v1beta1.py b/schemas/python/models/io/upbound/nebius/compute/disk/v1beta1.py new file mode 100644 index 000000000..f07eda25d --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/compute/disk/v1beta1.py @@ -0,0 +1,620 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_upbound_io_v1beta1_disk.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class DiskEncryption(BaseModel): + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `DISK_ENCRYPTION_UNSPECIFIED` - No encryption is applied unless explicitly specified. + - `DISK_ENCRYPTION_MANAGED`: + Enables encryption using the platform's default root key from KMS. + Available for disks with NETWORK_SSD_NON_REPLICATED and NETWORK_SSD_IO_M3 types only. + """ + + +class SourceImageFamily(BaseModel): + imageFamily: str | None = None + """ + (String) + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + """ + + +class ForProvider(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class InitProvider(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class LockState(BaseModel): + images: list[str] | None = None + """ + (List of String) : + : + + Disk is locked for deletion and for read-write operations while image is being created. + Here is the list of these images. + """ + + +class Status(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + """ + lockState: LockState | None = None + """ + write. (see below for nested schema) + """ + managedBy: str | None = None + """ + (String) : + : + + Indicates whether the disk is deleted along with an instance. + Set only for disks declared in the instance spec. + If set, the value is the instance ID that manages this disk's lifecycle (the disk is deleted when that instance is deleted). + To change this value, update the instance specification (see AttachedDiskSpec.type). + """ + readOnlyAttachments: list[str] | None = None + """ + (List of String) + """ + readWriteAttachment: str | None = None + """ + (String) : + : + + Current read-write owner (instance ID). + May refer to an instance in any state, including stopped + (this semantics is preserved for backward compatibility). + Reassigned on disk detach, instance deletion, or ownership transfer. + Ownership transfer occurs when this disk is explicitly attached to another instance + or when a VM with this disk attached starts while the current owner is stopped. + """ + reconciling: bool | None = None + """ + (Boolean) Indicates whether there is an ongoing operation + Indicates whether there is an ongoing operation + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + """ + sourceImageCpuArchitecture: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `SOURCE_IMAGE_CPU_UNSPECIFIED` + - `AMD64` + - `ARM64` + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `READY` + - `UPDATING` + - `DELETING` + - `ERROR` - Indicates that error happened during disk creation, and the disk cannot be recovered. + - `BROKEN` - Indicates that an error has occurred during the disk's life cycle, and the disk is broken or unhealthy, but can still be recovered. + """ + stateDescription: str | None = None + """ + (String) + """ + + +class AtProvider(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Disk(BaseModel): + apiVersion: Literal['compute.nebius.upbound.io/v1beta1'] | None = ( + 'compute.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Disk'] | None = 'Disk' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + DiskSpec defines the desired state of Disk + """ + status: StatusModel | None = None + """ + DiskStatus defines the observed state of Disk. + """ + + +class DiskList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Disk] + """ + List of disks. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/compute/filesystem/__init__.py b/schemas/python/models/io/upbound/nebius/compute/filesystem/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/filesystem/v1beta1.py b/schemas/python/models/io/upbound/nebius/compute/filesystem/v1beta1.py new file mode 100644 index 000000000..3e4bd6c8b --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/compute/filesystem/v1beta1.py @@ -0,0 +1,434 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_upbound_io_v1beta1_filesystem.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + blockSizeBytes: float | None = None + """ + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + forbidDeletion: bool | None = None + """ + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + type: str | None = None + """ + : + + The Shared Filesystem type determines its limits and performance characteristics. + For details, see https://docs.nebius.com/compute/storage/types#filesystems-types + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` - the list of available types will be clarified later, it is not final version + - `NETWORK_HDD` + - `WEKA` + - `VAST` + """ + + +class InitProvider(BaseModel): + blockSizeBytes: float | None = None + """ + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + forbidDeletion: bool | None = None + """ + Prevents deletion whilst set + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + sizeBytes: float | None = None + """ + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + type: str | None = None + """ + : + + The Shared Filesystem type determines its limits and performance characteristics. + For details, see https://docs.nebius.com/compute/storage/types#filesystems-types + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` - the list of available types will be clarified later, it is not final version + - `NETWORK_HDD` + - `WEKA` + - `VAST` + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + blockSizeBytes: float | None = None + readOnlyAttachments: list[str] | None = None + readWriteAttachments: list[str] | None = None + reconciling: bool | None = None + """ + Indicates whether there is an ongoing operation + """ + sizeBytes: float | None = None + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `READY` + - `UPDATING` + - `DELETING` + - `ERROR` + """ + stateDescription: str | None = None + + +class AtProvider(BaseModel): + blockSizeBytes: float | None = None + """ + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + forbidDeletion: bool | None = None + """ + Prevents deletion whilst set + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + sizeBytes: float | None = None + """ + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + status: Status | None = None + type: str | None = None + """ + : + + The Shared Filesystem type determines its limits and performance characteristics. + For details, see https://docs.nebius.com/compute/storage/types#filesystems-types + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` - the list of available types will be clarified later, it is not final version + - `NETWORK_HDD` + - `WEKA` + - `VAST` + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Filesystem(BaseModel): + apiVersion: Literal['compute.nebius.upbound.io/v1beta1'] | None = ( + 'compute.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Filesystem'] | None = 'Filesystem' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FilesystemSpec defines the desired state of Filesystem + """ + status: StatusModel | None = None + """ + FilesystemStatus defines the observed state of Filesystem. + """ + + +class FilesystemList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Filesystem] + """ + List of filesystems. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/compute/gpucluster/__init__.py b/schemas/python/models/io/upbound/nebius/compute/gpucluster/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/gpucluster/v1beta1.py b/schemas/python/models/io/upbound/nebius/compute/gpucluster/v1beta1.py new file mode 100644 index 000000000..de5a18434 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/compute/gpucluster/v1beta1.py @@ -0,0 +1,311 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_upbound_io_v1beta1_gpucluster.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + infinibandFabric: str | None = None + """ + : + + The identifier of the physical InfiniBand fabric to connect GPU instances to. + For details, see https://docs.nebius.com/compute/clusters/gpu#fabrics + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + infinibandFabric: str | None = None + """ + : + + The identifier of the physical InfiniBand fabric to connect GPU instances to. + For details, see https://docs.nebius.com/compute/clusters/gpu#fabrics + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Instance(BaseModel): + instanceId: str | None = None + path: list[str] | None = None + + +class InfinibandTopologyPath(BaseModel): + instances: list[Instance] | None = None + + +class Status(BaseModel): + infinibandTopologyPath: InfinibandTopologyPath | None = None + instances: list[str] | None = None + reconciling: bool | None = None + """ + Indicates whether there is an ongoing operation + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + infinibandFabric: str | None = None + """ + : + + The identifier of the physical InfiniBand fabric to connect GPU instances to. + For details, see https://docs.nebius.com/compute/clusters/gpu#fabrics + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class GpuCluster(BaseModel): + apiVersion: Literal['compute.nebius.upbound.io/v1beta1'] | None = ( + 'compute.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['GpuCluster'] | None = 'GpuCluster' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + GpuClusterSpec defines the desired state of GpuCluster + """ + status: StatusModel | None = None + """ + GpuClusterStatus defines the observed state of GpuCluster. + """ + + +class GpuClusterList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[GpuCluster] + """ + List of gpuclusters. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/compute/instance/__init__.py b/schemas/python/models/io/upbound/nebius/compute/instance/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/instance/v1beta1.py b/schemas/python/models/io/upbound/nebius/compute/instance/v1beta1.py new file mode 100644 index 000000000..a0f7bf26a --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/compute/instance/v1beta1.py @@ -0,0 +1,1403 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_upbound_io_v1beta1_instance.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ExistingDisk(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a Disk in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Disk in compute to populate id. + """ + + +class DiskEncryption(BaseModel): + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `DISK_ENCRYPTION_UNSPECIFIED` - No encryption is applied unless explicitly specified. + - `DISK_ENCRYPTION_MANAGED`: + Enables encryption using the platform's default root key from KMS. + Available for disks with NETWORK_SSD_NON_REPLICATED and NETWORK_SSD_IO_M3 types only. + """ + + +class SourceImageFamily(BaseModel): + imageFamily: str | None = None + """ + (String) + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + """ + + +class Spec(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class ManagedDisk(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with disk resource. + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Name of a dependent disk. + Use it to convert an ExistingDisk to a dependent disk. + Changing the name will replace the disk and cause data loss. + """ + spec: Spec | None = None + """ + (Attributes) Specification of a dependent disk to be created. (see below for nested schema) + """ + + +class BootDisk(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + deviceId: str | None = None + """ + defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + Specifies the user-defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + """ + existingDisk: ExistingDisk | None = None + """ + (Attributes) : + """ + managedDisk: ManagedDisk | None = None + """ + (Attributes) : + """ + + +class CloudInitUserDataSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class ExistingFilesystem(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a Filesystem in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Filesystem in compute to populate id. + """ + + +class Filesystem(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + existingFilesystem: ExistingFilesystem | None = None + """ + (Attributes) (see below for nested schema) + """ + mountTag: str | None = None + """ + defined identifier, allowing to use it as a device in mount command. + Specifies the user-defined identifier, allowing to use it as a device in mount command. + """ + + +class GpuCluster(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + If you want to interconnect several instances in a GPU cluster via NVIDIA InfiniBand, + set the ID of an existing GPU cluster. + You can only add the VM to the cluster when creating the VM. + For details, see https://docs.nebius.com/compute/clusters/gpu + """ + idRef: IdRef | None = None + """ + Reference to a GpuCluster in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a GpuCluster in compute to populate id. + """ + + +class PassthroughGroup(BaseModel): + requested: bool | None = None + """ + (Boolean) : + : + + Passthrough local disks from the underlying host. + + Devices are expected to appear in the guest as NVMe devices (nvme0, nvme1, ...), + but the exact number depends on the preset. + Enabled only when this field is explicitly set. + """ + + +class LocalDisks(BaseModel): + passthroughGroup: PassthroughGroup | None = None + """ + (Attributes) : + """ + + +class Alias(BaseModel): + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + ID of allocation + """ + + +class IpAddress(BaseModel): + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier if it was created before. + """ + + +class PublicIpAddress(BaseModel): + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier if it was created before. + """ + static: bool | None = None + """ + (Boolean) : + : + + If false - Allocation will be created/deleted during NetworkInterface.Allocate/NetworkInterface.Deallocate + If true - Allocation will be created/deleted during NetworkInterface.Create/NetworkInterface.Delete + False by default + """ + + +class SecurityGroup(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Security group identifier + """ + idRef: IdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate id. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class NetworkInterface(BaseModel): + aliases: list[Alias] | None = None + """ + (Attributes List) Assign ranges of IP addresses as aliases (see below for nested schema) + """ + ipAddress: IpAddress | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Interface name + Value of this field configures the name of the network interface inside VM's OS. + Longer values will persist in the specification but will be truncated to 15 symbols before being passed to VM configuration. + """ + publicIpAddress: PublicIpAddress | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroup] | None = None + """ + (Attributes List) : + """ + subnetId: str | None = None + """ + (String) Subnet ID + Subnet ID + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class Preemptible(BaseModel): + onPreemption: str | None = None + """ + (String) : + : + + Specifies what happens when the VM is preempted. The only supported value is STOP: + Compute stops the VM without deleting or restarting it. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `STOP` + """ + priority: float | None = None + """ + (Number, Deprecated) + """ + + +class ReservationPolicy(BaseModel): + policy: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `AUTO`: + 1) Will try to launch instance in any reservation_ids if provided. + 2) Will try to launch instance in any of the available capacity block. + 3) Will try to launch instance in PAYG if 1 & 2 are not satisfied. + + - `FORBID`: + The instance is launched only using on-demand (PAYG) capacity. + No attempt is made to find or use a Capacity Block. + It's an error to provide reservation_ids with policy = FORBID + + - `STRICT`: + 1) Will try to launch the instance in Capacity Blocks from reservation_ids if provided. + 2) If reservation_ids are not provided will try to launch instance in suitable & available Capacity Block. + 3) Fail otherwise. + """ + reservationIds: list[str] | None = None + """ + (List of String) Capacity block groups, order matters + Capacity block groups, order matters + """ + + +class Resources(BaseModel): + platform: str | None = None + """ + (String) + """ + preset: str | None = None + """ + (String) + """ + + +class SecondaryDisk(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + deviceId: str | None = None + """ + defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + Specifies the user-defined identifier, allowing to use '/dev/disk/by-id/virtio-{device_id}' as a device path in mount command. + """ + existingDisk: ExistingDisk | None = None + """ + (Attributes) : + """ + managedDisk: ManagedDisk | None = None + """ + (Attributes) : + """ + + +class ServiceAccountIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ServiceAccountIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Specified boot disk attached to the instance. (see below for nested schema) + """ + cloudInitUserDataSecretRef: CloudInitUserDataSecretRef | None = None + """ + (String, Sensitive) : + : + + Data in cloud-init format for customizing instance initialization. + For details, see https://docs.nebius.com/compute/virtual-machines/manage#user-data + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) List of Shared Filesystems attached to the instance. (see below for nested schema) + """ + gpuCluster: GpuCluster | None = None + """ + (Attributes) : + """ + hostname: str | None = None + """ + (String) : + : + + Instance's hostname. Used to generate default DNS record in format `..compute.internal.` + or `..compute.internal.` if hostname is not specified. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkInterfaces: list[NetworkInterface] | None = None + """ + (Attributes List) : + """ + nvlInstanceGroupId: str | None = None + """ + (String) NVLink Instance Group ID associated with the VM + NVLink Instance Group ID associated with the VM + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + preemptible: Preemptible | None = None + """ + (Attributes) : + """ + recoveryPolicy: str | None = None + """ + (String) : + : + + Recovery policy defines how the instance will be treated in case of a failure. + Common source of failure is a host failure, but it can be any other failure. + Instance undergoing a guest shutdown (poweroff, etc.) will be subject to recovery policy, meaning that it could + be restarted and billed accordingly. Stop instance via API or UI to stop it to avoid recovering. + - If set to RECOVER, instance will be restarted, if possible. It could be restarted on the same host or on another host. + - If set to FAIL, instance will be stopped and not restarted. + + #### Supported values + + Possible values: + + - `RECOVER` + - `FAIL` + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) (see below for nested schema) + """ + resources: Resources | None = None + """ + (Attributes) : + """ + secondaryDisks: list[SecondaryDisk] | None = None + """ + (Attributes List) List of additional data disks attached to the instance beyond the boot disk. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + Unique identifier of the service account associated with this instance. + For details, see https://docs.nebius.com/iam/service-accounts/manage + """ + serviceAccountIdRef: ServiceAccountIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate serviceAccountId. + """ + serviceAccountIdSelector: ServiceAccountIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate serviceAccountId. + """ + stopped: bool | None = None + """ + (Boolean) Indicates whether the instance should be stopped. + Indicates whether the instance should be stopped. + """ + + +class InitProvider(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Specified boot disk attached to the instance. (see below for nested schema) + """ + cloudInitUserDataSecretRef: CloudInitUserDataSecretRef | None = None + """ + (String, Sensitive) : + : + + Data in cloud-init format for customizing instance initialization. + For details, see https://docs.nebius.com/compute/virtual-machines/manage#user-data + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) List of Shared Filesystems attached to the instance. (see below for nested schema) + """ + gpuCluster: GpuCluster | None = None + """ + (Attributes) : + """ + hostname: str | None = None + """ + (String) : + : + + Instance's hostname. Used to generate default DNS record in format `..compute.internal.` + or `..compute.internal.` if hostname is not specified. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkInterfaces: list[NetworkInterface] | None = None + """ + (Attributes List) : + """ + nvlInstanceGroupId: str | None = None + """ + (String) NVLink Instance Group ID associated with the VM + NVLink Instance Group ID associated with the VM + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + preemptible: Preemptible | None = None + """ + (Attributes) : + """ + recoveryPolicy: str | None = None + """ + (String) : + : + + Recovery policy defines how the instance will be treated in case of a failure. + Common source of failure is a host failure, but it can be any other failure. + Instance undergoing a guest shutdown (poweroff, etc.) will be subject to recovery policy, meaning that it could + be restarted and billed accordingly. Stop instance via API or UI to stop it to avoid recovering. + - If set to RECOVER, instance will be restarted, if possible. It could be restarted on the same host or on another host. + - If set to FAIL, instance will be stopped and not restarted. + + #### Supported values + + Possible values: + + - `RECOVER` + - `FAIL` + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) (see below for nested schema) + """ + resources: Resources | None = None + """ + (Attributes) : + """ + secondaryDisks: list[SecondaryDisk] | None = None + """ + (Attributes List) List of additional data disks attached to the instance beyond the boot disk. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + Unique identifier of the service account associated with this instance. + For details, see https://docs.nebius.com/iam/service-accounts/manage + """ + serviceAccountIdRef: ServiceAccountIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate serviceAccountId. + """ + serviceAccountIdSelector: ServiceAccountIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate serviceAccountId. + """ + stopped: bool | None = None + """ + (Boolean) Indicates whether the instance should be stopped. + Indicates whether the instance should be stopped. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class SpecModel(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ExistingDiskModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class SpecModel1(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) : + : + + Block size in bytes. + The block size must be a power of two between 4096 bytes (4 KiB) and 131072 bytes (128 KiB). + The default value is 4096 bytes (4 KiB). + """ + diskEncryption: DiskEncryption | None = None + """ + (Attributes) Defines how data on the disk is encrypted. By default, no encryption is applied. (see below for nested schema) + """ + forbidDeletion: bool | None = None + """ + (Boolean) Prevents deletion whilst set + Prevents deletion whilst set + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + sourceImageFamily: SourceImageFamily | None = None + """ + (Attributes) Cannot be set alongside source_image_id. (see below for nested schema) + """ + sourceImageId: str | None = None + """ + (String) Cannot be set alongside source_image_family. + *Cannot be set alongside source_image_family.* + """ + type: str | None = None + """ + (String) : + : + + The type of disk defines the performance and reliability characteristics of the block device. + For details, see https://docs.nebius.com/compute/storage/types#disks-types + + #### Supported values + + the list of available types will be clarified later, it is not final version + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_NON_REPLICATED` + - `NETWORK_SSD_IO_M3` + """ + + +class ExistingFilesystemModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class GpuClusterModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + If you want to interconnect several instances in a GPU cluster via NVIDIA InfiniBand, + set the ID of an existing GPU cluster. + You can only add the VM to the cluster when creating the VM. + For details, see https://docs.nebius.com/compute/clusters/gpu + """ + + +class SecurityGroupModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Security group identifier + """ + + +class NetworkInterfaceModel(BaseModel): + aliases: list[Alias] | None = None + """ + (Attributes List) Assign ranges of IP addresses as aliases (see below for nested schema) + """ + ipAddress: IpAddress | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Interface name + Value of this field configures the name of the network interface inside VM's OS. + Longer values will persist in the specification but will be truncated to 15 symbols before being passed to VM configuration. + """ + publicIpAddress: PublicIpAddress | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroupModel] | None = None + """ + (Attributes List) : + """ + subnetId: str | None = None + """ + (String) Subnet ID + Subnet ID + """ + + +class DiskAttachment(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Disk ID. + - For ExistingDisk, this is the referenced disk ID. + - For ManagedDisk, may be empty while the attachment intent is still pending. + """ + isManaged: bool | None = None + """ + (Boolean) : + : + + Indicates whether this attachment is managed by the instance lifecycle. + If true, the disk is expected to be deleted when the instance is deleted. + If false, the disk is preserved and only detached on instance deletion. + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Disk name used to match this status entry with the desired attachment + from the instance specification. + + Consistency: + - For ManagedDisk, this value is derived from the instance spec (ManagedDisk.name). + - For ExistingDisk, this value is derived from the disk resource name and may lag behind + in case of renaming. It is updated asynchronously and is eventually consistent. + """ + + +class InfinibandTopologyPath(BaseModel): + path: list[str] | None = None + """ + (List of String) + """ + + +class Aliases(BaseModel): + cidrs: list[str] | None = None + """ + (List of String) + """ + + +class IpAddressModel(BaseModel): + address: str | None = None + """ + (String) Effective private IPv4 address assigned to the interface. + Effective private IPv4 address assigned to the interface. + """ + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier. + """ + + +class PublicIpAddressModel(BaseModel): + address: str | None = None + """ + (String) Effective private IPv4 address assigned to the interface. + Effective public IPv4 address assigned to the interface. + """ + allocationId: str | None = None + """ + (String) Allocation identifier if it was created before. + Allocation identifier. + """ + static: bool | None = None + """ + (Boolean) : + : + + If false - Allocation will be created/deleted during NetworkInterface.Allocate/NetworkInterface.Deallocate + If true - Allocation will be created/deleted during NetworkInterface.Create/NetworkInterface.Delete + False by default + """ + + +class NetworkInterfaceModel1(BaseModel): + aliases: Aliases | None = None + """ + (Attributes List) Assign ranges of IP addresses as aliases (see below for nested schema) + """ + fqdn: str | None = None + """ + (String) FQDN of the interface + FQDN of the interface + """ + index: float | None = None + """ + (Number) The index of the network interface + The index of the network interface + """ + ipAddress: IpAddressModel | None = None + """ + (Attributes) : + """ + macAddress: str | None = None + """ + (String) MAC address + MAC address + """ + name: str | None = None + """ + (String) Human readable name for the resource. + : + + Name for interface. + Unique within instance's network interfaces + """ + publicIpAddress: PublicIpAddressModel | None = None + """ + (Attributes) : + """ + + +class Status(BaseModel): + diskAttachments: list[DiskAttachment] | None = None + """ + . + """ + infinibandTopologyPath: InfinibandTopologyPath | None = None + """ + (Attributes) (see below for nested schema) + """ + maintenanceEventId: str | None = None + """ + (String) + """ + networkInterfaces: list[NetworkInterfaceModel1] | None = None + """ + (Attributes List) : + """ + reconciling: bool | None = None + """ + (Boolean) Indicates whether there is an ongoing operation + Indicates whether there is an ongoing operation + """ + reservationId: str | None = None + """ + (String) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `UPDATING` + - `STARTING` + - `RUNNING` + - `STOPPING` + - `STOPPED` + - `DELETING` + - `ERROR` + """ + + +class AtProvider(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Specified boot disk attached to the instance. (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) List of Shared Filesystems attached to the instance. (see below for nested schema) + """ + gpuCluster: GpuClusterModel | None = None + """ + (Attributes) : + """ + hostname: str | None = None + """ + (String) : + : + + Instance's hostname. Used to generate default DNS record in format `..compute.internal.` + or `..compute.internal.` if hostname is not specified. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkInterfaces: list[NetworkInterfaceModel] | None = None + """ + (Attributes List) : + """ + nvlInstanceGroupId: str | None = None + """ + (String) NVLink Instance Group ID associated with the VM + NVLink Instance Group ID associated with the VM + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + preemptible: Preemptible | None = None + """ + (Attributes) : + """ + recoveryPolicy: str | None = None + """ + (String) : + : + + Recovery policy defines how the instance will be treated in case of a failure. + Common source of failure is a host failure, but it can be any other failure. + Instance undergoing a guest shutdown (poweroff, etc.) will be subject to recovery policy, meaning that it could + be restarted and billed accordingly. Stop instance via API or UI to stop it to avoid recovering. + - If set to RECOVER, instance will be restarted, if possible. It could be restarted on the same host or on another host. + - If set to FAIL, instance will be stopped and not restarted. + + #### Supported values + + Possible values: + + - `RECOVER` + - `FAIL` + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) (see below for nested schema) + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + resources: Resources | None = None + """ + (Attributes) : + """ + secondaryDisks: list[SecondaryDisk] | None = None + """ + (Attributes List) List of additional data disks attached to the instance beyond the boot disk. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + Unique identifier of the service account associated with this instance. + For details, see https://docs.nebius.com/iam/service-accounts/manage + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + stopped: bool | None = None + """ + (Boolean) Indicates whether the instance should be stopped. + Indicates whether the instance should be stopped. + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Instance(BaseModel): + apiVersion: Literal['compute.nebius.upbound.io/v1beta1'] | None = ( + 'compute.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Instance'] | None = 'Instance' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: SpecModel + """ + InstanceSpec defines the desired state of Instance + """ + status: StatusModel | None = None + """ + InstanceStatus defines the observed state of Instance. + """ + + +class InstanceList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Instance] + """ + List of instances. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/compute/nvlinstancegroup/__init__.py b/schemas/python/models/io/upbound/nebius/compute/nvlinstancegroup/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/compute/nvlinstancegroup/v1beta1.py b/schemas/python/models/io/upbound/nebius/compute/nvlinstancegroup/v1beta1.py new file mode 100644 index 000000000..2ac55910f --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/compute/nvlinstancegroup/v1beta1.py @@ -0,0 +1,360 @@ +# generated by datamodel-codegen: +# filename: workdir/compute_nebius_upbound_io_v1beta1_nvlinstancegroup.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + size: float | None = None + """ + Maximum number of instances in the NVLink InstanceGroup + """ + type: str | None = None + """ + : + + Type of the NVLink InstanceGroup (corresponds to the Compute platform) + + #### Supported values + + Type of the NVLink InstanceGroup. + Possible values: + + - `UNSPECIFIED` + - `GB200` + - `GB300` + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + size: float | None = None + """ + Maximum number of instances in the NVLink InstanceGroup + """ + type: str | None = None + """ + : + + Type of the NVLink InstanceGroup (corresponds to the Compute platform) + + #### Supported values + + Type of the NVLink InstanceGroup. + Possible values: + + - `UNSPECIFIED` + - `GB200` + - `GB300` + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Instances(BaseModel): + instanceState: str | None = None + """ + : + + Current state of the instance. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` + - `UPDATING` + - `STARTING` + - `RUNNING` + - `STOPPING` + - `STOPPED` + - `DELETING` + - `ERROR` + """ + + +class Status(BaseModel): + instances: dict[str, Instances] | None = None + reconciling: bool | None = None + """ + Indicates whether there is an ongoing operation with any VM in the InstanceGroup + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + size: float | None = None + """ + Maximum number of instances in the NVLink InstanceGroup + """ + status: Status | None = None + type: str | None = None + """ + : + + Type of the NVLink InstanceGroup (corresponds to the Compute platform) + + #### Supported values + + Type of the NVLink InstanceGroup. + Possible values: + + - `UNSPECIFIED` + - `GB200` + - `GB300` + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class NvlInstanceGroup(BaseModel): + apiVersion: Literal['compute.nebius.upbound.io/v1beta1'] | None = ( + 'compute.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['NvlInstanceGroup'] | None = 'NvlInstanceGroup' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NvlInstanceGroupSpec defines the desired state of NvlInstanceGroup + """ + status: StatusModel | None = None + """ + NvlInstanceGroupStatus defines the observed state of NvlInstanceGroup. + """ + + +class NvlInstanceGroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[NvlInstanceGroup] + """ + List of nvlinstancegroups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/dns/__init__.py b/schemas/python/models/io/upbound/nebius/dns/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/dns/record/__init__.py b/schemas/python/models/io/upbound/nebius/dns/record/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/dns/record/v1beta1.py b/schemas/python/models/io/upbound/nebius/dns/record/v1beta1.py new file mode 100644 index 000000000..7ea330fb6 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/dns/record/v1beta1.py @@ -0,0 +1,498 @@ +# generated by datamodel-codegen: +# filename: workdir/dns_nebius_upbound_io_v1beta1_record.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + data: str | None = None + """ + : + + # Record data in text format + + This should be the RDATA part of this Resource Record's + [presentation (zonefile) format](https://datatracker.ietf.org/doc/html/rfc9499#name-resource-records). + E.g., `10 xyz.tuv` for a `@ 600 IN MX 10 xyz.tuv.` resource record in a zonefile + """ + deletionProtection: bool | None = None + """ + : + + Mark this record as delete-protected + Delete-protected records can *only* be deleted by explicitly calling `RecordService/Delete` API with `force` flag set to `true` + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Zone in dns to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Zone in dns to populate parentId. + """ + relativeName: str | None = None + """ + : + + Zone-relative name of this record (e.g., `www` for `www.`) + Use `@` for records in zone apex (that is, records that have the same domain name as the zone itself) + To see the resolved absolute domain name, see `Record.status.effective_fqdn` + """ + ttl: float | None = None + """ + Record TTL. If absent or negative, will be assumed to be the default value (`600`) + """ + type: str | None = None + """ + : + + # Record type + + #### Supported values + + DNS Record type + Possible values: + + - `RECORD_TYPE_UNSPECIFIED` - Record type is not specified + - `A` - `A` record: IPv4 address + - `AAAA` - `AAAA` record: IPv6 address + - `PTR` - `PTR` record: mapping from IP address to a domain name + - `CNAME` - `CNAME` record: an alias for a *canonical domain name* + - `MX` - `MX` record: mail server information (domain name, priority) + - `TXT` - `TXT` record: text data, typically used to verify e-mail addresses, websites and TLS certificates + - `SRV` - `SRV` record: information about a network service (domain name, port, weight) + - `NS` - `NS` record: domain name of an authoritative nameserver for this DNS zone, or one of its subzones + - `SOA` - `SOA` record: administrative information about this DNS zone + - `CAA` - `CAA` record: certificate issuance settings for this DNS zone and its subzones + - `SVCB` - `SVCB` record: service binding. See [RFC 9460, section 2.3](https://www.rfc-editor.org/rfc/rfc9460.html#section-2.3) + - `HTTPS`: + `HTTPS` record: service binding with HTTPS protocol configuration. + See [RFC 9460, section 9.1](https://www.rfc-editor.org/rfc/rfc9460.html#section-9.1) + """ + + +class InitProvider(BaseModel): + data: str | None = None + """ + : + + # Record data in text format + + This should be the RDATA part of this Resource Record's + [presentation (zonefile) format](https://datatracker.ietf.org/doc/html/rfc9499#name-resource-records). + E.g., `10 xyz.tuv` for a `@ 600 IN MX 10 xyz.tuv.` resource record in a zonefile + """ + deletionProtection: bool | None = None + """ + : + + Mark this record as delete-protected + Delete-protected records can *only* be deleted by explicitly calling `RecordService/Delete` API with `force` flag set to `true` + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Zone in dns to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Zone in dns to populate parentId. + """ + relativeName: str | None = None + """ + : + + Zone-relative name of this record (e.g., `www` for `www.`) + Use `@` for records in zone apex (that is, records that have the same domain name as the zone itself) + To see the resolved absolute domain name, see `Record.status.effective_fqdn` + """ + ttl: float | None = None + """ + Record TTL. If absent or negative, will be assumed to be the default value (`600`) + """ + type: str | None = None + """ + : + + # Record type + + #### Supported values + + DNS Record type + Possible values: + + - `RECORD_TYPE_UNSPECIFIED` - Record type is not specified + - `A` - `A` record: IPv4 address + - `AAAA` - `AAAA` record: IPv6 address + - `PTR` - `PTR` record: mapping from IP address to a domain name + - `CNAME` - `CNAME` record: an alias for a *canonical domain name* + - `MX` - `MX` record: mail server information (domain name, priority) + - `TXT` - `TXT` record: text data, typically used to verify e-mail addresses, websites and TLS certificates + - `SRV` - `SRV` record: information about a network service (domain name, port, weight) + - `NS` - `NS` record: domain name of an authoritative nameserver for this DNS zone, or one of its subzones + - `SOA` - `SOA` record: administrative information about this DNS zone + - `CAA` - `CAA` record: certificate issuance settings for this DNS zone and its subzones + - `SVCB` - `SVCB` record: service binding. See [RFC 9460, section 2.3](https://www.rfc-editor.org/rfc/rfc9460.html#section-2.3) + - `HTTPS`: + `HTTPS` record: service binding with HTTPS protocol configuration. + See [RFC 9460, section 9.1](https://www.rfc-editor.org/rfc/rfc9460.html#section-9.1) + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + effectiveFqdn: str | None = None + """ + Fully-qualified domain name of this record including `.` at the end, e.g. `www.example.com.` + """ + reconciling: bool | None = None + """ + Indicates whether there is a running Operation for this Record + """ + zoneDomainName: str | None = None + """ + Domain name of this record's parent zone including `.` at the end, e.g. `example.com.` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + data: str | None = None + """ + : + + # Record data in text format + + This should be the RDATA part of this Resource Record's + [presentation (zonefile) format](https://datatracker.ietf.org/doc/html/rfc9499#name-resource-records). + E.g., `10 xyz.tuv` for a `@ 600 IN MX 10 xyz.tuv.` resource record in a zonefile + """ + deletionProtection: bool | None = None + """ + : + + Mark this record as delete-protected + Delete-protected records can *only* be deleted by explicitly calling `RecordService/Delete` API with `force` flag set to `true` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + relativeName: str | None = None + """ + : + + Zone-relative name of this record (e.g., `www` for `www.`) + Use `@` for records in zone apex (that is, records that have the same domain name as the zone itself) + To see the resolved absolute domain name, see `Record.status.effective_fqdn` + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + ttl: float | None = None + """ + Record TTL. If absent or negative, will be assumed to be the default value (`600`) + """ + type: str | None = None + """ + : + + # Record type + + #### Supported values + + DNS Record type + Possible values: + + - `RECORD_TYPE_UNSPECIFIED` - Record type is not specified + - `A` - `A` record: IPv4 address + - `AAAA` - `AAAA` record: IPv6 address + - `PTR` - `PTR` record: mapping from IP address to a domain name + - `CNAME` - `CNAME` record: an alias for a *canonical domain name* + - `MX` - `MX` record: mail server information (domain name, priority) + - `TXT` - `TXT` record: text data, typically used to verify e-mail addresses, websites and TLS certificates + - `SRV` - `SRV` record: information about a network service (domain name, port, weight) + - `NS` - `NS` record: domain name of an authoritative nameserver for this DNS zone, or one of its subzones + - `SOA` - `SOA` record: administrative information about this DNS zone + - `CAA` - `CAA` record: certificate issuance settings for this DNS zone and its subzones + - `SVCB` - `SVCB` record: service binding. See [RFC 9460, section 2.3](https://www.rfc-editor.org/rfc/rfc9460.html#section-2.3) + - `HTTPS`: + `HTTPS` record: service binding with HTTPS protocol configuration. + See [RFC 9460, section 9.1](https://www.rfc-editor.org/rfc/rfc9460.html#section-9.1) + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Record(BaseModel): + apiVersion: Literal['dns.nebius.upbound.io/v1beta1'] | None = ( + 'dns.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Record'] | None = 'Record' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RecordSpec defines the desired state of Record + """ + status: StatusModel | None = None + """ + RecordStatus defines the observed state of Record. + """ + + +class RecordList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Record] + """ + List of records. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/dns/zone/__init__.py b/schemas/python/models/io/upbound/nebius/dns/zone/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/dns/zone/v1beta1.py b/schemas/python/models/io/upbound/nebius/dns/zone/v1beta1.py new file mode 100644 index 000000000..a36a7c14b --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/dns/zone/v1beta1.py @@ -0,0 +1,376 @@ +# generated by datamodel-codegen: +# filename: workdir/dns_nebius_upbound_io_v1beta1_zone.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class SoaSpec(BaseModel): + negativeTtl: float | None = None + """ + : + + Specifies TTL, in seconds, for caching `NXDOMAIN` ("record not found") DNS responses from this zone (*negative caching*) + Set this TTL to a low value if you frequently delete and recreate records instead of updating them + *Note:* Values of less than `5` will be ignored, and a default negative caching TTL will be used instead + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class PrimaryNetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class PrimaryNetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Vpc(BaseModel): + primaryNetworkId: str | None = None + """ + : + + ID of the virtual network that this zone's records will be visible from + This value cannot be changed after creating the zone + """ + primaryNetworkIdRef: PrimaryNetworkIdRef | None = None + """ + Reference to a Network in vpc to populate primaryNetworkId. + """ + primaryNetworkIdSelector: PrimaryNetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate primaryNetworkId. + """ + + +class ForProvider(BaseModel): + domainName: str | None = None + """ + : + + Fully qualified domain name of this zone, including `.` at the end + Cannot be changed after creating the zone + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + soaSpec: SoaSpec | None = None + vpc: Vpc | None = None + + +class InitProvider(BaseModel): + domainName: str | None = None + """ + : + + Fully qualified domain name of this zone, including `.` at the end + Cannot be changed after creating the zone + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + soaSpec: SoaSpec | None = None + vpc: Vpc | None = None + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + reconciling: bool | None = None + """ + Indicates whether there is a running Operation for this Zone + """ + recordCount: float | None = None + """ + Number of records in this zone. May be 0 if not calculated (e.g., in listings) + """ + + +class VpcModel(BaseModel): + primaryNetworkId: str | None = None + """ + : + + ID of the virtual network that this zone's records will be visible from + This value cannot be changed after creating the zone + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + domainName: str | None = None + """ + : + + Fully qualified domain name of this zone, including `.` at the end + Cannot be changed after creating the zone + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + soaSpec: SoaSpec | None = None + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + vpc: VpcModel | None = None + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Zone(BaseModel): + apiVersion: Literal['dns.nebius.upbound.io/v1beta1'] | None = ( + 'dns.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Zone'] | None = 'Zone' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ZoneSpec defines the desired state of Zone + """ + status: StatusModel | None = None + """ + ZoneStatus defines the observed state of Zone. + """ + + +class ZoneList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Zone] + """ + List of zones. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/__init__.py b/schemas/python/models/io/upbound/nebius/iam/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/accesskey/__init__.py b/schemas/python/models/io/upbound/nebius/iam/accesskey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/accesskey/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/accesskey/v1beta1.py new file mode 100644 index 000000000..6bbe2fe6b --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/accesskey/v1beta1.py @@ -0,0 +1,490 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_accesskey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ServiceAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a ServiceAccount in iam to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate id. + """ + + +class UserAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Account(BaseModel): + anonymousAccount: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside user_account or service_account. (see below for nested schema) + """ + serviceAccount: ServiceAccount | None = None + """ + (Attributes) Cannot be set alongside user_account or anonymous_account. (see below for nested schema) + """ + userAccount: UserAccount | None = None + """ + (Attributes) Cannot be set alongside service_account or anonymous_account. (see below for nested schema) + """ + + +class ForProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + secretDeliveryMode: str | None = None + """ + (String) : + : + + Specifies how the secret will be delivered upon creation. This field is immutable — it cannot be changed after the resource is + created. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - If not specified, the default behaviour will be applied. Currently it's INLINE, later will be EXPLICIT + """ + + +class InitProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + secretDeliveryMode: str | None = None + """ + (String) : + : + + Specifies how the secret will be delivered upon creation. This field is immutable — it cannot be changed after the resource is + created. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - If not specified, the default behaviour will be applied. Currently it's INLINE, later will be EXPLICIT + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ServiceAccountModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Status(BaseModel): + algorithm: str | None = None + """ + (String) + """ + awsAccessKeyId: str | None = None + """ + (String) + """ + fingerprint: str | None = None + """ + (String) + """ + keySize: float | None = None + """ + (Number) + """ + secretReferenceId: str | None = None + """ + (String) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `INACTIVE` + - `EXPIRED` + - `DELETING` + - `DELETED` + """ + + +class AtProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + secretDeliveryMode: str | None = None + """ + (String) : + : + + Specifies how the secret will be delivered upon creation. This field is immutable — it cannot be changed after the resource is + created. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - If not specified, the default behaviour will be applied. Currently it's INLINE, later will be EXPLICIT + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AccessKey(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AccessKey'] | None = 'AccessKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AccessKeySpec defines the desired state of AccessKey + """ + status: StatusModel | None = None + """ + AccessKeyStatus defines the observed state of AccessKey. + """ + + +class AccessKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AccessKey] + """ + List of accesskeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/accesspermit/__init__.py b/schemas/python/models/io/upbound/nebius/iam/accesspermit/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/accesspermit/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/accesspermit/v1beta1.py new file mode 100644 index 000000000..a3cdbe617 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/accesspermit/v1beta1.py @@ -0,0 +1,339 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_accesspermit.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + resourceId: str | None = None + """ + Resource for granting access permit. + """ + role: str | None = None + """ + Role for granting access permit. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + resourceId: str | None = None + """ + Resource for granting access permit. + """ + role: str | None = None + """ + Role for granting access permit. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceId: str | None = None + """ + Resource for granting access permit. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + role: str | None = None + """ + Role for granting access permit. + """ + status: dict[str, Any] | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AccessPermit(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AccessPermit'] | None = 'AccessPermit' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AccessPermitSpec defines the desired state of AccessPermit + """ + status: Status | None = None + """ + AccessPermitStatus defines the observed state of AccessPermit. + """ + + +class AccessPermitList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AccessPermit] + """ + List of accesspermits. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/authpublickey/__init__.py b/schemas/python/models/io/upbound/nebius/iam/authpublickey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/authpublickey/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/authpublickey/v1beta1.py new file mode 100644 index 000000000..e98269bdf --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/authpublickey/v1beta1.py @@ -0,0 +1,463 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_authpublickey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ServiceAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a ServiceAccount in iam to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate id. + """ + + +class UserAccount(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Account(BaseModel): + anonymousAccount: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside user_account or service_account. (see below for nested schema) + """ + serviceAccount: ServiceAccount | None = None + """ + (Attributes) Cannot be set alongside user_account or anonymous_account. (see below for nested schema) + """ + userAccount: UserAccount | None = None + """ + (Attributes) Cannot be set alongside service_account or anonymous_account. (see below for nested schema) + """ + + +class DataSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class ForProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + dataSecretRef: DataSecretRef | None = None + """ + (String) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + dataSecretRef: DataSecretRef | None = None + """ + (String) + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ServiceAccountModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class Status(BaseModel): + algorithm: str | None = None + """ + (String) + """ + fingerprint: str | None = None + """ + (String) + """ + keySize: float | None = None + """ + (Number) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `INACTIVE` + - `EXPIRED` + - `DELETING` + - `DELETED` + """ + + +class AtProvider(BaseModel): + account: Account | None = None + """ + (Attributes) (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + expiresAt: str | None = None + """ + MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AuthPublicKey(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AuthPublicKey'] | None = 'AuthPublicKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AuthPublicKeySpec defines the desired state of AuthPublicKey + """ + status: StatusModel | None = None + """ + AuthPublicKeyStatus defines the observed state of AuthPublicKey. + """ + + +class AuthPublicKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AuthPublicKey] + """ + List of authpublickeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/federatedcredentials/__init__.py b/schemas/python/models/io/upbound/nebius/iam/federatedcredentials/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/federatedcredentials/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/federatedcredentials/v1beta1.py new file mode 100644 index 000000000..e5bb178cf --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/federatedcredentials/v1beta1.py @@ -0,0 +1,366 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_federatedcredentials.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class OidcProvider(BaseModel): + issuerUrl: str | None = None + """ + OIDC-compatible JWT issuer URL. + """ + jwkSetJson: str | None = None + """ + : + + JSON representation of a JSON Web Key Set (JWKS) with public keys used for + JWT signature verification. + If set, the token service uses this JWKS to verify token signatures. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class SubjectIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubjectIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + federatedSubjectId: str | None = None + """ + : + + Federated subject ID. For oidc_provider, the subject is calculated from the + "sub" claim of the federated JWT token. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + oidcProvider: OidcProvider | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + subjectId: str | None = None + """ + IAM subject (service account) that the federated subject impersonates. + """ + subjectIdRef: SubjectIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate subjectId. + """ + subjectIdSelector: SubjectIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate subjectId. + """ + + +class InitProvider(BaseModel): + federatedSubjectId: str | None = None + """ + : + + Federated subject ID. For oidc_provider, the subject is calculated from the + "sub" claim of the federated JWT token. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + oidcProvider: OidcProvider | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + subjectId: str | None = None + """ + IAM subject (service account) that the federated subject impersonates. + """ + subjectIdRef: SubjectIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate subjectId. + """ + subjectIdSelector: SubjectIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate subjectId. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + federatedSubjectId: str | None = None + """ + : + + Federated subject ID. For oidc_provider, the subject is calculated from the + "sub" claim of the federated JWT token. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + oidcProvider: OidcProvider | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: dict[str, Any] | None = None + subjectId: str | None = None + """ + IAM subject (service account) that the federated subject impersonates. + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class FederatedCredentials(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['FederatedCredentials'] | None = 'FederatedCredentials' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FederatedCredentialsSpec defines the desired state of FederatedCredentials + """ + status: Status | None = None + """ + FederatedCredentialsStatus defines the observed state of FederatedCredentials. + """ + + +class FederatedCredentialsList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[FederatedCredentials] + """ + List of federatedcredentials. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/federation/__init__.py b/schemas/python/models/io/upbound/nebius/iam/federation/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/federation/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/federation/v1beta1.py new file mode 100644 index 000000000..68284a0a3 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/federation/v1beta1.py @@ -0,0 +1,348 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_federation.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class SamlSettings(BaseModel): + forceAuthn: bool | None = None + """ + if "true", the identity provider MUST authenticate the presenter directly rather than rely on a previous security context. + """ + idpIssuer: str | None = None + """ + The unique identifier of the SAML Identity Provider. It usually matches the entityID from the IdP metadata. + """ + ssoUrl: str | None = None + """ + Identity Provider’s Single Sign-On endpoint. This is the URL where the user is redirected to start SAML login. + """ + + +class ForProvider(BaseModel): + active: bool | None = None + """ + Specifies if the federation in active state + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + samlSettings: SamlSettings | None = None + userAccountAutoCreation: bool | None = None + """ + : + + If false, users with access to the federation cannot sign in automatically + and user accounts for them must be pre-created by a federation administrator. + """ + + +class InitProvider(BaseModel): + active: bool | None = None + """ + Specifies if the federation in active state + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + samlSettings: SamlSettings | None = None + userAccountAutoCreation: bool | None = None + """ + : + + If false, users with access to the federation cannot sign in automatically + and user accounts for them must be pre-created by a federation administrator. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + certificatesCount: float | None = None + """ + Number of certificates attached to the SAML federation for verifying SAML responses. + """ + state: str | None = None + """ + : + + Federation state. + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `ACTIVE` + - `INACTIVE` + """ + usersCount: float | None = None + """ + Number of users registered in the IAM federation. This value may differ from the number of users in the identity provider. + """ + + +class AtProvider(BaseModel): + active: bool | None = None + """ + Specifies if the federation in active state + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + samlSettings: SamlSettings | None = None + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + userAccountAutoCreation: bool | None = None + """ + : + + If false, users with access to the federation cannot sign in automatically + and user accounts for them must be pre-created by a federation administrator. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Federation(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Federation'] | None = 'Federation' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FederationSpec defines the desired state of Federation + """ + status: StatusModel | None = None + """ + FederationStatus defines the observed state of Federation. + """ + + +class FederationList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Federation] + """ + List of federations. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/federationcertificate/__init__.py b/schemas/python/models/io/upbound/nebius/iam/federationcertificate/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/federationcertificate/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/federationcertificate/v1beta1.py new file mode 100644 index 000000000..a69b13d61 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/federationcertificate/v1beta1.py @@ -0,0 +1,367 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_federationcertificate.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class DataSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + dataSecretRef: DataSecretRef | None = None + """ + A SecretKeySelector is a reference to a secret key in an arbitrary namespace. + """ + description: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Federation in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Federation in iam to populate parentId. + """ + + +class InitProvider(BaseModel): + dataSecretRef: DataSecretRef | None = None + """ + A SecretKeySelector is a reference to a secret key in an arbitrary namespace. + """ + description: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Federation in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Federation in iam to populate parentId. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + algorithm: str | None = None + fingerprint: str | None = None + keySize: float | None = None + notAfter: str | None = None + """ + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + notBefore: str | None = None + """ + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `EXPIRED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class FederationCertificate(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['FederationCertificate'] | None = 'FederationCertificate' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + FederationCertificateSpec defines the desired state of FederationCertificate + """ + status: StatusModel | None = None + """ + FederationCertificateStatus defines the observed state of FederationCertificate. + """ + + +class FederationCertificateList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[FederationCertificate] + """ + List of federationcertificates. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/group/__init__.py b/schemas/python/models/io/upbound/nebius/iam/group/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/group/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/group/v1beta1.py new file mode 100644 index 000000000..6fb71ec8c --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/group/v1beta1.py @@ -0,0 +1,289 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_group.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + membersCount: float | None = None + serviceAccountsCount: float | None = None + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `ACTIVE` + """ + tenantUserAccountsCount: float | None = None + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Group(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Group'] | None = 'Group' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + GroupSpec defines the desired state of Group + """ + status: StatusModel | None = None + """ + GroupStatus defines the observed state of Group. + """ + + +class GroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Group] + """ + List of groups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/groupmembership/__init__.py b/schemas/python/models/io/upbound/nebius/iam/groupmembership/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/groupmembership/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/groupmembership/v1beta1.py new file mode 100644 index 000000000..e7cc88373 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/groupmembership/v1beta1.py @@ -0,0 +1,479 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_groupmembership.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class MemberIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class MemberIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + memberId: str | None = None + """ + Member of the group. Can be tenant user account id or service account id. + """ + memberIdRef: MemberIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate memberId. + """ + memberIdSelector: MemberIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate memberId. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + memberId: str | None = None + """ + Member of the group. Can be tenant user account id or service account id. + """ + memberIdRef: MemberIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate memberId. + """ + memberIdSelector: MemberIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate memberId. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Group in iam to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Group in iam to populate parentId. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class GroupMemberMetadata(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class ServiceAccountStatus(BaseModel): + active: bool | None = None + + +class TenantUserAccountStatus(BaseModel): + federationId: str | None = None + """ + : + + the federation id of the linked user account. Could be empty in a case of a tenant user account belongs to an invitation which wasn't + accepted. + """ + invitationId: str | None = None + """ + : + + if a tenant user account is created during invitation it gets a reference to the invitation resource + once invitation is accepted it looses this reference (and internally gets a reference to their global federated user account) + """ + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE`: + - in case of ordinary tenant user account a corresponding user can log into the system and use granted tenant resources + - in case of invited tenant user account once the invitation is accepted a corresponding user can start using granted resources + immediately + + - `INACTIVE` - unused + - `BLOCKED`: + - in case of ordinary tenant user account a corresponding user can log into the system but cannot be authorized to use tenant + resources + - in case of invited tenant user account once the invitation is accepted a corresponding user cannot start using granted resources + until is unblocked + """ + userAccountState: str | None = None + """ + : + + user account state can help distinguish case when account is blocked globally + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` - usual state when federated user can log into the system and view/manage granted resources in one or more tenants + - `INACTIVE` - federated user can be blocked (manually or by any specific automated process), in this state user cannot log into the system + - `DELETING`: + federated user can be deleted/forgot, in this state user cannot log into the system and various internal removal interactions are in + progress + """ + + +class Status(BaseModel): + groupMemberMetadata: GroupMemberMetadata | None = None + serviceAccountStatus: ServiceAccountStatus | None = None + tenantUserAccountStatus: TenantUserAccountStatus | None = None + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + memberId: str | None = None + """ + Member of the group. Can be tenant user account id or service account id. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class GroupMembership(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['GroupMembership'] | None = 'GroupMembership' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + GroupMembershipSpec defines the desired state of GroupMembership + """ + status: StatusModel | None = None + """ + GroupMembershipStatus defines the observed state of GroupMembership. + """ + + +class GroupMembershipList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[GroupMembership] + """ + List of groupmemberships. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/invitation/__init__.py b/schemas/python/models/io/upbound/nebius/iam/invitation/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/invitation/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/invitation/v1beta1.py new file mode 100644 index 000000000..a58a3dfb5 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/invitation/v1beta1.py @@ -0,0 +1,321 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_invitation.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class EmailSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class ForProvider(BaseModel): + description: str | None = None + emailSecretRef: EmailSecretRef | None = None + """ + A SecretKeySelector is a reference to a secret key in an arbitrary namespace. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + emailSecretRef: EmailSecretRef | None = None + """ + A SecretKeySelector is a reference to a secret key in an arbitrary namespace. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + expiresAt: str | None = None + """ + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `CREATING` - contacts data is not stored in pds yet. probably will GC it later + - `CREATED` - notification is not sent yet + - `PENDING` - notification is sent, we are waiting for the user to approve the notification + - `EXPIRED` - notification is expired, accept is no longer possible + - `ACCEPTED` - notification is accepted + """ + tenantUserAccountId: str | None = None + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Invitation(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Invitation'] | None = 'Invitation' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + InvitationSpec defines the desired state of Invitation + """ + status: StatusModel | None = None + """ + InvitationStatus defines the observed state of Invitation. + """ + + +class InvitationList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Invitation] + """ + List of invitations. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/project/__init__.py b/schemas/python/models/io/upbound/nebius/iam/project/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/project/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/project/v1beta1.py new file mode 100644 index 000000000..29a1566e2 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/project/v1beta1.py @@ -0,0 +1,315 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_project.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + : + + Name of the region where project resources will be created. + Example: "eu-north1". + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + : + + Name of the region where project resources will be created. + Example: "eu-north1". + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + projectState: str | None = None + """ + : + + Current state of the project. + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `CREATING` + - `ACTIVE` + - `PURGING` + - `CREATED` + - `ACTIVATING` + - `PARKING` + - `PARKED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + : + + Name of the region where project resources will be created. + Example: "eu-north1". + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Project(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Project'] | None = 'Project' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ProjectSpec defines the desired state of Project + """ + status: StatusModel | None = None + """ + ProjectStatus defines the observed state of Project. + """ + + +class ProjectList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Project] + """ + List of projects. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/iam/serviceaccount/__init__.py b/schemas/python/models/io/upbound/nebius/iam/serviceaccount/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/iam/serviceaccount/v1beta1.py b/schemas/python/models/io/upbound/nebius/iam/serviceaccount/v1beta1.py new file mode 100644 index 000000000..ba0cfb7f2 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/iam/serviceaccount/v1beta1.py @@ -0,0 +1,318 @@ +# generated by datamodel-codegen: +# filename: workdir/iam_nebius_upbound_io_v1beta1_serviceaccount.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + active: bool | None = None + """ + (Boolean) + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class ServiceAccount(BaseModel): + apiVersion: Literal['iam.nebius.upbound.io/v1beta1'] | None = ( + 'iam.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ServiceAccount'] | None = 'ServiceAccount' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ServiceAccountSpec defines the desired state of ServiceAccount + """ + status: StatusModel | None = None + """ + ServiceAccountStatus defines the observed state of ServiceAccount. + """ + + +class ServiceAccountList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ServiceAccount] + """ + List of serviceaccounts. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/kms/__init__.py b/schemas/python/models/io/upbound/nebius/kms/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/kms/asymmetrickey/__init__.py b/schemas/python/models/io/upbound/nebius/kms/asymmetrickey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/kms/asymmetrickey/v1beta1.py b/schemas/python/models/io/upbound/nebius/kms/asymmetrickey/v1beta1.py new file mode 100644 index 000000000..3e91d2324 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/kms/asymmetrickey/v1beta1.py @@ -0,0 +1,369 @@ +# generated by datamodel-codegen: +# filename: workdir/kms_nebius_upbound_io_v1beta1_asymmetrickey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + algorithm: str | None = None + """ + : + + Cryptographic algorithm that should be used with the key. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported asymmetric algorithms. + Possible values: + + - `ASYMMETRIC_ALGORITHM_UNSPECIFIED` + - `ECDSA_NIST_P256_SHA_256` - ECDSA signature with NIST P-256 curve and SHA-256 + - `ECDSA_NIST_P384_SHA_384` - ECDSA signature with NIST P-384 curve and SHA-384 + - `RSA_4096_ENC_OAEP_SHA_256` - RSA encryption with RSA-4096 key, OAEP padding and SHA-256. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + algorithm: str | None = None + """ + : + + Cryptographic algorithm that should be used with the key. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported asymmetric algorithms. + Possible values: + + - `ASYMMETRIC_ALGORITHM_UNSPECIFIED` + - `ECDSA_NIST_P256_SHA_256` - ECDSA signature with NIST P-256 curve and SHA-256 + - `ECDSA_NIST_P384_SHA_384` - ECDSA signature with NIST P-384 curve and SHA-384 + - `RSA_4096_ENC_OAEP_SHA_256` - RSA encryption with RSA-4096 key, OAEP padding and SHA-256. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + : + + Time when the key was scheduled for deletion. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + purgeAt: str | None = None + """ + : + + Time when the key will be permanently deleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + State (ACTIVE, SCHEDULED_FOR_DELETION) + + #### Supported values + + Key state + Possible values: + + - `KEY_STATE_UNSPECIFIED` + - `ACTIVE` - Key is active, ready for use + - `SCHEDULED_FOR_DELETION` - Key is scheduled for deletion. + """ + + +class AtProvider(BaseModel): + algorithm: str | None = None + """ + : + + Cryptographic algorithm that should be used with the key. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported asymmetric algorithms. + Possible values: + + - `ASYMMETRIC_ALGORITHM_UNSPECIFIED` + - `ECDSA_NIST_P256_SHA_256` - ECDSA signature with NIST P-256 curve and SHA-256 + - `ECDSA_NIST_P384_SHA_384` - ECDSA signature with NIST P-384 curve and SHA-384 + - `RSA_4096_ENC_OAEP_SHA_256` - RSA encryption with RSA-4096 key, OAEP padding and SHA-256. + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Description of the key. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class AsymmetricKey(BaseModel): + apiVersion: Literal['kms.nebius.upbound.io/v1beta1'] | None = ( + 'kms.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['AsymmetricKey'] | None = 'AsymmetricKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AsymmetricKeySpec defines the desired state of AsymmetricKey + """ + status: StatusModel | None = None + """ + AsymmetricKeyStatus defines the observed state of AsymmetricKey. + """ + + +class AsymmetricKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[AsymmetricKey] + """ + List of asymmetrickeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/kms/symmetrickey/__init__.py b/schemas/python/models/io/upbound/nebius/kms/symmetrickey/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/kms/symmetrickey/v1beta1.py b/schemas/python/models/io/upbound/nebius/kms/symmetrickey/v1beta1.py new file mode 100644 index 000000000..c35deb423 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/kms/symmetrickey/v1beta1.py @@ -0,0 +1,399 @@ +# generated by datamodel-codegen: +# filename: workdir/kms_nebius_upbound_io_v1beta1_symmetrickey.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + algorithm: str | None = None + """ + : + + Encryption algorithm that should be used when using the key to encrypt plaintext. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported symmetric encryption algorithms. + Possible values: + + - `SYMMETRIC_ALGORITHM_UNSPECIFIED` + - `AES_128`: + Deprecated. It is impossible to create new keys with this algorithm. + AES algorithm with 128-bit keys. + + - `AES_256` - AES algorithm with 256-bit keys. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + rotationPeriod: str | None = None + """ + : + + Key rotation period. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + + +class InitProvider(BaseModel): + algorithm: str | None = None + """ + : + + Encryption algorithm that should be used when using the key to encrypt plaintext. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported symmetric encryption algorithms. + Possible values: + + - `SYMMETRIC_ALGORITHM_UNSPECIFIED` + - `AES_128`: + Deprecated. It is impossible to create new keys with this algorithm. + AES algorithm with 128-bit keys. + + - `AES_256` - AES algorithm with 256-bit keys. + """ + description: str | None = None + """ + Description of the key. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + rotationPeriod: str | None = None + """ + : + + Key rotation period. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + : + + Time when the key was scheduled for deletion. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + purgeAt: str | None = None + """ + : + + Time when the key will be permanently deleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + : + + State (ACTIVE, SCHEDULED_FOR_DELETION). + + #### Supported values + + Key state + Possible values: + + - `KEY_STATE_UNSPECIFIED` + - `ACTIVE` - Key is active, ready for use + - `SCHEDULED_FOR_DELETION` - Key is scheduled for deletion. + """ + + +class AtProvider(BaseModel): + algorithm: str | None = None + """ + : + + Encryption algorithm that should be used when using the key to encrypt plaintext. + Must be specified only during create operations. Cannot be updated. + + #### Supported values + + Supported symmetric encryption algorithms. + Possible values: + + - `SYMMETRIC_ALGORITHM_UNSPECIFIED` + - `AES_128`: + Deprecated. It is impossible to create new keys with this algorithm. + AES algorithm with 128-bit keys. + + - `AES_256` - AES algorithm with 256-bit keys. + """ + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Description of the key. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + rotationPeriod: str | None = None + """ + : + + Key rotation period. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SymmetricKey(BaseModel): + apiVersion: Literal['kms.nebius.upbound.io/v1beta1'] | None = ( + 'kms.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SymmetricKey'] | None = 'SymmetricKey' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SymmetricKeySpec defines the desired state of SymmetricKey + """ + status: StatusModel | None = None + """ + SymmetricKeyStatus defines the observed state of SymmetricKey. + """ + + +class SymmetricKeyList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SymmetricKey] + """ + List of symmetrickeys. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/mk8s/__init__.py b/schemas/python/models/io/upbound/nebius/mk8s/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/mk8s/cluster/__init__.py b/schemas/python/models/io/upbound/nebius/mk8s/cluster/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/mk8s/cluster/v1beta1.py b/schemas/python/models/io/upbound/nebius/mk8s/cluster/v1beta1.py new file mode 100644 index 000000000..ddf7522a1 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/mk8s/cluster/v1beta1.py @@ -0,0 +1,597 @@ +# generated by datamodel-codegen: +# filename: workdir/mk8s_nebius_upbound_io_v1beta1_cluster.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class PublicEndpoint(BaseModel): + allowedCidrs: list[str] | None = None + """ + (List of String) : + : + + List of CIDR blocks from which access to public endpoint is allowed. + If field is not set, or list is empty, it means that access is not restricted at all. + """ + + +class Endpoints(BaseModel): + publicEndpoint: PublicEndpoint | None = None + """ + (Attributes) Public endpoint specification. When set, a public endpoint is created. (see below for nested schema) + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ControlPlane(BaseModel): + auditLogs: dict[str, Any] | None = None + """ + (Attributes) : + """ + endpoints: Endpoints | None = None + """ + (Attributes) Specification of endpoints of cluster control plane. (see below for nested schema) + """ + etcdClusterSize: float | None = None + """ + (Number) : + : + + Number of instances in etcd cluster. + 3 by default. + Control plane with `etcd_cluster_size: 3` called "Highly Available" ("HA"), because it's Kubernetes API + will be available despite a failure of one control plane instance. + """ + karpenter: dict[str, Any] | None = None + """ + (Attributes) : + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID where control plane instances will be located. + Also will be default NodeGroup subnet. + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + version: str | None = None + """ + (String) : + : + + Desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + """ + + +class KubeNetwork(BaseModel): + serviceCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks for Service ClusterIP allocation. + For now, only one value is supported. + Must be a valid CIDR block or prefix length. + In case of prefix length, certain CIDR is auto allocated. + Specified CIDR blocks will be reserved in Cluster.spec.control_plane.subnet_id to prevent address duplication. + Allowed prefix length is from "/12" to "/28". + Empty value treated as ["/16"]. + """ + + +class ForProvider(BaseModel): + controlPlane: ControlPlane | None = None + """ + (Attributes) (see below for nested schema) + """ + kubeNetwork: KubeNetwork | None = None + """ + (Attributes) Defines kubernetes network configuration, like IP allocation. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + controlPlane: ControlPlane | None = None + """ + (Attributes) (see below for nested schema) + """ + kubeNetwork: KubeNetwork | None = None + """ + (Attributes) Defines kubernetes network configuration, like IP allocation. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class ControlPlaneModel(BaseModel): + auditLogs: dict[str, Any] | None = None + """ + (Attributes) : + """ + endpoints: Endpoints | None = None + """ + (Attributes) Specification of endpoints of cluster control plane. (see below for nested schema) + """ + etcdClusterSize: float | None = None + """ + (Number) : + : + + Number of instances in etcd cluster. + 3 by default. + Control plane with `etcd_cluster_size: 3` called "Highly Available" ("HA"), because it's Kubernetes API + will be available despite a failure of one control plane instance. + """ + karpenter: dict[str, Any] | None = None + """ + (Attributes) : + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID where control plane instances will be located. + Also will be default NodeGroup subnet. + """ + version: str | None = None + """ + (String) : + : + + Desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + """ + + +class ControlPlaneModel1(BaseModel): + auth: dict[str, Any] | None = None + """ + (Attributes) (see below for nested schema) + """ + endpoints: dict[str, Any] | None = None + """ + (Attributes) Specification of endpoints of cluster control plane. (see below for nested schema) + """ + etcdClusterSize: float | None = None + """ + (Number) : + Number of instances in etcd cluster. + """ + version: str | None = None + """ + (String) : + : + + Actual Kubernetes and configuration version. + Version has format `..-nebius-cp.` like + "1.30.0-nebius-cp.3", where `..` is Kubernetes version and `` is version of control plane + infrastructure and configuration, updating of which may include bug fixes, security updates and new features of components running on + control plane, like CCM or Cluster Autoscaler. + """ + + +class LastOccurrence(BaseModel): + code: str | None = None + """ + (String) Event code (unique within the API service), in UpperCamelCase, e.g. "DiskAttached" + Event code (unique within the API service), in UpperCamelCase, e.g. `"DiskAttached"` + """ + level: str | None = None + """ + (String) : + : + + # Severity level for the event + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - Unspecified event severity level + - `DEBUG` - A debug event providing detailed insight. Such events are used to debug problems with specific resource(s) and process(es) + - `INFO` - A normal event or state change. Informs what is happening with the API resource. Does not require user attention or interaction + - `WARN`: + Warning event. Indicates a potential or minor problem with the API resource and/or the corresponding processes. Needs user attention, + but requires no immediate action (yet) + + - `ERROR` - Error event. Indicates a serious problem with the API resource and/or the corresponding processes. Requires immediate user action + """ + message: str | None = None + """ + (String) : + : + + A human-readable message describing what has happened + (and suggested actions for the user, if this is a `WARN` or `ERROR` level event) + """ + occurredAt: str | None = None + """ + (String) : + : + + # Time at which the event has occurred + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Event(BaseModel): + firstOccurredAt: str | None = None + """ + (String) : + : + + # Time of the first occurrence of a recurrent event + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + lastOccurrence: LastOccurrence | None = None + """ + (Attributes) : + """ + occurrenceCount: float | None = None + """ + (Number) The number of times this event has occurred between first_occurred_at and last_occurrence.occurred_at. Must be > 0 + The number of times this event has occurred between `first_occurred_at` and `last_occurrence.occurred_at`. Must be > 0 + """ + + +class Status(BaseModel): + controlPlane: ControlPlaneModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + events: list[Event] | None = None + """ + (Attributes List) : + """ + reconciling: bool | None = None + """ + (Boolean) Show that changes are in flight + Show that changes are in flight + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `PROVISIONING` + - `RUNNING` + - `DELETING` + """ + + +class AtProvider(BaseModel): + controlPlane: ControlPlaneModel | None = None + """ + (Attributes) (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + kubeNetwork: KubeNetwork | None = None + """ + (Attributes) Defines kubernetes network configuration, like IP allocation. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Cluster(BaseModel): + apiVersion: Literal['mk8s.nebius.upbound.io/v1beta1'] | None = ( + 'mk8s.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Cluster'] | None = 'Cluster' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + ClusterSpec defines the desired state of Cluster + """ + status: StatusModel | None = None + """ + ClusterStatus defines the observed state of Cluster. + """ + + +class ClusterList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Cluster] + """ + List of clusters. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/mk8s/nodegroup/__init__.py b/schemas/python/models/io/upbound/nebius/mk8s/nodegroup/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/mk8s/nodegroup/v1beta1.py b/schemas/python/models/io/upbound/nebius/mk8s/nodegroup/v1beta1.py new file mode 100644 index 000000000..91ff10e40 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/mk8s/nodegroup/v1beta1.py @@ -0,0 +1,1387 @@ +# generated by datamodel-codegen: +# filename: workdir/mk8s_nebius_upbound_io_v1beta1_nodegroup.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Condition(BaseModel): + disabled: bool | None = None + """ + (Boolean) : + : + + When true, disables the default auto-repair condition rules. + + *Cannot be set alongside timeout.* + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + Node condition status. + + #### Supported values + + Possible values: + + - `CONDITION_STATUS_UNSPECIFIED` + - `TRUE` + - `FALSE` + - `UNKNOWN` + """ + timeout: str | None = None + """ + (String) : + : + + The duration after which the node is automatically repaired if the condition remains in the specified status. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + + *Cannot be set alongside disabled.* + """ + type: str | None = None + """ + (String) : + Node condition type. + """ + + +class AutoRepair(BaseModel): + conditions: list[Condition] | None = None + """ + (Attributes List) Conditions that determine whether a node should be auto repaired. (see below for nested schema) + """ + + +class Autoscaling(BaseModel): + maxNodeCount: float | None = None + """ + (Number) + """ + minNodeCount: float | None = None + """ + (Number) + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class MaxSurge(BaseModel): + count: float | None = None + """ + (Number) Cannot be set alongside percent. + *Cannot be set alongside percent.* + """ + percent: float | None = None + """ + (Number) Cannot be set alongside count. + *Cannot be set alongside count.* + """ + + +class MaxUnavailable(BaseModel): + count: float | None = None + """ + (Number) Cannot be set alongside percent. + *Cannot be set alongside percent.* + """ + percent: float | None = None + """ + (Number) Cannot be set alongside count. + *Cannot be set alongside count.* + """ + + +class Strategy(BaseModel): + drainTimeout: str | None = None + """ + (String) : + : + + Maximum amount of time that the service will spend attempting to gracefully drain a node + (evicting its pods) before falling back to pod deletion. + A value of 0 (or when field is omitted) means no timeout: the node can be drained for an unlimited time. + Important consequence of that is if PodDisruptionBudget doesn't allow evicting a pod, + then NodeGroup update with node re-creation will hang on that pod eviction. + Note that this is different from `kubectl drain --timeout`, which gives up and returns an error. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + maxSurge: MaxSurge | None = None + """ + (Attributes) : + """ + maxUnavailable: MaxUnavailable | None = None + """ + is also set to 0. + """ + + +class BootDisk(BaseModel): + blockSizeBytes: float | None = None + """ + (Number) + """ + sizeBytes: float | None = None + """ + (Number) Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_kibibytes, size_mebibytes or size_gibibytes.* + """ + sizeGibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_mebibytes.* + """ + sizeKibibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_mebibytes or size_gibibytes.* + """ + sizeMebibytes: float | None = None + """ + (Number) Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes. + *Cannot be set alongside size_bytes, size_kibibytes or size_gibibytes.* + """ + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `NETWORK_SSD` + - `NETWORK_HDD` + - `NETWORK_SSD_IO_M3` + - `NETWORK_SSD_NON_REPLICATED` + """ + + +class CloudInitUserDataSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ExistingFilesystem(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a Filesystem in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Filesystem in compute to populate id. + """ + + +class Filesystem(BaseModel): + attachMode: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `UNSPECIFIED` + - `READ_ONLY` + - `READ_WRITE` + """ + existingFilesystem: ExistingFilesystem | None = None + """ + (Attributes) (see below for nested schema) + """ + mountTag: str | None = None + """ + defined identifier, allowing to use it as a device in mount command. + Specifies the user-defined identifier, allowing to use it as a device in mount command. + """ + + +class GpuCluster(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + idRef: IdRef | None = None + """ + Reference to a GpuCluster in compute to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a GpuCluster in compute to populate id. + """ + + +class GpuSettings(BaseModel): + driversPreset: str | None = None + """ + : "" + : + + Identifier of the predefined set of drivers included in the ComputeImage deployed on ComputeInstances that are part of the NodeGroup. + Supported presets for different platform / Kubernetes version combinations: + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`: + * `version`: 1.30 → `"cuda12"` (CUDA 12.4) + * `version`: 1.31 → `"cuda12"` (CUDA 12.4), `"cuda12.4"`, `"cuda12.8"` + * `gpu-b200-sxm`: + * `version`: 1.31 → `"cuda12"` (CUDA 12.8), `"cuda12.8"` + * `gpu-b200-sxm-a`: + * `version`: 1.31 → `"cuda12.8"` + """ + + +class Config(BaseModel): + kubeletEphemeral: bool | None = None + """ + (Boolean) : + : + + kubelet_ephemeral: combine all local disks into a single storage volume and use it as kubelet's local ephemeral storage on the node + See also https://kubernetes.io/docs/concepts/storage/ephemeral-storage/ + + The default when LocalDisksSpecConfig is not set. + + *Cannot be set alongside none.* + """ + none: bool | None = None + """ + (Boolean) : + : + + none: "do nothing" - local disks will be provisioned as on a regular compute instance. + + *Cannot be set alongside kubelet_ephemeral.* + """ + + +class PassthroughGroup(BaseModel): + requested: bool | None = None + """ + (Boolean) : + : + + Passthrough local disks from the underlying host. + + Devices are expected to appear in the guest as NVMe devices (nvme0, nvme1, ...), + but the exact number depends on the preset. + Enabled only when this field is explicitly set. + """ + + +class LocalDisks(BaseModel): + config: Config | None = None + """ + (Attributes) : + """ + passthroughGroup: PassthroughGroup | None = None + """ + (Attributes) : + """ + + +class Metadata(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + : + + Kubernetes Node labels. + + Keys and values must follow Kubernetes label syntax: + https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + + For now change will not be propagated to existing nodes, so will be applied only to Kubernetes Nodes created after the field change. + That behavior may change later. + So, for now you will need to manually set them to existing nodes, if that is needed. + + System labels containing "kubernetes.io" and "k8s.io" will be ignored. + Field change will NOT trigger NodeGroup roll out. + """ + + +class SecurityGroup(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class NetworkInterface(BaseModel): + publicIpAddress: dict[str, Any] | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroup] | None = None + """ + (Attributes List) User provided VPC Security Groups which will be assigned to all nodes of this NodeGroup. (see below for nested schema) + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID that will be attached to a node cloud instance network interface. + By default Cluster control plane subnet_id used. + Subnet should be located in the same network with control plane. + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class NvlInstanceGroupIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NvlInstanceGroupIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Nvlink(BaseModel): + nvlInstanceGroupId: str | None = None + """ + (String) Existing NVLInstanceGroup ID to use. + Existing NVLInstanceGroup ID to use. + """ + nvlInstanceGroupIdRef: NvlInstanceGroupIdRef | None = None + """ + Reference to a NvlInstanceGroup in compute to populate nvlInstanceGroupId. + """ + nvlInstanceGroupIdSelector: NvlInstanceGroupIdSelector | None = None + """ + Selector for a NvlInstanceGroup in compute to populate nvlInstanceGroupId. + """ + + +class ReservationPolicy(BaseModel): + policy: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `AUTO`: + 1) Will try to launch instance in any reservation_ids if provided. + 2) Will try to launch instance in any of the available capacity block. + 3) Will try to launch instance in PAYG if 1 & 2 are not satisfied. + + - `FORBID`: + The instance is launched only using on-demand (PAYG) capacity. + No attempt is made to find or use a Capacity Block. + It's an error to provide reservation_ids with policy = FORBID + + - `STRICT`: + 1) Will try to launch the instance in Capacity Blocks from reservation_ids if provided. + 2) If reservation_ids are not provided will try to launch instance in suitable & available Capacity Block. + 3) Fail otherwise. + """ + reservationIds: list[str] | None = None + """ + (List of String) Capacity block groups, order matters + Capacity block groups, order matters + """ + + +class Resources(BaseModel): + platform: str | None = None + """ + (String) + """ + preset: str | None = None + """ + (String) + """ + + +class ServiceAccountIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ServiceAccountIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Taint(BaseModel): + effect: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `EFFECT_UNSPECIFIED` + - `NO_EXECUTE` + - `NO_SCHEDULE` + - `PREFER_NO_SCHEDULE` + """ + key: str | None = None + """ + (String) + """ + value: str | None = None + """ + (String) + """ + + +class Template(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Parameters of a Node Nebius Compute Instance boot disk. (see below for nested schema) + """ + cloudInitUserDataSecretRef: CloudInitUserDataSecretRef | None = None + """ + (String, Sensitive) : + : + + cloud-init user-data + Should contain at least one SSH key. + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) : + """ + gpuCluster: GpuCluster | None = None + """ + (Attributes) Nebius Compute GPUCluster ID that will be attached to node. (see below for nested schema) + """ + gpuSettings: GpuSettings | None = None + """ + (Attributes) : + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + maxPods: float | None = None + """ + (Number) : + : + + The maximum number of Pods per node for your cluster. If omitted, MK8S assigns the default value of 110. When you + configure the maximum number of Pods per node for the cluster, MK8S uses this value to allocate a CIDR range for every node + in group. The node CIDR prefix is calculated as `32 - ceil(log2(2 * max_pods))`, i.e. the smallest IPv4 subnet whose total address + count is at least `2 * max_pods`. Not all IPs are usable for workload Pods because some of them are consumed by system Pods. + """ + metadata: Metadata | None = None + """ + (Attributes) : + """ + networkInterfaces: list[NetworkInterface] | None = None + """ + (Attributes List) (see below for nested schema) + """ + nvlink: Nvlink | None = None + """ + (Attributes) NVLinkSpec configures NVLink settings for the NodeGroup. (see below for nested schema) + """ + os: str | None = None + """ + (String) : + : + + OS version that will be used to create the boot disk of Compute Instances in the NodeGroup. + Supported platform / Kubernetes version / OS / driver presets combinations + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`, `cpu-e1`, `cpu-e2`, `cpu-d3`: + * `drivers_preset`: `""` + * `version`: 1.30 → `"ubuntu22.04"` + * `version`: 1.31 → `"ubuntu22.04"` (default), `"ubuntu24.04"` + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`: + * `drivers_preset`: `"cuda12"` (CUDA 12.4) + * `version`: 1.30, 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.4"` + * `version`: 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm`: + * `drivers_preset`: `""` + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12"` (CUDA 12.8) + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm-a`: + * `drivers_preset`: `""` + * `version`: 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + """ + preemptible: dict[str, Any] | None = None + """ + (Attributes) : + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) : + """ + resources: Resources | None = None + """ + (Attributes) Resources that will have Nebius Compute Instance where Node kubelet will run. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + the Nebius service account whose credentials will be available on the nodes of the group. + With these credentials, it is possible to make `nebius` CLI or public API requests from the nodes + without the need for extra authentication. + This service account is also used to make requests to container registry. + + `resource.serviceaccount.issueAccessToken` permission is required to use this field. + """ + serviceAccountIdRef: ServiceAccountIdRef | None = None + """ + Reference to a ServiceAccount in iam to populate serviceAccountId. + """ + serviceAccountIdSelector: ServiceAccountIdSelector | None = None + """ + Selector for a ServiceAccount in iam to populate serviceAccountId. + """ + taints: list[Taint] | None = None + """ + (Attributes List) : + """ + + +class ForProvider(BaseModel): + autoRepair: AutoRepair | None = None + """ + (Attributes) Parameters for nodes auto repair. (see below for nested schema) + """ + autoscaling: Autoscaling | None = None + """ + (Attributes) : + """ + fixedNodeCount: float | None = None + """ + (Number) : + : + + Number of nodes in the group. Can be changed manually at any time. + + *Cannot be set alongside autoscaling.* + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Cluster in mk8s to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Cluster in mk8s to populate parentId. + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + template: Template | None = None + """ + (Attributes) : + """ + version: str | None = None + """ + (String) : + : + + Version is desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + By default the cluster control plane `.` version will be used. + """ + + +class InitProvider(BaseModel): + autoRepair: AutoRepair | None = None + """ + (Attributes) Parameters for nodes auto repair. (see below for nested schema) + """ + autoscaling: Autoscaling | None = None + """ + (Attributes) : + """ + fixedNodeCount: float | None = None + """ + (Number) : + : + + Number of nodes in the group. Can be changed manually at any time. + + *Cannot be set alongside autoscaling.* + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Cluster in mk8s to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Cluster in mk8s to populate parentId. + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + template: Template | None = None + """ + (Attributes) : + """ + version: str | None = None + """ + (String) : + : + + Version is desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + By default the cluster control plane `.` version will be used. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class LastOccurrence(BaseModel): + code: str | None = None + """ + (String) Event code (unique within the API service), in UpperCamelCase, e.g. "DiskAttached" + Event code (unique within the API service), in UpperCamelCase, e.g. `"DiskAttached"` + """ + level: str | None = None + """ + (String) : + : + + # Severity level for the event + + #### Supported values + + Possible values: + + - `UNSPECIFIED` - Unspecified event severity level + - `DEBUG` - A debug event providing detailed insight. Such events are used to debug problems with specific resource(s) and process(es) + - `INFO` - A normal event or state change. Informs what is happening with the API resource. Does not require user attention or interaction + - `WARN`: + Warning event. Indicates a potential or minor problem with the API resource and/or the corresponding processes. Needs user attention, + but requires no immediate action (yet) + + - `ERROR` - Error event. Indicates a serious problem with the API resource and/or the corresponding processes. Requires immediate user action + """ + message: str | None = None + """ + (String) : + : + + A human-readable message describing what has happened + (and suggested actions for the user, if this is a `WARN` or `ERROR` level event) + """ + occurredAt: str | None = None + """ + (String) : + : + + # Time at which the event has occurred + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Event(BaseModel): + firstOccurredAt: str | None = None + """ + (String) : + : + + # Time of the first occurrence of a recurrent event + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + lastOccurrence: LastOccurrence | None = None + """ + (Attributes) : + """ + occurrenceCount: float | None = None + """ + (Number) The number of times this event has occurred between first_occurred_at and last_occurrence.occurred_at. Must be > 0 + The number of times this event has occurred between `first_occurred_at` and `last_occurrence.occurred_at`. Must be > 0 + """ + + +class Status(BaseModel): + events: list[Event] | None = None + """ + (Attributes List) : + """ + nodeCount: float | None = None + """ + (Number) : + : + + Total number of nodes that are currently in the node group. + Both ready and not ready nodes are counted. + """ + outdatedNodeCount: float | None = None + """ + (Number) : + : + + Total number of nodes that has outdated node configuration. + These nodes will be replaced by new nodes with up-to-date configuration. + """ + readyNodeCount: float | None = None + """ + (Number) : + : + + Total number of nodes that successfully joined the cluster and are ready to serve workloads. + Both outdated and up-to-date nodes are counted. + """ + reconciling: bool | None = None + """ + (Boolean) Show that there are changes are in flight. + Show that there are changes are in flight. + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `PROVISIONING` + - `RUNNING` + - `DELETING` + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + targetNodeCount: float | None = None + """ + (Number) : + : + + Desired total number of nodes that should be in the node group. + It is either `NodeGroupSpec.fixed_node_count` or arbitrary number between + `NodeGroupAutoscalingSpec.min_node_count` and `NodeGroupAutoscalingSpec.max_node_count` decided by autoscaler. + """ + version: str | None = None + """ + (String) : + : + + Actual version of NodeGroup. Have format `..-nebius-node.` like "1.30.0-nebius-node.10". + Where `..` is Kubernetes version and `` is version of Node infrastructure and configuration, + which update may include bug fixes, security updates and new features depending on worker node configuration. + """ + + +class ExistingFilesystemModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class GpuClusterModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + + +class NetworkInterfaceModel(BaseModel): + publicIpAddress: dict[str, Any] | None = None + """ + (Attributes) : + """ + securityGroups: list[SecurityGroup] | None = None + """ + (Attributes List) User provided VPC Security Groups which will be assigned to all nodes of this NodeGroup. (see below for nested schema) + """ + subnetId: str | None = None + """ + (String) : + : + + Nebius VPC Subnet ID that will be attached to a node cloud instance network interface. + By default Cluster control plane subnet_id used. + Subnet should be located in the same network with control plane. + """ + + +class NvlinkModel(BaseModel): + nvlInstanceGroupId: str | None = None + """ + (String) Existing NVLInstanceGroup ID to use. + Existing NVLInstanceGroup ID to use. + """ + + +class TemplateModel(BaseModel): + bootDisk: BootDisk | None = None + """ + (Attributes) Parameters of a Node Nebius Compute Instance boot disk. (see below for nested schema) + """ + filesystems: list[Filesystem] | None = None + """ + (Attributes List) : + """ + gpuCluster: GpuClusterModel | None = None + """ + (Attributes) Nebius Compute GPUCluster ID that will be attached to node. (see below for nested schema) + """ + gpuSettings: GpuSettings | None = None + """ + (Attributes) : + """ + localDisks: LocalDisks | None = None + """ + (Attributes) : + """ + maxPods: float | None = None + """ + (Number) : + : + + The maximum number of Pods per node for your cluster. If omitted, MK8S assigns the default value of 110. When you + configure the maximum number of Pods per node for the cluster, MK8S uses this value to allocate a CIDR range for every node + in group. The node CIDR prefix is calculated as `32 - ceil(log2(2 * max_pods))`, i.e. the smallest IPv4 subnet whose total address + count is at least `2 * max_pods`. Not all IPs are usable for workload Pods because some of them are consumed by system Pods. + """ + metadata: Metadata | None = None + """ + (Attributes) : + """ + networkInterfaces: list[NetworkInterfaceModel] | None = None + """ + (Attributes List) (see below for nested schema) + """ + nvlink: NvlinkModel | None = None + """ + (Attributes) NVLinkSpec configures NVLink settings for the NodeGroup. (see below for nested schema) + """ + os: str | None = None + """ + (String) : + : + + OS version that will be used to create the boot disk of Compute Instances in the NodeGroup. + Supported platform / Kubernetes version / OS / driver presets combinations + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`, `cpu-e1`, `cpu-e2`, `cpu-d3`: + * `drivers_preset`: `""` + * `version`: 1.30 → `"ubuntu22.04"` + * `version`: 1.31 → `"ubuntu22.04"` (default), `"ubuntu24.04"` + * `gpu-l40s-a`, `gpu-l40s-d`, `gpu-h100-sxm`, `gpu-h200-sxm`: + * `drivers_preset`: `"cuda12"` (CUDA 12.4) + * `version`: 1.30, 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.4"` + * `version`: 1.31 → `"ubuntu22.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm`: + * `drivers_preset`: `""` + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12"` (CUDA 12.8) + * `version`: 1.30, 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + * `gpu-b200-sxm-a`: + * `drivers_preset`: `""` + * `version`: 1.31 → `"ubuntu24.04"` + * `drivers_preset`: `"cuda12.8"` + * `version`: 1.31 → `"ubuntu24.04"` + """ + preemptible: dict[str, Any] | None = None + """ + (Attributes) : + """ + reservationPolicy: ReservationPolicy | None = None + """ + (Attributes) : + """ + resources: Resources | None = None + """ + (Attributes) Resources that will have Nebius Compute Instance where Node kubelet will run. (see below for nested schema) + """ + serviceAccountId: str | None = None + """ + (String) : + : + + the Nebius service account whose credentials will be available on the nodes of the group. + With these credentials, it is possible to make `nebius` CLI or public API requests from the nodes + without the need for extra authentication. + This service account is also used to make requests to container registry. + + `resource.serviceaccount.issueAccessToken` permission is required to use this field. + """ + taints: list[Taint] | None = None + """ + (Attributes List) : + """ + + +class AtProvider(BaseModel): + autoRepair: AutoRepair | None = None + """ + (Attributes) Parameters for nodes auto repair. (see below for nested schema) + """ + autoscaling: Autoscaling | None = None + """ + (Attributes) : + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + fixedNodeCount: float | None = None + """ + (Number) : + : + + Number of nodes in the group. Can be changed manually at any time. + + *Cannot be set alongside autoscaling.* + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + strategy: Strategy | None = None + """ + (Attributes) : + """ + template: TemplateModel | None = None + """ + (Attributes) : + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + version: str | None = None + """ + (String) : + : + + Version is desired Kubernetes version of the cluster. For now only acceptable format is + `.` like "1.31". Option for patch version update will be added later. + By default the cluster control plane `.` version will be used. + """ + + +class ConditionModel(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[ConditionModel] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class NodeGroup(BaseModel): + apiVersion: Literal['mk8s.nebius.upbound.io/v1beta1'] | None = ( + 'mk8s.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['NodeGroup'] | None = 'NodeGroup' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NodeGroupSpec defines the desired state of NodeGroup + """ + status: StatusModel | None = None + """ + NodeGroupStatus defines the observed state of NodeGroup. + """ + + +class NodeGroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[NodeGroup] + """ + List of nodegroups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/mysterybox/__init__.py b/schemas/python/models/io/upbound/nebius/mysterybox/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/mysterybox/secret/__init__.py b/schemas/python/models/io/upbound/nebius/mysterybox/secret/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/mysterybox/secret/v1beta1.py b/schemas/python/models/io/upbound/nebius/mysterybox/secret/v1beta1.py new file mode 100644 index 000000000..8e5d3352d --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/mysterybox/secret/v1beta1.py @@ -0,0 +1,379 @@ +# generated by datamodel-codegen: +# filename: workdir/mysterybox_nebius_upbound_io_v1beta1_secret.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) Description of the secret. + Description of the secret. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) Description of the secret. + Description of the secret. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class SecretVersion(BaseModel): + description: str | None = None + """ + (String) Description of the secret. + Description of the version. + """ + payload: list[dict[str, Any]] | None = None + """ + (Attributes List) : + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + (String) : + : + + # Time when user called soft delete method + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + effectiveKmsKeyId: str | None = None + """ + (String) + """ + purgeAt: str | None = None + """ + (String) : + : + + # Time when key should be totally deleted from DB + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + (String) : + : + + State (ACTIVE, SCHEDULED_FOR_DELETION) + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` - Resource is active, ready for use + - `SCHEDULED_FOR_DELETION` - Resource was marked as soft deleted + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) Description of the secret. + Description of the secret. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + primaryVersionId: str | None = None + """ + (String) Specifies the primary version of the secret to update its payload. This parameter should only be provided during update operations. + Specifies the primary version of the secret to update its payload. This parameter should only be provided during update operations. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + secretVersion: SecretVersion | None = None + """ + (Attributes) : + """ + status: Status | None = None + """ + (Attributes) The status of the secret. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Secret(BaseModel): + apiVersion: Literal['mysterybox.nebius.upbound.io/v1beta1'] | None = ( + 'mysterybox.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Secret'] | None = 'Secret' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecretSpec defines the desired state of Secret + """ + status: StatusModel | None = None + """ + SecretStatus defines the observed state of Secret. + """ + + +class SecretList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Secret] + """ + List of secrets. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/mysterybox/secretversion/__init__.py b/schemas/python/models/io/upbound/nebius/mysterybox/secretversion/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/mysterybox/secretversion/v1beta1.py b/schemas/python/models/io/upbound/nebius/mysterybox/secretversion/v1beta1.py new file mode 100644 index 000000000..b53e32a1a --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/mysterybox/secretversion/v1beta1.py @@ -0,0 +1,481 @@ +# generated by datamodel-codegen: +# filename: workdir/mysterybox_nebius_upbound_io_v1beta1_secretversion.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class BinaryValueSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class StringValueSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class PayloadItem(BaseModel): + binaryValueSecretRef: BinaryValueSecretRef | None = None + """ + (String, Sensitive) : + : + + The binary data to encrypt and store in the version of the secret. + + *Cannot be set alongside string_value.* + """ + key: str | None = None + """ + confidential key of the payload entry. + Non-confidential key of the payload entry. + """ + stringValueSecretRef: StringValueSecretRef | None = None + """ + (String, Sensitive) : + : + + The text data to encrypt and store in the version of the secret. + + *Cannot be set alongside binary_value.* + """ + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) Description of the version. + Description of the version. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Secret in mysterybox to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Secret in mysterybox to populate parentId. + """ + payload: list[PayloadItem] | None = None + """ + (Attributes List) : + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) Description of the version. + Description of the version. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a Secret in mysterybox to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a Secret in mysterybox to populate parentId. + """ + payload: list[PayloadItem] | None = None + """ + (Attributes List) : + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class PayloadItemModel(BaseModel): + key: str | None = None + """ + confidential key of the payload entry. + Non-confidential key of the payload entry. + """ + + +class Status(BaseModel): + deletedAt: str | None = None + """ + (String) : + : + + # Time when user called soft delete method + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + purgeAt: str | None = None + """ + (String) : + : + + # Time when key should be totally deleted from DB + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + (String) : + : + + State (ACTIVE, SCHEDULED_FOR_DELETION) + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` - Resource is active, ready for use + - `SCHEDULED_FOR_DELETION` - Resource was marked as soft deleted + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) Description of the version. + Description of the version. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + payload: list[PayloadItemModel] | None = None + """ + (Attributes List) : + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + setPrimary: bool | None = None + """ + (Boolean) + """ + status: Status | None = None + """ + (Attributes) The status of the secret version. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SecretVersion(BaseModel): + apiVersion: Literal['mysterybox.nebius.upbound.io/v1beta1'] | None = ( + 'mysterybox.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SecretVersion'] | None = 'SecretVersion' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecretVersionSpec defines the desired state of SecretVersion + """ + status: StatusModel | None = None + """ + SecretVersionStatus defines the observed state of SecretVersion. + """ + + +class SecretVersionList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SecretVersion] + """ + List of secretversions. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/providerconfig/__init__.py b/schemas/python/models/io/upbound/nebius/providerconfig/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/providerconfig/v1beta1.py b/schemas/python/models/io/upbound/nebius/providerconfig/v1beta1.py new file mode 100644 index 000000000..d7bbcb066 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/providerconfig/v1beta1.py @@ -0,0 +1,201 @@ +# generated by datamodel-codegen: +# filename: workdir/nebius_upbound_io_v1beta1_providerconfig.yaml + +from __future__ import annotations + +from typing import Literal + +from pydantic import AwareDatetime, BaseModel + +from ....k8s.apimachinery.pkg.apis.meta import v1 + + +class Env(BaseModel): + name: str + """ + Name is the name of an environment variable. + """ + + +class Fs(BaseModel): + path: str + """ + Path is a filesystem path. + """ + + +class SecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Credentials(BaseModel): + env: Env | None = None + """ + Env is a reference to an environment variable that contains credentials + that must be used to connect to the provider. + """ + fs: Fs | None = None + """ + Fs is a reference to a filesystem location that contains credentials that + must be used to connect to the provider. + """ + secretRef: SecretRef | None = None + """ + A SecretRef is a reference to a secret key that contains the credentials + that must be used to connect to the provider. + """ + source: Literal['None', 'Secret', 'InjectedIdentity', 'Environment', 'Filesystem'] + """ + Source of the provider credentials. + """ + + +class Identity(BaseModel): + type: Literal['Token', 'ServiceAccount'] + """ + Type specifies the authentication method. + Token: authenticate using a static IAM token from the credentials secret key "token". + ServiceAccount: authenticate using a service-account key (account_id, public_key_id, + private_key) from the credentials secret. + """ + + +class ExponentialFailureRateLimiter(BaseModel): + baseDelay: str | None = None + """ + BaseDelay is the initial delay between retries. + """ + maxDelay: str | None = None + """ + MaxDelay is the maximum delay between retries. + """ + + +class ReconciliationPolicy(BaseModel): + exponentialFailureRateLimiter: ExponentialFailureRateLimiter | None = None + """ + ExponentialFailureRateLimiter, when set, overrides the parameters of the + exponential failure rate limiter used to schedule retries for the + managed resource that this policy applies to. + """ + + +class Spec(BaseModel): + credentials: Credentials + """ + Credentials required to authenticate to this provider. + """ + identity: Identity + """ + Identity specifies the authentication identity configuration. + """ + projectID: str | None = None + """ + ProjectID is the Nebius project ID used as the default parent for + project-parented resources. Individual resources may override it via + spec.forProvider.parentId. Optional. + """ + reconciliationPolicy: ReconciliationPolicy | None = None + """ + ReconciliationPolicy configures how a managed resource is reconciled. + It currently allows overriding the controller's failure rate limiter + parameters on a per-resource basis via ExponentialFailureRateLimiter. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class Status(BaseModel): + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + users: int | None = None + """ + Users of this provider configuration. + """ + + +class ProviderConfig(BaseModel): + apiVersion: Literal['nebius.upbound.io/v1beta1'] | None = ( + 'nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ProviderConfig'] | None = 'ProviderConfig' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + A ProviderConfigSpec defines the desired state of a ProviderConfig. + """ + status: Status | None = None + """ + A ProviderConfigStatus reflects the observed state of a ProviderConfig. + """ + + +class ProviderConfigList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ProviderConfig] + """ + List of providerconfigs. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/providerconfigusage/__init__.py b/schemas/python/models/io/upbound/nebius/providerconfigusage/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/providerconfigusage/v1beta1.py b/schemas/python/models/io/upbound/nebius/providerconfigusage/v1beta1.py new file mode 100644 index 000000000..af72a3ae5 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/providerconfigusage/v1beta1.py @@ -0,0 +1,101 @@ +# generated by datamodel-codegen: +# filename: workdir/nebius_upbound_io_v1beta1_providerconfigusage.yaml + +from __future__ import annotations + +from typing import Literal + +from pydantic import BaseModel + +from ....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ResourceRef(BaseModel): + apiVersion: str + """ + APIVersion of the referenced object. + """ + kind: str + """ + Kind of the referenced object. + """ + name: str + """ + Name of the referenced object. + """ + uid: str | None = None + """ + UID of the referenced object. + """ + + +class ProviderConfigUsage(BaseModel): + apiVersion: Literal['nebius.upbound.io/v1beta1'] | None = ( + 'nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['ProviderConfigUsage'] | None = 'ProviderConfigUsage' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + providerConfigRef: ProviderConfigRef + """ + ProviderConfigReference to the provider config being used. + """ + resourceRef: ResourceRef + """ + ResourceReference to the managed resource using the provider config. + """ + + +class ProviderConfigUsageList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[ProviderConfigUsage] + """ + List of providerconfigusages. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/quotas/__init__.py b/schemas/python/models/io/upbound/nebius/quotas/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/quotas/quotaallowance/__init__.py b/schemas/python/models/io/upbound/nebius/quotas/quotaallowance/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/quotas/quotaallowance/v1beta1.py b/schemas/python/models/io/upbound/nebius/quotas/quotaallowance/v1beta1.py new file mode 100644 index 000000000..1faab55c3 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/quotas/quotaallowance/v1beta1.py @@ -0,0 +1,425 @@ +# generated by datamodel-codegen: +# filename: workdir/quotas_nebius_upbound_io_v1beta1_quotaallowance.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limit: float | None = None + """ + (Number) Total amount of resources allocated. + Total amount of resources allocated. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + (String) : + : + + Name of the region where the quota is allocated. + Example: "eu-north1". + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limit: float | None = None + """ + (Number) Total amount of resources allocated. + Total amount of resources allocated. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + (String) : + : + + Name of the region where the quota is allocated. + Example: "eu-north1". + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + description: str | None = None + """ + (String) : + : + + Human-readable description of the quota. + Example: "Total RAM across VMs". + """ + service: str | None = None + """ + (String) : + : + + Service in which the quota is allocated. + Example: "mk8s". + """ + serviceDescription: str | None = None + """ + (String) : + : + + Human-readable name of the service managing the quota. + Example: "Managed Kubernetes®". + """ + state: str | None = None + """ + (String) : + : + + Current state of the quota. + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `STATE_PROVISIONING` - Quota is being allocated; the process can take up to several minutes. + - `STATE_ACTIVE` - Quota is allocated and can be used. + - `STATE_FROZEN` - Quota is allocated but cannot be used any longer + - `STATE_DELETED` - Quota has been removed and is no longer allocated. + """ + unit: str | None = None + """ + (String) : + : + + Quota unit. + Example: "byte". + """ + usage: float | None = None + """ + (Number) Current quota usage. + Current quota usage. + """ + usagePercentage: str | None = None + """ + (String) : + : + + Current quota usage as a percentage. + Values range from 0.0 to 1.0, representing 0% to 100%. + Values can exceed 1.0 if usage exceeds the limit. + Example: "0.12". + """ + usageState: str | None = None + """ + (String) : + : + + Current state of the quota usage. + + #### Supported values + + Possible values: + + - `USAGE_STATE_UNSPECIFIED` + - `USAGE_STATE_USED` - Quota is actively in use. + - `USAGE_STATE_NOT_USED` - Quota is not currently in use. + - `USAGE_STATE_UNKNOWN`: + Quota region is unreachable, the current usage is therefore unknown. + Please, retry the request later. + + - `USAGE_STATE_NOT_APPLICABLE` - Quota usage is not applicable + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limit: float | None = None + """ + (Number) Total amount of resources allocated. + Total amount of resources allocated. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + region: str | None = None + """ + (String) : + : + + Name of the region where the quota is allocated. + Example: "eu-north1". + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class QuotaAllowance(BaseModel): + apiVersion: Literal['quotas.nebius.upbound.io/v1beta1'] | None = ( + 'quotas.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['QuotaAllowance'] | None = 'QuotaAllowance' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + QuotaAllowanceSpec defines the desired state of QuotaAllowance + """ + status: StatusModel | None = None + """ + QuotaAllowanceStatus defines the observed state of QuotaAllowance. + """ + + +class QuotaAllowanceList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[QuotaAllowance] + """ + List of quotaallowances. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/registry/__init__.py b/schemas/python/models/io/upbound/nebius/registry/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/registry/v1beta1.py b/schemas/python/models/io/upbound/nebius/registry/v1beta1.py new file mode 100644 index 000000000..5547c09bd --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/registry/v1beta1.py @@ -0,0 +1,342 @@ +# generated by datamodel-codegen: +# filename: workdir/registry_nebius_upbound_io_v1beta1_registry.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + (String) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + imagesCount: float | None = None + """ + (Number) Registry.Type type = 2; + """ + registryFqdn: str | None = None + """ + north1.nebius.cloud" + regional fqdn "cr.eu-north1.nebius.cloud" + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `CREATING` + - `ACTIVE` + - `DELETING` + - `SUSPENDED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + (String) + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + imagesCount: float | None = None + """ + (Number) Registry.Type type = 2; + Registry.Type type = 2; + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) This is filled in by the server and reports the current state of the system. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Registry(BaseModel): + apiVersion: Literal['registry.nebius.upbound.io/v1beta1'] | None = ( + 'registry.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Registry'] | None = 'Registry' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RegistrySpec defines the desired state of Registry + """ + status: StatusModel | None = None + """ + RegistryStatus defines the observed state of Registry. + """ + + +class RegistryList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Registry] + """ + List of registries. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/storage/__init__.py b/schemas/python/models/io/upbound/nebius/storage/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/storage/bucket/__init__.py b/schemas/python/models/io/upbound/nebius/storage/bucket/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/storage/bucket/v1beta1.py b/schemas/python/models/io/upbound/nebius/storage/bucket/v1beta1.py new file mode 100644 index 000000000..58ad55ecf --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/storage/bucket/v1beta1.py @@ -0,0 +1,1287 @@ +# generated by datamodel-codegen: +# filename: workdir/storage_nebius_upbound_io_v1beta1_bucket.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Rule(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) : + """ + groupId: str | None = None + """ + (String) : + : + + Group ID to grant access to. + + *Cannot be set alongside anonymous.* + """ + paths: list[str] | None = None + """ + (List of String) : + : + + A list of paths each of which is either a full object key or a prefix ending with a + single "*" wildcard character. A rule is only applied to objects matching any of paths. + If there is a path equal to "*", a rule applies to a whole bucket. + """ + roles: list[str] | None = None + """ + (List of String) A set of roles which a subject will have. All storage.* roles are supported. + A set of roles which a subject will have. All `storage.*` roles are supported. + """ + + +class BucketPolicy(BaseModel): + rules: list[Rule] | None = None + """ + (Attributes List) : + """ + + +class RuleModel(BaseModel): + allowedHeaders: list[str] | None = None + """ + Control-Request-Headers header + Headers that are allowed in a preflight request through the Access-Control-Request-Headers header + """ + allowedMethods: list[str] | None = None + """ + (List of String) HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + """ + allowedOrigins: list[str] | None = None + """ + domain requests from. Single wildcard * is allowed. + The origins that you want to allow cross-domain requests from. Single wildcard * is allowed. + """ + exposeHeaders: list[str] | None = None + """ + (List of String) Headers in the response that you want customers to be able to access from their applications. + Headers in the response that you want customers to be able to access from their applications. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Optional rule identifier. + """ + maxAgeSeconds: float | None = None + """ + (Number) Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + """ + + +class Cors(BaseModel): + rules: list[RuleModel] | None = None + """ + (Attributes List) : + """ + + +class Condition(BaseModel): + methods: list[str] | None = None + """ + (List of String) : + : + + The s3 methods to match. + An empty list matches all methods + + #### Supported values + + Possible values: + + - `METHOD_UNSPECIFIED` + - `GET_OBJECT` + - `HEAD_OBJECT` + - `GET_OBJECT_TAGGING` + - `COPY_OBJECT`: + Copy object method reads the source object. + We account for those operations as source object accesses when calculating `days_since_last_access` for source object. + + - `UPLOAD_PART_COPY`: + Upload part copy method reads the source object. + We account for those operations as source object accesses when calculating `days_since_last_access` for source object. + """ + type: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `TYPE_UNSPECIFIED` + - `INCLUDE`: + If an include type condition is the first condition that the request match, the request will be included in + `days_since_last_access` calculation. + + - `EXCLUDE`: + If an exclude type condition is the first condition that the request match, the request will be ignored in `days_since_last_access` + calculation. + """ + userAgents: list[str] | None = None + """ + (List of String) : + : + + User agents to match. Condition is satisfied if the request's user agent contains any of these substrings. + An empty list matches all user agents. + """ + + +class LastAccessFilter(BaseModel): + conditions: list[Condition] | None = None + """ + (Attributes List) : + """ + + +class AbortIncompleteMultipartUpload(BaseModel): + daysAfterInitiation: float | None = None + """ + (Number) : + : + + Specifies the days since the initiation of an incomplete multipart upload that + the system will wait before permanently removing all parts of the upload. + """ + + +class Expiration(BaseModel): + date: str | None = None + """ + (String) : + : + + Indicates at what date the object will be deleted. The time is always midnight UTC. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + + *Cannot be set alongside days.* + """ + days: float | None = None + """ + (Number) : + : + + Indicates the lifetime, in days, of the objects that are subject to the rule. + The value must be a non-zero positive integer. + + *Cannot be set alongside date.* + """ + expiredObjectDeleteMarker: bool | None = None + """ + (Boolean) : + : + + Indicates whether the system will remove a "delete marker" with no noncurrent versions. + If set to true, the "delete marker" will be permanently removed. + If set to false the policy takes no action. + This cannot be specified with Days or Date in a LifecycleExpiration Policy. + """ + + +class Tag(BaseModel): + key: str | None = None + """ + (String) + """ + value: str | None = None + """ + (String) + """ + + +class Filter(BaseModel): + objectSizeGreaterThanBytes: float | None = None + """ + (Number) Minimum object size to which the rule applies. + Minimum object size to which the rule applies. + """ + objectSizeLessThanBytes: float | None = None + """ + (Number) Maximum object size to which the rule applies. + Maximum object size to which the rule applies. + """ + prefix: str | None = None + """ + (String) : + : + + Prefix identifying one or more objects to which the rule applies. + If prefix is empty, the rule applies to all objects in the bucket. + """ + tags: list[Tag] | None = None + """ + (Attributes List) : + """ + + +class NoncurrentVersionExpiration(BaseModel): + newerNoncurrentVersions: float | None = None + """ + (Number) Specifies how many noncurrent versions the system will retain. + Specifies how many noncurrent versions the system will retain. + """ + noncurrentDays: float | None = None + """ + (Number) Specifies the number of days an object is noncurrent before the system will expire it. + Specifies the number of days an object is noncurrent before the system will expire it. + """ + + +class NoncurrentVersionTransition(BaseModel): + newerNoncurrentVersions: float | None = None + """ + (Number) Specifies how many noncurrent versions the system will retain. + Specifies how many noncurrent versions the system will retain without transition. + """ + noncurrentDays: float | None = None + """ + (Number) Specifies the number of days an object is noncurrent before the system will expire it. + Specifies the number of days an object is noncurrent before the system will transit it. + """ + storageClass: str | None = None + """ + (String) : + : + + Target storage class to transit to. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + + +class Transition(BaseModel): + date: str | None = None + """ + (String) : + : + + Indicates at what date the object will be transited. The time is always midnight UTC. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + + *Cannot be set alongside days or days_since_last_access.* + """ + days: float | None = None + """ + (Number) : + : + + Amount of days since object was uploaded before it's transited to a new storage class. + The value must be a non-zero positive integer. + + *Cannot be set alongside date or days_since_last_access.* + """ + daysSinceLastAccess: float | None = None + """ + calculations for all transition rules. + : + + The number of days since the object was last accessed before it is transitioned. + + *Cannot be set alongside date or days.* + """ + storageClass: str | None = None + """ + (String) : + : + + Target storage class to transit to. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + + +class RuleModel1(BaseModel): + abortIncompleteMultipartUpload: AbortIncompleteMultipartUpload | None = None + """ + (Attributes) : + """ + expiration: Expiration | None = None + """ + (Attributes) : + """ + filter: Filter | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Unique identifier for the rule per configuration. + The value cannot be longer than 255 characters. + """ + noncurrentVersionExpiration: NoncurrentVersionExpiration | None = None + """ + (Attributes) : + """ + noncurrentVersionTransition: NoncurrentVersionTransition | None = None + """ + (Attributes) : + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + #### Supported values + + Possible values: + + - `STATUS_UNSPECIFIED` + - `ENABLED` + - `DISABLED` + """ + transition: Transition | None = None + """ + (Attributes) : + """ + + +class LifecycleConfiguration(BaseModel): + lastAccessFilter: LastAccessFilter | None = None + """ + (Attributes) : + """ + rules: list[RuleModel1] | None = None + """ + (Attributes List) : + """ + + +class ForProvider(BaseModel): + bucketPolicy: BucketPolicy | None = None + """ + (Attributes) : + """ + cors: Cors | None = None + """ + (Attributes) : + """ + defaultStorageClass: str | None = None + """ + (String) : + : + + Storage class to use by default for uploads to the bucket. It may be overridden by `x-amz-storage-class` header. + If not set - STANDARD is used as a default storage class. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + forceStorageClass: bool | None = None + """ + amz-storage-class header. + Flag to force usage of default_storage_class, ignoring `x-amz-storage-class` header. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + lifecycleConfiguration: LifecycleConfiguration | None = None + """ + (Attributes) : + """ + maxSizeBytes: float | None = None + """ + (Number) : + : + + Maximum bucket size. + Zero means unlimited. + Actual limit can be lower if customer doesn't have enough quota. + Real bucket size can go a little higher if customer writes too fast. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + objectAuditLogging: str | None = None + """ + (String) : + : + + Object audit logging specifies which requests must be logged - none, all or mutational only. + + #### Supported values + + Possible values: + + - `OBJECT_AUDIT_LOGGING_UNSPECIFIED` + - `NONE` - Logging is disabled. + - `MUTATE_ONLY` - Logging enabled only for mutating requests. + - `ALL` - Logging enabled for all requests. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + versioningPolicy: str | None = None + """ + (String) : + : + + Supports transitions: + * disabled -\\> enabled + * disabled -\\> suspended + * enabled \\<-\\> suspended + + #### Supported values + + Possible values: + + - `VERSIONING_POLICY_UNSPECIFIED` + - `DISABLED` + - `ENABLED` + - `SUSPENDED` + """ + + +class RuleModel2(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) : + """ + groupId: str | None = None + """ + (String) : + : + + Group ID to grant access to. + + *Cannot be set alongside anonymous.* + """ + paths: list[str] | None = None + """ + (List of String) : + : + + A list of paths each of which is either a full object key or a prefix ending with a + single "*" wildcard character. A rule is only applied to objects matching any of paths. + If there is a path equal to "*", a rule applies to a whole bucket. + """ + roles: list[str] | None = None + """ + (List of String) A set of roles which a subject will have. All storage.* roles are supported. + A set of roles which a subject will have. All `storage.*` roles are supported. + """ + + +class RuleModel3(BaseModel): + allowedHeaders: list[str] | None = None + """ + Control-Request-Headers header + Headers that are allowed in a preflight request through the Access-Control-Request-Headers header + """ + allowedMethods: list[str] | None = None + """ + (List of String) HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + """ + allowedOrigins: list[str] | None = None + """ + domain requests from. Single wildcard * is allowed. + The origins that you want to allow cross-domain requests from. Single wildcard * is allowed. + """ + exposeHeaders: list[str] | None = None + """ + (List of String) Headers in the response that you want customers to be able to access from their applications. + Headers in the response that you want customers to be able to access from their applications. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Optional rule identifier. + """ + maxAgeSeconds: float | None = None + """ + (Number) Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + """ + + +class RuleModel4(BaseModel): + abortIncompleteMultipartUpload: AbortIncompleteMultipartUpload | None = None + """ + (Attributes) : + """ + expiration: Expiration | None = None + """ + (Attributes) : + """ + filter: Filter | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Unique identifier for the rule per configuration. + The value cannot be longer than 255 characters. + """ + noncurrentVersionExpiration: NoncurrentVersionExpiration | None = None + """ + (Attributes) : + """ + noncurrentVersionTransition: NoncurrentVersionTransition | None = None + """ + (Attributes) : + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + #### Supported values + + Possible values: + + - `STATUS_UNSPECIFIED` + - `ENABLED` + - `DISABLED` + """ + transition: Transition | None = None + """ + (Attributes) : + """ + + +class InitProvider(BaseModel): + bucketPolicy: BucketPolicy | None = None + """ + (Attributes) : + """ + cors: Cors | None = None + """ + (Attributes) : + """ + defaultStorageClass: str | None = None + """ + (String) : + : + + Storage class to use by default for uploads to the bucket. It may be overridden by `x-amz-storage-class` header. + If not set - STANDARD is used as a default storage class. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + forceStorageClass: bool | None = None + """ + amz-storage-class header. + Flag to force usage of default_storage_class, ignoring `x-amz-storage-class` header. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + lifecycleConfiguration: LifecycleConfiguration | None = None + """ + (Attributes) : + """ + maxSizeBytes: float | None = None + """ + (Number) : + : + + Maximum bucket size. + Zero means unlimited. + Actual limit can be lower if customer doesn't have enough quota. + Real bucket size can go a little higher if customer writes too fast. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + objectAuditLogging: str | None = None + """ + (String) : + : + + Object audit logging specifies which requests must be logged - none, all or mutational only. + + #### Supported values + + Possible values: + + - `OBJECT_AUDIT_LOGGING_UNSPECIFIED` + - `NONE` - Logging is disabled. + - `MUTATE_ONLY` - Logging enabled only for mutating requests. + - `ALL` - Logging enabled for all requests. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + versioningPolicy: str | None = None + """ + (String) : + : + + Supports transitions: + * disabled -\\> enabled + * disabled -\\> suspended + * enabled \\<-\\> suspended + + #### Supported values + + Possible values: + + - `VERSIONING_POLICY_UNSPECIFIED` + - `DISABLED` + - `ENABLED` + - `SUSPENDED` + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class RuleModel5(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) : + """ + groupId: str | None = None + """ + (String) : + : + + Group ID to grant access to. + + *Cannot be set alongside anonymous.* + """ + paths: list[str] | None = None + """ + (List of String) : + : + + A list of paths each of which is either a full object key or a prefix ending with a + single "*" wildcard character. A rule is only applied to objects matching any of paths. + If there is a path equal to "*", a rule applies to a whole bucket. + """ + roles: list[str] | None = None + """ + (List of String) A set of roles which a subject will have. All storage.* roles are supported. + A set of roles which a subject will have. All `storage.*` roles are supported. + """ + + +class RuleModel6(BaseModel): + allowedHeaders: list[str] | None = None + """ + Control-Request-Headers header + Headers that are allowed in a preflight request through the Access-Control-Request-Headers header + """ + allowedMethods: list[str] | None = None + """ + (List of String) HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + HTTP methods CORS is allowed for: GET, PUT, POST, DELETE, HEAD. + """ + allowedOrigins: list[str] | None = None + """ + domain requests from. Single wildcard * is allowed. + The origins that you want to allow cross-domain requests from. Single wildcard * is allowed. + """ + exposeHeaders: list[str] | None = None + """ + (List of String) Headers in the response that you want customers to be able to access from their applications. + Headers in the response that you want customers to be able to access from their applications. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + Optional rule identifier. + """ + maxAgeSeconds: float | None = None + """ + (Number) Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + Time in seconds that your browser can cache the response for a preflight request as identified by the resource. + """ + + +class RuleModel7(BaseModel): + abortIncompleteMultipartUpload: AbortIncompleteMultipartUpload | None = None + """ + (Attributes) : + """ + expiration: Expiration | None = None + """ + (Attributes) : + """ + filter: Filter | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + : + + Unique identifier for the rule per configuration. + The value cannot be longer than 255 characters. + """ + noncurrentVersionExpiration: NoncurrentVersionExpiration | None = None + """ + (Attributes) : + """ + noncurrentVersionTransition: NoncurrentVersionTransition | None = None + """ + (Attributes) : + """ + status: str | None = None + """ + (Attributes) (see below for nested schema) + : + + #### Supported values + + Possible values: + + - `STATUS_UNSPECIFIED` + - `ENABLED` + - `DISABLED` + """ + transition: Transition | None = None + """ + (Attributes) : + """ + + +class Counters(BaseModel): + inflightPartsQuantity: float | None = None + """ + (Number) + """ + inflightPartsSize: float | None = None + """ + (Number) + """ + multipartObjectsQuantity: float | None = None + """ + (Number) + """ + multipartObjectsSize: float | None = None + """ + (Number) + """ + multipartUploadsQuantity: float | None = None + """ + (Number) + """ + simpleObjectsQuantity: float | None = None + """ + (Number) + """ + simpleObjectsSize: float | None = None + """ + (Number) + """ + + +class NonCurrentCounters(BaseModel): + multipartObjectsQuantity: float | None = None + """ + (Number) + """ + multipartObjectsSize: float | None = None + """ + (Number) + """ + simpleObjectsQuantity: float | None = None + """ + (Number) + """ + simpleObjectsSize: float | None = None + """ + (Number) + """ + + +class Counter(BaseModel): + counters: Counters | None = None + """ + (Attributes List) (see below for nested schema) + """ + nonCurrentCounters: NonCurrentCounters | None = None + """ + (Attributes) : + """ + storageClass: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + + +class Status(BaseModel): + anonymousAccessEnabled: bool | None = None + """ + (Boolean) : + : + + Indicator flag showing whether the bucket has any BucketPolicy rule + that grants anonymous access to any object, prefix, or the entire bucket. + """ + counters: list[Counter] | None = None + """ + (Attributes List) (see below for nested schema) + """ + deletedAt: str | None = None + """ + (String) : + : + + The time when the bucket was deleted (or scheduled for deletion). + It resets to null if the bucket is undeleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + domainName: str | None = None + """ + (String) : + : + + The domain of the endpoint where the bucket can be accessed. It omits the scheme (HTTPS) and the port (443) + and contains only the FQDN address. + """ + purgeAt: str | None = None + """ + (String) : + : + + The time when the bucket will be automatically purged in case it was soft-deleted. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + region: str | None = None + """ + west1". + The name of the region where the bucket is located for use with S3 clients, i.e. "eu-west1". + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` + - `CREATING` - Bucket is under creation and cannot be used yet. + - `ACTIVE` - Bucket is active and ready for usage. + - `UPDATING`: + Bucket is being updated. + It can be used, but some settings are being modified and you can observe their inconsistency. + + - `SCHEDULED_FOR_DELETION`: + Bucket is scheduled for deletion. + It cannot be used in s3 api anymore. + """ + suspensionState: str | None = None + """ + (String) : + : + + #### Supported values + + Possible values: + + - `SUSPENSION_STATE_UNSPECIFIED` + - `NOT_SUSPENDED` + - `SUSPENDED` + """ + + +class AtProvider(BaseModel): + bucketPolicy: BucketPolicy | None = None + """ + (Attributes) : + """ + cors: Cors | None = None + """ + (Attributes) : + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + defaultStorageClass: str | None = None + """ + (String) : + : + + Storage class to use by default for uploads to the bucket. It may be overridden by `x-amz-storage-class` header. + If not set - STANDARD is used as a default storage class. + + #### Supported values + + Possible values: + + - `STORAGE_CLASS_UNSPECIFIED` + - `STANDARD` + - `ENHANCED_THROUGHPUT` + - `INTELLIGENT` + - `FILESYSTEM` - Special storage class only for filesystem buckets. + """ + forceStorageClass: bool | None = None + """ + amz-storage-class header. + Flag to force usage of default_storage_class, ignoring `x-amz-storage-class` header. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + lifecycleConfiguration: LifecycleConfiguration | None = None + """ + (Attributes) : + """ + maxSizeBytes: float | None = None + """ + (Number) : + : + + Maximum bucket size. + Zero means unlimited. + Actual limit can be lower if customer doesn't have enough quota. + Real bucket size can go a little higher if customer writes too fast. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + objectAuditLogging: str | None = None + """ + (String) : + : + + Object audit logging specifies which requests must be logged - none, all or mutational only. + + #### Supported values + + Possible values: + + - `OBJECT_AUDIT_LOGGING_UNSPECIFIED` + - `NONE` - Logging is disabled. + - `MUTATE_ONLY` - Logging enabled only for mutating requests. + - `ALL` - Logging enabled for all requests. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + versioningPolicy: str | None = None + """ + (String) : + : + + Supports transitions: + * disabled -\\> enabled + * disabled -\\> suspended + * enabled \\<-\\> suspended + + #### Supported values + + Possible values: + + - `VERSIONING_POLICY_UNSPECIFIED` + - `DISABLED` + - `ENABLED` + - `SUSPENDED` + """ + + +class ConditionModel(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[ConditionModel] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Bucket(BaseModel): + apiVersion: Literal['storage.nebius.upbound.io/v1beta1'] | None = ( + 'storage.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Bucket'] | None = 'Bucket' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + BucketSpec defines the desired state of Bucket + """ + status: StatusModel | None = None + """ + BucketStatus defines the observed state of Bucket. + """ + + +class BucketList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Bucket] + """ + List of buckets. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/storage/transfer/__init__.py b/schemas/python/models/io/upbound/nebius/storage/transfer/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/storage/transfer/v1beta1.py b/schemas/python/models/io/upbound/nebius/storage/transfer/v1beta1.py new file mode 100644 index 000000000..1541b752d --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/storage/transfer/v1beta1.py @@ -0,0 +1,1216 @@ +# generated by datamodel-codegen: +# filename: workdir/storage_nebius_upbound_io_v1beta1_transfer.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class AfterNEmptyIterations(BaseModel): + emptyIterationsThreshold: float | None = None + """ + (Number) Number of consecutive iterations with zero transferred objects required to stop transfer. + Number of consecutive iterations with zero transferred objects required to stop transfer. + """ + + +class AccessKeyIdSecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class SecretAccessKeySecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class AccessKey(BaseModel): + accessKeyIdSecretRef: AccessKeyIdSecretRef | None = None + """ + (String) Access key ID. + Access key ID. + """ + secretAccessKeySecretRef: SecretAccessKeySecretRef | None = None + """ + (String, Sensitive) Secret access key. + Secret access key. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class BucketNameRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class BucketNameSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Nebius(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the destination bucket is located. + """ + + +class S3Compatible(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where destination bucket is located. + """ + + +class Destination(BaseModel): + nebius: Nebius | None = None + """ + (Attributes) Cannot be set alongside s3_compatible. (see below for nested schema) + """ + prefix: str | None = None + """ + (String) : + : + + Prefix to add to the beginning of each transferred object key in the destination. + During transfer, the resulting object key in the destination is computed + by removing source.prefix (if provided) from the original key and then prepending destination.prefix. + Important: This transformation may result in an empty object key or one that exceeds allowed length limits. + Use prefixes that guarantee valid resulting object keys for your objects after transformation. + """ + s3Compatible: S3Compatible | None = None + """ + (Attributes) Cannot be set alongside nebius. (see below for nested schema) + """ + + +class Limiters(BaseModel): + bandwidthBytesPerSecond: float | None = None + """ + (Number) Maximum bandwidth in bytes per second. If set to zero, default limit will be applied. + Maximum bandwidth in bytes per second. If set to zero, default limit will be applied. + """ + requestsPerSecond: float | None = None + """ + (Number) Maximum number of requests per second. If set to zero, default limit will be applied. + Maximum number of requests per second. If set to zero, default limit will be applied. + """ + + +class AccessKeySecretRef(BaseModel): + key: str + """ + The key to select. + """ + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class AzureStorageAccount(BaseModel): + accessKeySecretRef: AccessKeySecretRef | None = None + """ + (Attributes) (see below for nested schema) + Storage account access key. + """ + accountName: str | None = None + """ + (String) Storage account name. + Storage account name. + """ + + +class AzureBlobStorage(BaseModel): + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + azureStorageAccount: AzureStorageAccount | None = None + """ + (Attributes) Cannot be set alongside anonymous. (see below for nested schema) + """ + containerName: str | None = None + """ + (String) Name of the source Azure Blob Storage container. + Name of the source Azure Blob Storage container. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storageaccountname.blob.core.windows.net". + """ + + +class NebiusModel(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the source bucket is located. + """ + + +class S3CompatibleModel(BaseModel): + accessKey: AccessKey | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where source bucket is located. + """ + + +class Source(BaseModel): + azureBlobStorage: AzureBlobStorage | None = None + """ + (Attributes) Cannot be set alongside nebius or s3_compatible. (see below for nested schema) + """ + nebius: NebiusModel | None = None + """ + (Attributes) Cannot be set alongside s3_compatible. (see below for nested schema) + """ + prefix: str | None = None + """ + (String) : + : + + Prefix to filter objects in the source. Only objects whose keys start with this prefix will be transferred. + During transfer, the resulting object key in the destination is computed + by removing source.prefix from the original key and then prepending destination.prefix (if provided). + Important: This transformation may result in an empty object key or one that exceeds allowed length limits. + Use prefixes that guarantee valid resulting object keys for your objects after transformation. + """ + s3Compatible: S3CompatibleModel | None = None + """ + (Attributes) Cannot be set alongside nebius. (see below for nested schema) + """ + + +class ForProvider(BaseModel): + afterNEmptyIterations: AfterNEmptyIterations | None = None + """ + (Attributes) Cannot be set alongside after_one_iteration or infinite. (see below for nested schema) + """ + afterOneIteration: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside after_n_empty_iterations or infinite. (see below for nested schema) + """ + destination: Destination | None = None + """ + (Attributes) Destination to which the transfer writes data. (see below for nested schema) + """ + enableDeletesInDestination: bool | None = None + """ + (Boolean) : + : + + If enable_deletes_in_destination flag is set, service will delete objects that exist in destination, but don't exist in source. + If touch_unmanaged flag isn't set, we do not delete objects that haven't been created by Data Transfer service. + """ + infinite: dict[str, Any] | None = None + """ + (Attributes) : + """ + interIterationInterval: str | None = None + """ + (String) : + : + + The time to wait since the previous iteration before starting the next one. + Default is 15 minutes if not specified. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limiters: Limiters | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + overwriteStrategy: str | None = None + """ + (String) : + : + + Overwrite strategy set logic of overwrite already existed objects in destination bucket. + + #### Supported values + + Possible values: + + - `OVERWRITE_STRATEGY_UNSPECIFIED` + - `NEVER`: + Never overwrite objects that exist in the destination. + If object exists in destination bucket, skip it. + Safest option to prevent any data loss. + + - `IF_NEWER`: + Overwrite only if source object is newer than destination. + Comparison based on Last-Modified timestamp. + Recommended for incremental sync scenarios. + If touch_unmanaged flag isn't set, we do not overwrite objects that haven't been created by Data Transfer service. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + source: Source | None = None + """ + (Attributes) Source from which the transfer reads data. (see below for nested schema) + """ + touchUnmanaged: bool | None = None + """ + (Boolean) : + : + + If touch_unmanaged flag is set, service will be allowed to overwrite and delete from destination objects that were not + created by Data Transfer Service. If this flag is false, Data Transfer Service will never overwrite or delete objects + that haven't been created by Data Transfer service. + """ + + +class AccessKeyModel(BaseModel): + accessKeyIdSecretRef: AccessKeyIdSecretRef + """ + (String) Access key ID. + Access key ID. + """ + secretAccessKeySecretRef: SecretAccessKeySecretRef | None = None + """ + (String, Sensitive) Secret access key. + Secret access key. + """ + + +class NebiusModel1(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the destination bucket is located. + """ + + +class S3CompatibleModel1(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where destination bucket is located. + """ + + +class NebiusModel2(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + bucketNameRef: BucketNameRef | None = None + """ + Reference to a Bucket in storage to populate bucketName. + """ + bucketNameSelector: BucketNameSelector | None = None + """ + Selector for a Bucket in storage to populate bucketName. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the source bucket is located. + """ + + +class S3CompatibleModel2(BaseModel): + accessKey: AccessKeyModel | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where source bucket is located. + """ + + +class InitProvider(BaseModel): + afterNEmptyIterations: AfterNEmptyIterations | None = None + """ + (Attributes) Cannot be set alongside after_one_iteration or infinite. (see below for nested schema) + """ + afterOneIteration: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside after_n_empty_iterations or infinite. (see below for nested schema) + """ + destination: Destination | None = None + """ + (Attributes) Destination to which the transfer writes data. (see below for nested schema) + """ + enableDeletesInDestination: bool | None = None + """ + (Boolean) : + : + + If enable_deletes_in_destination flag is set, service will delete objects that exist in destination, but don't exist in source. + If touch_unmanaged flag isn't set, we do not delete objects that haven't been created by Data Transfer service. + """ + infinite: dict[str, Any] | None = None + """ + (Attributes) : + """ + interIterationInterval: str | None = None + """ + (String) : + : + + The time to wait since the previous iteration before starting the next one. + Default is 15 minutes if not specified. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limiters: Limiters | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + overwriteStrategy: str | None = None + """ + (String) : + : + + Overwrite strategy set logic of overwrite already existed objects in destination bucket. + + #### Supported values + + Possible values: + + - `OVERWRITE_STRATEGY_UNSPECIFIED` + - `NEVER`: + Never overwrite objects that exist in the destination. + If object exists in destination bucket, skip it. + Safest option to prevent any data loss. + + - `IF_NEWER`: + Overwrite only if source object is newer than destination. + Comparison based on Last-Modified timestamp. + Recommended for incremental sync scenarios. + If touch_unmanaged flag isn't set, we do not overwrite objects that haven't been created by Data Transfer service. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + source: Source | None = None + """ + (Attributes) Source from which the transfer reads data. (see below for nested schema) + """ + touchUnmanaged: bool | None = None + """ + (Boolean) : + : + + If touch_unmanaged flag is set, service will be allowed to overwrite and delete from destination objects that were not + created by Data Transfer Service. If this flag is false, Data Transfer Service will never overwrite or delete objects + that haven't been created by Data Transfer service. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AccessKeyModel1(BaseModel): + accessKeyIdSecretRef: AccessKeyIdSecretRef | None = None + """ + (String) Access key ID. + Access key ID. + """ + secretAccessKeySecretRef: SecretAccessKeySecretRef | None = None + """ + (String, Sensitive) Secret access key. + Secret access key. + """ + + +class NebiusModel3(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the destination bucket is located. + """ + + +class S3CompatibleModel3(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the destination bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where destination bucket is located. + """ + + +class AzureStorageAccountModel(BaseModel): + accountName: str | None = None + """ + (String) Storage account name. + Storage account name. + """ + + +class NebiusModel4(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + Nebius region where the source bucket is located. + """ + + +class S3CompatibleModel4(BaseModel): + accessKey: AccessKeyModel1 | None = None + """ + (Attributes) (see below for nested schema) + """ + anonymous: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside access_key. (see below for nested schema) + """ + bucketName: str | None = None + """ + (String) Name of the destination bucket. + Name of the source bucket. + """ + endpoint: str | None = None + """ + (String) : + : + + The endpoint must be in the form of a URL, starting with the protocol (https), + followed by the endpoint address without a trailing slash. + Example: "https://storage.some-cloud". + """ + region: str | None = None + """ + (String) Nebius region where the destination bucket is located. + S3-compatible provider region where source bucket is located. + """ + + +class Error(BaseModel): + code: str | None = None + """ + (String) Error code, usually taken from the endpoint response. + Error code, usually taken from the endpoint response. + """ + message: str | None = None + """ + (String) Error message, usually taken from the endpoint response. + Error message, usually taken from the endpoint response. + """ + origin: str | None = None + """ + (String) : + : + + Endpoint where the error occurred. + + #### Supported values + + Possible values: + + - `ORIGIN_UNSPECIFIED` + - `SOURCE` - Error originated from the source. + - `DESTINATION` - Error originated from the destination. + """ + + +class LastIteration(BaseModel): + averageThroughputBytes: float | None = None + """ + (Number) Average throughput in bytes per second during the iteration. + Average throughput in bytes per second during the iteration. + """ + endTime: str | None = None + """ + (String) : + : + + Iteration end time. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + error: Error | None = None + """ + (Attributes) Error information if the transfer has failed. (see below for nested schema) + """ + objectsDeletedCount: float | None = None + """ + (Number) Number of objects deleted from destination bucket during this iteration. + Number of objects deleted from destination bucket during this iteration. + """ + objectsTransferredCount: float | None = None + """ + (Number) Number of objects transferred during this iteration. + Number of objects transferred during this iteration. + """ + objectsTransferredSize: float | None = None + """ + (Number) Total size of objects transferred during this iteration. + Total size of objects transferred during this iteration. + """ + sequenceNumber: float | None = None + """ + (Number) Sequence number of the iteration in the transfer, starting from 1. + Sequence number of the iteration in the transfer, starting from 1. + """ + startTime: str | None = None + """ + (String) : + : + + Iteration start time. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + state: str | None = None + """ + (String) : + : + + Current iteration state. + + #### Supported values + + Iteration state. + Possible values: + + - `STATE_UNSPECIFIED` + - `IN_PROGRESS` + - `COMPLETED` + - `INTERRUPTED` + - `FAILED` + """ + + +class Status(BaseModel): + error: Error | None = None + """ + (Attributes) Error information if the transfer has failed. (see below for nested schema) + """ + lastIteration: LastIteration | None = None + """ + (Attributes) : + """ + state: str | None = None + """ + (String) : + : + + Current transfer state. + + #### Supported values + + Transfer state. + Possible values: + + - `STATE_UNSPECIFIED` + - `ACTIVE` + - `STOPPING` + - `STOPPED` + - `FAILING` + - `FAILED` + - `DELETING` + """ + suspensionState: str | None = None + """ + (String) : + : + + If the transfer is suspended, transfer's suspension state becomes SUSPENDED. + + #### Supported values + + Transfer suspension state. + Possible values: + + - `SUSPENSION_STATE_UNSPECIFIED` + - `NOT_SUSPENDED` + - `SUSPENDED` + """ + + +class AtProvider(BaseModel): + afterNEmptyIterations: AfterNEmptyIterations | None = None + """ + (Attributes) Cannot be set alongside after_one_iteration or infinite. (see below for nested schema) + """ + afterOneIteration: dict[str, Any] | None = None + """ + (Attributes) Cannot be set alongside after_n_empty_iterations or infinite. (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + destination: Destination | None = None + """ + (Attributes) Destination to which the transfer writes data. (see below for nested schema) + """ + enableDeletesInDestination: bool | None = None + """ + (Boolean) : + : + + If enable_deletes_in_destination flag is set, service will delete objects that exist in destination, but don't exist in source. + If touch_unmanaged flag isn't set, we do not delete objects that haven't been created by Data Transfer service. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + infinite: dict[str, Any] | None = None + """ + (Attributes) : + """ + interIterationInterval: str | None = None + """ + (String) : + : + + The time to wait since the previous iteration before starting the next one. + Default is 15 minutes if not specified. + + Duration as a string: possibly signed sequence of decimal numbers, each with optional fraction and a unit suffix, such as `300ms`, `-1.5h` or `2h45m`. Valid time units are `ns`, `us` (or `µs`), `ms`, `s`, `m`, `h`, `d`. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + limiters: Limiters | None = None + """ + (Attributes) : + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + overwriteStrategy: str | None = None + """ + (String) : + : + + Overwrite strategy set logic of overwrite already existed objects in destination bucket. + + #### Supported values + + Possible values: + + - `OVERWRITE_STRATEGY_UNSPECIFIED` + - `NEVER`: + Never overwrite objects that exist in the destination. + If object exists in destination bucket, skip it. + Safest option to prevent any data loss. + + - `IF_NEWER`: + Overwrite only if source object is newer than destination. + Comparison based on Last-Modified timestamp. + Recommended for incremental sync scenarios. + If touch_unmanaged flag isn't set, we do not overwrite objects that haven't been created by Data Transfer service. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + source: Source | None = None + """ + (Attributes) Source from which the transfer reads data. (see below for nested schema) + """ + status: Status | None = None + """ + (Attributes) (see below for nested schema) + """ + touchUnmanaged: bool | None = None + """ + (Boolean) : + : + + If touch_unmanaged flag is set, service will be allowed to overwrite and delete from destination objects that were not + created by Data Transfer Service. If this flag is false, Data Transfer Service will never overwrite or delete objects + that haven't been created by Data Transfer service. + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Transfer(BaseModel): + apiVersion: Literal['storage.nebius.upbound.io/v1beta1'] | None = ( + 'storage.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Transfer'] | None = 'Transfer' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + TransferSpec defines the desired state of Transfer + """ + status: StatusModel | None = None + """ + TransferStatus defines the observed state of Transfer. + """ + + +class TransferList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Transfer] + """ + List of transfers. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/tunnel/__init__.py b/schemas/python/models/io/upbound/nebius/tunnel/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/tunnel/v1beta1.py b/schemas/python/models/io/upbound/nebius/tunnel/v1beta1.py new file mode 100644 index 000000000..5ff54ec86 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/tunnel/v1beta1.py @@ -0,0 +1,314 @@ +# generated by datamodel-codegen: +# filename: workdir/tunnel_nebius_upbound_io_v1beta1_tunnel.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from ....k8s.apimachinery.pkg.apis.meta import v1 + + +class ForProvider(BaseModel): + description: str | None = None + """ + Arbitrary description of the tunnel provided by the user. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + title: str | None = None + """ + Human-readable display name for the tunnel. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + Arbitrary description of the tunnel provided by the user. + """ + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + title: str | None = None + """ + Human-readable display name for the tunnel. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + state: str | None = None + """ + : + + Current lifecycle state of the tunnel. + + #### Supported values + + State represents the lifecycle state of the tunnel. + Possible values: + + - `UNSPECIFIED` - Default unspecified state. + - `CREATED` - The tunnel has been created and is active. + - `DELETED` - The tunnel has been deleted. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Arbitrary description of the tunnel provided by the user. + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + title: str | None = None + """ + Human-readable display name for the tunnel. + """ + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Tunnel(BaseModel): + apiVersion: Literal['tunnel.nebius.upbound.io/v1beta1'] | None = ( + 'tunnel.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Tunnel'] | None = 'Tunnel' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + TunnelSpec defines the desired state of Tunnel + """ + status: StatusModel | None = None + """ + TunnelStatus defines the observed state of Tunnel. + """ + + +class TunnelList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Tunnel] + """ + List of tunnels. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/allocation/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/allocation/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/allocation/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/allocation/v1beta1.py new file mode 100644 index 000000000..6328c5969 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/allocation/v1beta1.py @@ -0,0 +1,672 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_allocation.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class PoolIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class PoolIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class SubnetIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SubnetIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Ipv4Private(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g 10.1.2.1), a CIDR block (e.g., "10.1.2.0/24") or + a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + poolIdRef: PoolIdRef | None = None + """ + Reference to a Pool in vpc to populate poolId. + """ + poolIdSelector: PoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate poolId. + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated + with this subnet. + In order to assign an allocation to a resource (i.e. network interface) + both must be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class Ipv4Public(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g. 1.2.3.4), a CIDR block (e.g., "1.2.3.4/24") + or a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + poolIdRef: PoolIdRef | None = None + """ + Reference to a Pool in vpc to populate poolId. + """ + poolIdSelector: PoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate poolId. + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated with + this subnet. + Assigning an allocation to a resource (i.e. network interface) requires + both to be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + subnetIdRef: SubnetIdRef | None = None + """ + Reference to a Subnet in vpc to populate subnetId. + """ + subnetIdSelector: SubnetIdSelector | None = None + """ + Selector for a Subnet in vpc to populate subnetId. + """ + + +class ForProvider(BaseModel): + ipv4Private: Ipv4Private | None = None + """ + (Attributes) : + """ + ipv4Public: Ipv4Public | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + ipv4Private: Ipv4Private | None = None + """ + (Attributes) : + """ + ipv4Public: Ipv4Public | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Ipv4PrivateModel(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g 10.1.2.1), a CIDR block (e.g., "10.1.2.0/24") or + a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated + with this subnet. + In order to assign an allocation to a resource (i.e. network interface) + both must be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + + +class Ipv4PublicModel(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A single IP address (e.g. 1.2.3.4), a CIDR block (e.g., "1.2.3.4/24") + or a prefix length (e.g., "/32"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the pool or subnet. + If not specified, defaults to "/32". + """ + poolId: str | None = None + """ + (String) : + : + + ID of the pool that allocation will receive its IP address from. + + *Cannot be set alongside subnet_id.* + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet that allocation will be associated with. + IP address of the allocation must be within a CIDR block associated with + this subnet. + Assigning an allocation to a resource (i.e. network interface) requires + both to be associated with the same subnet. + + *Cannot be set alongside pool_id.* + """ + + +class LoadBalancer(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the Load Balancer. + """ + + +class NetworkInterface(BaseModel): + instanceId: str | None = None + """ + (String) ID of the Compute instance network interface belongs to. + ID of the Compute instance network interface belongs to. + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Network interface name + """ + type: str | None = None + """ + (String) : + : + + Type of allocation attachment on the network interface. + + #### Supported values + + Possible values: + + - `TYPE_UNSPECIFIED` + - `PRIMARY` - Allocation is attached as the interface private IPv4 address. + - `ALIAS` - Allocation is attached as an IP alias. + - `PUBLIC` - Allocation is attached as the interface public IPv4 address. + """ + + +class Assignment(BaseModel): + loadBalancer: LoadBalancer | None = None + """ + (Attributes) Cannot be set alongside network_interface. (see below for nested schema) + """ + networkInterface: NetworkInterface | None = None + """ + (Attributes) Cannot be set alongside load_balancer. (see below for nested schema) + """ + + +class Details(BaseModel): + allocatedCidr: str | None = None + """ + (String) The actual CIDR block that has been allocated. + The actual CIDR block that has been allocated. + """ + poolId: str | None = None + """ + (String) : + ID of the pool from which this allocation was made. + """ + subnetId: str | None = None + """ + (String) : + : + + ID of the subnet associated with this allocation. + Populated when created with explicit subnet_id, from a subnet-specific pool, + or when assigned to a resource. + """ + version: str | None = None + """ + (String) : + : + + The IP version of this allocation (IPv4 or IPv6). + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + + +class Status(BaseModel): + assignment: Assignment | None = None + """ + (Attributes) : + """ + details: Details | None = None + """ + (Attributes) : + """ + state: str | None = None + """ + (String) : + : + + This field represents the current state of the allocation. + + #### Supported values + + Enumeration of possible states of the Allocation. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `CREATING` - Allocation is being created. + - `ALLOCATED` - Allocation is ready for use. + - `ASSIGNED` - Allocation is used. + - `DELETING` - Allocation is being deleted. + """ + static: bool | None = None + """ + Lifecycle of allocation depends on resource that using it. + If false - Lifecycle of allocation depends on resource that using it. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ipv4Private: Ipv4PrivateModel | None = None + """ + (Attributes) : + """ + ipv4Public: Ipv4PublicModel | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) : + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Allocation(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Allocation'] | None = 'Allocation' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + AllocationSpec defines the desired state of Allocation + """ + status: StatusModel | None = None + """ + AllocationStatus defines the observed state of Allocation. + """ + + +class AllocationList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Allocation] + """ + List of allocations. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/network/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/network/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/network/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/network/v1beta1.py new file mode 100644 index 000000000..c69cd222b --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/network/v1beta1.py @@ -0,0 +1,413 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_network.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Pool(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the pool. + """ + idRef: IdRef | None = None + """ + Reference to a Pool in vpc to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Pool in vpc to populate id. + """ + + +class Ipv4PrivatePools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) (see below for nested schema) + """ + + +class Ipv4PublicPools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) (see below for nested schema) + """ + + +class ForProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class PoolModel(BaseModel): + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the pool. + """ + + +class Status(BaseModel): + defaultRouteTableId: str | None = None + """ + (String) ID of the network's default route table. + ID of the network's default route table. + """ + state: str | None = None + """ + (String) : + : + + Current state of the network. + + #### Supported values + + Enumeration of possible states of the network. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `CREATING` - Network is being created. + - `READY` - Network is ready for use. + - `DELETING` - Network is being deleted. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) Status of the network. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Network(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Network'] | None = 'Network' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + NetworkSpec defines the desired state of Network + """ + status: StatusModel | None = None + """ + NetworkStatus defines the observed state of Network. + """ + + +class NetworkList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Network] + """ + List of networks. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/pool/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/pool/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/pool/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/pool/v1beta1.py new file mode 100644 index 000000000..59032b3f5 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/pool/v1beta1.py @@ -0,0 +1,556 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_pool.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Cidr(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A CIDR block (e.g., "10.1.2.0/24") or a prefix length (e.g., "/24"). + If prefix length is specified, the CIDR block will be auto-allocated from + the available space in the parent pool. + """ + maxMaskLength: float | None = None + """ + (Number) : + : + + Maximum mask length for this pool child pools and allocations. + Default max_mask_length is 32 for IPv4. + """ + state: str | None = None + """ + (String) : + : + + Controls provisioning of IP addresses from the CIDR block to other pools + or allocations. Defaults to AVAILABLE. + + #### Supported values + + Controls provisioning of IP addresses from this pool to other pools + or allocations. Defaults to AVAILABLE. + Possible values: + + - `STATE_UNSPECIFIED` - Not used, mandated by the protocol. + - `AVAILABLE` - Default state. Provision of the IP addresses from this CIDR block is allowed. + - `DISABLED` - Provision of the IP addresses from this CIDR block is denied. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class SourcePoolIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SourcePoolIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + cidrs: list[Cidr] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sourcePoolId: str | None = None + """ + (String) : + : + + ID of the source pool. + CIDR blocks of a pool must be within the range defined by its source pool. + """ + sourcePoolIdRef: SourcePoolIdRef | None = None + """ + Reference to a Pool in vpc to populate sourcePoolId. + """ + sourcePoolIdSelector: SourcePoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate sourcePoolId. + """ + version: str | None = None + """ + (String) : + : + + IP version of the pool. + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + visibility: str | None = None + """ + (String) : + : + + Configures whether the pool is private or public. + Only public pools IP addresses are routable in the Internet. + + #### Supported values + + Possible values: + + - `IP_VISIBILITY_UNSPECIFIED` - Default, unspecified IP visibility. + - `PRIVATE` - Private address. + - `PUBLIC` - Public address. + """ + + +class InitProvider(BaseModel): + cidrs: list[Cidr] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + sourcePoolId: str | None = None + """ + (String) : + : + + ID of the source pool. + CIDR blocks of a pool must be within the range defined by its source pool. + """ + sourcePoolIdRef: SourcePoolIdRef | None = None + """ + Reference to a Pool in vpc to populate sourcePoolId. + """ + sourcePoolIdSelector: SourcePoolIdSelector | None = None + """ + Selector for a Pool in vpc to populate sourcePoolId. + """ + version: str | None = None + """ + (String) : + : + + IP version of the pool. + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + visibility: str | None = None + """ + (String) : + : + + Configures whether the pool is private or public. + Only public pools IP addresses are routable in the Internet. + + #### Supported values + + Possible values: + + - `IP_VISIBILITY_UNSPECIFIED` - Default, unspecified IP visibility. + - `PRIVATE` - Private address. + - `PUBLIC` - Public address. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Assignment(BaseModel): + networks: list[str] | None = None + """ + (List of String) IDs of Networks to which the Pool is assigned. + IDs of Networks to which the Pool is assigned. + """ + subnets: list[str] | None = None + """ + (List of String) IDs of Subnets to which the Pool is assigned. + IDs of Subnets to which the Pool is assigned. + """ + + +class Status(BaseModel): + assignment: Assignment | None = None + """ + (Attributes) Assignment details for this Pool (see below for nested schema) + """ + cidrs: list[str] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + CIDR blocks. + """ + scopeId: str | None = None + """ + (String) Scope is the unique identifier for single pool tree. + Scope is the unique identifier for single pool tree. + """ + state: str | None = None + """ + (String) : + : + + Current state of the Pool. + + #### Supported values + + Possible states of the Pool. + Possible values: + + - `STATE_UNSPECIFIED` - Default, unspecified state. + - `CREATING` - Pool is being created. + - `READY` - Pool is ready for use. + - `DELETING` - Pool is being deleted. + """ + + +class AtProvider(BaseModel): + cidrs: list[Cidr] | None = None + """ + (Attributes List) CIDR blocks defined by the pool. (see below for nested schema) + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + sourcePoolId: str | None = None + """ + (String) : + : + + ID of the source pool. + CIDR blocks of a pool must be within the range defined by its source pool. + """ + status: Status | None = None + """ + (Attributes) Status information for the Pool. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + version: str | None = None + """ + (String) : + : + + IP version of the pool. + + #### Supported values + + Possible values: + + - `IP_VERSION_UNSPECIFIED` - Default, unspecified IP version. + - `IPV4` - IPv4 address. + - `IPV6` - IPv6 address. + """ + visibility: str | None = None + """ + (String) : + : + + Configures whether the pool is private or public. + Only public pools IP addresses are routable in the Internet. + + #### Supported values + + Possible values: + + - `IP_VISIBILITY_UNSPECIFIED` - Default, unspecified IP visibility. + - `PRIVATE` - Private address. + - `PUBLIC` - Public address. + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Pool(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Pool'] | None = 'Pool' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + PoolSpec defines the desired state of Pool + """ + status: StatusModel | None = None + """ + PoolStatus defines the observed state of Pool. + """ + + +class PoolList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Pool] + """ + List of pools. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/route/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/route/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/route/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/route/v1beta1.py new file mode 100644 index 000000000..179258a81 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/route/v1beta1.py @@ -0,0 +1,460 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_route.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Destination(BaseModel): + cidr: str | None = None + """ + : + + Destination CIDR block in IPv4 format (e.g., "0.0.0.0/0" for default route, "192.168.100.0/24" for specific subnet). + The CIDR notation specifies the range of IP addresses that this route will match. + Must be unique within a route table. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class IdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class IdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Allocation(BaseModel): + id: str | None = None + """ + ID of the IP allocation to use as the next hop. + """ + idRef: IdRef | None = None + """ + Reference to a Allocation in vpc to populate id. + """ + idSelector: IdSelector | None = None + """ + Selector for a Allocation in vpc to populate id. + """ + + +class NextHop(BaseModel): + allocation: Allocation | None = None + defaultEgressGateway: bool | None = None + """ + : + + Use the default egress gateway for outbound traffic. + Note: For VMs with public addresses (Floating IPs/FIPs), the FIP-specific route + takes precedence over this default egress gateway route. + + *Cannot be set alongside allocation.* + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + description: str | None = None + """ + Optional description of the route. + """ + destination: Destination | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + nextHop: NextHop | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a RouteTable in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate parentId. + """ + + +class InitProvider(BaseModel): + description: str | None = None + """ + Optional description of the route. + """ + destination: Destination | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + nextHop: NextHop | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a RouteTable in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate parentId. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class AllocationModel(BaseModel): + id: str | None = None + """ + ID of the IP allocation to use as the next hop. + """ + + +class AllocationModel1(BaseModel): + cidr: str | None = None + """ + The CIDR of the allocation being used as the next hop. + """ + + +class NextHopModel(BaseModel): + allocation: AllocationModel1 | None = None + defaultEgressGateway: dict[str, Any] | None = None + + +class Status(BaseModel): + nextHop: NextHopModel | None = None + priority: float | None = None + """ + : + + Indicates priority of the route. + That is 0 or a positive number. + Lower value = higher priority; 0 is the highest priority. + """ + state: str | None = None + """ + : + + Current state of the route. + + #### Supported values + + Possible values: + + - `STATE_UNSPECIFIED` - The state is unknown or not yet set. + - `READY` - The route is configured and operational. + """ + type: str | None = None + """ + : + + Indicates the route type. + REDISTRIBUTED routes cannot be deleted directly. + + #### Supported values + + Route type. + Possible values: + + - `TYPE_UNSPECIFIED` + - `STATIC` + - `REDISTRIBUTED` + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + description: str | None = None + """ + Optional description of the route. + """ + destination: Destination | None = None + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + nextHop: NextHop | None = None + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Route(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Route'] | None = 'Route' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RouteSpec defines the desired state of Route + """ + status: StatusModel | None = None + """ + RouteStatus defines the observed state of Route. + """ + + +class RouteList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Route] + """ + List of routes. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/routetable/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/routetable/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/routetable/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/routetable/v1beta1.py new file mode 100644 index 000000000..fc5406683 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/routetable/v1beta1.py @@ -0,0 +1,359 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_routetable.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class NetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + networkId: str | None = None + """ + ID of the VPC network this route table belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + networkId: str | None = None + """ + ID of the VPC network this route table belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Assignment(BaseModel): + subnets: list[str] | None = None + """ + List of subnet IDs that use this route table for their routing configuration. + """ + + +class Status(BaseModel): + assignment: Assignment | None = None + default: bool | None = None + """ + : + + Indicates if this is the default route table for the network. + Only one route table can be default per network. + """ + state: str | None = None + """ + : + + Current state of the route table. + + #### Supported values + + State indicates the current operational state of the route table. + Possible values: + + - `STATE_UNSPECIFIED` - The state is unknown or not yet set. + - `READY` - The route table is configured and operational. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + labels: dict[str, str] | None = None + """ + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + name: str | None = None + """ + Human readable name for the resource. + """ + networkId: str | None = None + """ + ID of the VPC network this route table belongs to. + """ + parentId: str | None = None + """ + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + updatedAt: str | None = None + """ + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class RouteTable(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['RouteTable'] | None = 'RouteTable' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + RouteTableSpec defines the desired state of RouteTable + """ + status: StatusModel | None = None + """ + RouteTableStatus defines the observed state of RouteTable. + """ + + +class RouteTableList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[RouteTable] + """ + List of routetables. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/securitygroup/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/securitygroup/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/securitygroup/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/securitygroup/v1beta1.py new file mode 100644 index 000000000..b6e39a74f --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/securitygroup/v1beta1.py @@ -0,0 +1,384 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_securitygroup.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class NetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the VPC network this security group belongs to. + ID of the VPC network this security group belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class InitProvider(BaseModel): + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the VPC network this security group belongs to. + ID of the VPC network this security group belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Status(BaseModel): + default: bool | None = None + """ + (Boolean) : + : + + Indicates if this is the default security group for the network. + Only one security group can be default per network. + Will be used on the interface if no other is specified. + """ + state: str | None = None + """ + (String) : + : + + Current state of the security group. + + #### Supported values + + Enumeration of possible states of the security group. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `READY` - Security group is ready for use. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the VPC network this security group belongs to. + ID of the VPC network this security group belongs to. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) Current status of the security group. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SecurityGroup(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SecurityGroup'] | None = 'SecurityGroup' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecurityGroupSpec defines the desired state of SecurityGroup + """ + status: StatusModel | None = None + """ + SecurityGroupStatus defines the observed state of SecurityGroup. + """ + + +class SecurityGroupList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SecurityGroup] + """ + List of securitygroups. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/securityrule/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/securityrule/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/securityrule/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/securityrule/v1beta1.py new file mode 100644 index 000000000..87d716c36 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/securityrule/v1beta1.py @@ -0,0 +1,833 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_securityrule.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class DestinationSecurityGroupIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class DestinationSecurityGroupIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Egress(BaseModel): + destinationCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the destination. + Optional. Empty list means any address. + Must be a valid IPv4. + Maximum of 8 CIDRs can be specified. + """ + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + destinationSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the destination. + ID of the referenced Security Group as the destination. + """ + destinationSecurityGroupIdRef: DestinationSecurityGroupIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate destinationSecurityGroupId. + """ + destinationSecurityGroupIdSelector: DestinationSecurityGroupIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate destinationSecurityGroupId. + """ + + +class SourceSecurityGroupIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class SourceSecurityGroupIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class Ingress(BaseModel): + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of destination ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + sourceCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the source. + Optional. Empty list means any address. + Must be a valid IPv4 + Maximum of 8 CIDRs can be specified. + """ + sourceSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the source. + ID of the referenced Security Group as the source. + """ + sourceSecurityGroupIdRef: SourceSecurityGroupIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate sourceSecurityGroupId. + """ + sourceSecurityGroupIdSelector: SourceSecurityGroupIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate sourceSecurityGroupId. + """ + + +class ParentIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class ParentIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + access: str | None = None + """ + (String) : + : + + Access action for the rule. + Required. Determines whether matching traffic is allowed or denied. + + #### Supported values + + Access specifies action on matching traffic: ALLOW or DENY. + Possible values: + + - `ACCESS_UNSPECIFIED` + - `ALLOW` + - `DENY` + """ + egress: Egress | None = None + """ + (Attributes) : + """ + ingress: Ingress | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate parentId. + """ + priority: float | None = None + """ + (Number) : + : + + Priority of the rule. Valid range: 0-1000. + Optional. If not specified or set to 0, defaults to 500. + Rules are evaluated in priority order (lower numbers first) using a first-match algorithm: + only the first matching rule takes effect (ALLOW or DENY), and subsequent rules are skipped. + + When multiple rules share the same priority, DENY rules are evaluated before ALLOW rules. + The final evaluation order is reflected in 'effective_priority' (see SecurityRuleStatus). + """ + protocol: str | None = None + """ + (String) : + : + + Protocol used in the rule. + Supported values: ANY, TCP, UDP, ICMP. + + #### Supported values + + Protocol specifies traffic protocol. + Possible values: + + - `PROTOCOL_UNSPECIFIED` + - `ANY` + - `TCP` + - `UDP` + - `ICMP` + """ + type: str | None = None + """ + (String) : + : + + Type of the rule (STATEFUL or STATELESS) + Default value is STATEFUL + + #### Supported values + + RuleType specifies whether the security rule is stateful or stateless. + Possible values: + + - `RULE_TYPE_UNSPECIFIED` + - `STATEFUL` + - `STATELESS` + """ + + +class InitProvider(BaseModel): + access: str | None = None + """ + (String) : + : + + Access action for the rule. + Required. Determines whether matching traffic is allowed or denied. + + #### Supported values + + Access specifies action on matching traffic: ALLOW or DENY. + Possible values: + + - `ACCESS_UNSPECIFIED` + - `ALLOW` + - `DENY` + """ + egress: Egress | None = None + """ + (Attributes) : + """ + ingress: Ingress | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + parentIdRef: ParentIdRef | None = None + """ + Reference to a SecurityGroup in vpc to populate parentId. + """ + parentIdSelector: ParentIdSelector | None = None + """ + Selector for a SecurityGroup in vpc to populate parentId. + """ + priority: float | None = None + """ + (Number) : + : + + Priority of the rule. Valid range: 0-1000. + Optional. If not specified or set to 0, defaults to 500. + Rules are evaluated in priority order (lower numbers first) using a first-match algorithm: + only the first matching rule takes effect (ALLOW or DENY), and subsequent rules are skipped. + + When multiple rules share the same priority, DENY rules are evaluated before ALLOW rules. + The final evaluation order is reflected in 'effective_priority' (see SecurityRuleStatus). + """ + protocol: str | None = None + """ + (String) : + : + + Protocol used in the rule. + Supported values: ANY, TCP, UDP, ICMP. + + #### Supported values + + Protocol specifies traffic protocol. + Possible values: + + - `PROTOCOL_UNSPECIFIED` + - `ANY` + - `TCP` + - `UDP` + - `ICMP` + """ + type: str | None = None + """ + (String) : + : + + Type of the rule (STATEFUL or STATELESS) + Default value is STATEFUL + + #### Supported values + + RuleType specifies whether the security rule is stateful or stateless. + Possible values: + + - `RULE_TYPE_UNSPECIFIED` + - `STATEFUL` + - `STATELESS` + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class EgressModel(BaseModel): + destinationCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the destination. + Optional. Empty list means any address. + Must be a valid IPv4. + Maximum of 8 CIDRs can be specified. + """ + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + destinationSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the destination. + ID of the referenced Security Group as the destination. + """ + + +class IngressModel(BaseModel): + destinationPorts: list[float] | None = None + """ + (List of Number) : + : + + List of destination ports to which the rule applies. + Optional. Empty list means any port. + Valid range: 1–65535. + Maximum of 8 ports can be specified. + """ + sourceCidrs: list[str] | None = None + """ + (List of String) : + : + + CIDR blocks as the source. + Optional. Empty list means any address. + Must be a valid IPv4 + Maximum of 8 CIDRs can be specified. + """ + sourceSecurityGroupId: str | None = None + """ + (String) ID of the referenced Security Group as the source. + ID of the referenced Security Group as the source. + """ + + +class Destination(BaseModel): + cidrs: list[str] | None = None + """ + (List of String) List of CIDR blocks. + List of CIDR blocks. + """ + ports: list[float] | None = None + """ + (List of Number) List of ports. + List of ports. + """ + securityGroupId: str | None = None + """ + (String) ID of the Security Group. + ID of the Security Group. + """ + + +class Source(BaseModel): + cidrs: list[str] | None = None + """ + (List of String) List of CIDR blocks. + List of CIDR blocks. + """ + ports: list[float] | None = None + """ + (List of Number) List of ports. + List of ports. + """ + securityGroupId: str | None = None + """ + (String) ID of the Security Group. + ID of the Security Group. + """ + + +class Status(BaseModel): + destination: Destination | None = None + """ + (Attributes) Destination of the traffic that matched the rule. (see below for nested schema) + """ + direction: str | None = None + """ + (String) : + : + + Direction of traffic affected by the rule. + + #### Supported values + + Direction specifies whether traffic is INGRESS (incoming) or EGRESS (outgoing). + Possible values: + + - `DIRECTION_UNSPECIFIED` + - `INGRESS` + - `EGRESS` + """ + effectivePriority: float | None = None + """ + (Number) : + : + + Effective priority used for rule evaluation order, calculated by the system. + This value is computed from the user-specified 'priority' (SecurityRuleSpec). + Rules are evaluated in ascending order of effective_priority using a first-match algorithm. + """ + source: Source | None = None + """ + (Attributes) Source of the traffic that matched the rule. (see below for nested schema) + """ + state: str | None = None + """ + (String) : + : + + #### Supported values + + State describes lifecycle phases of a security rule. + Possible values: + + - `STATE_UNSPECIFIED` + - `CREATING` + - `READY` + - `DELETING` + """ + + +class AtProvider(BaseModel): + access: str | None = None + """ + (String) : + : + + Access action for the rule. + Required. Determines whether matching traffic is allowed or denied. + + #### Supported values + + Access specifies action on matching traffic: ALLOW or DENY. + Possible values: + + - `ACCESS_UNSPECIFIED` + - `ALLOW` + - `DENY` + """ + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + egress: EgressModel | None = None + """ + (Attributes) : + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ingress: IngressModel | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + priority: float | None = None + """ + (Number) : + : + + Priority of the rule. Valid range: 0-1000. + Optional. If not specified or set to 0, defaults to 500. + Rules are evaluated in priority order (lower numbers first) using a first-match algorithm: + only the first matching rule takes effect (ALLOW or DENY), and subsequent rules are skipped. + + When multiple rules share the same priority, DENY rules are evaluated before ALLOW rules. + The final evaluation order is reflected in 'effective_priority' (see SecurityRuleStatus). + """ + protocol: str | None = None + """ + (String) : + : + + Protocol used in the rule. + Supported values: ANY, TCP, UDP, ICMP. + + #### Supported values + + Protocol specifies traffic protocol. + Possible values: + + - `PROTOCOL_UNSPECIFIED` + - `ANY` + - `TCP` + - `UDP` + - `ICMP` + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + status: Status | None = None + """ + (Attributes) Current status of the security rule. (see below for nested schema) + """ + type: str | None = None + """ + (String) : + : + + Type of the rule (STATEFUL or STATELESS) + Default value is STATEFUL + + #### Supported values + + RuleType specifies whether the security rule is stateful or stateless. + Possible values: + + - `RULE_TYPE_UNSPECIFIED` + - `STATEFUL` + - `STATELESS` + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class SecurityRule(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['SecurityRule'] | None = 'SecurityRule' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SecurityRuleSpec defines the desired state of SecurityRule + """ + status: StatusModel | None = None + """ + SecurityRuleStatus defines the observed state of SecurityRule. + """ + + +class SecurityRuleList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[SecurityRule] + """ + List of securityrules. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/schemas/python/models/io/upbound/nebius/vpc/subnet/__init__.py b/schemas/python/models/io/upbound/nebius/vpc/subnet/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/schemas/python/models/io/upbound/nebius/vpc/subnet/v1beta1.py b/schemas/python/models/io/upbound/nebius/vpc/subnet/v1beta1.py new file mode 100644 index 000000000..595683003 --- /dev/null +++ b/schemas/python/models/io/upbound/nebius/vpc/subnet/v1beta1.py @@ -0,0 +1,610 @@ +# generated by datamodel-codegen: +# filename: workdir/vpc_nebius_upbound_io_v1beta1_subnet.yaml + +from __future__ import annotations + +from typing import Any, Literal + +from pydantic import AwareDatetime, BaseModel, Field + +from .....k8s.apimachinery.pkg.apis.meta import v1 + + +class Cidr(BaseModel): + cidr: str | None = None + """ + (String) : + : + + A CIDR block (e.g., "10.1.2.0/24") or a prefix length (e.g., "/24"). + If prefix length is specified, the CIDR block will be auto-allocated + from the network's available space. + """ + maxMaskLength: float | None = None + """ + (Number) Maximum mask length for an allocation from this block. Defaults to /32 for IPv4. + Maximum mask length for an allocation from this block. Defaults to /32 for IPv4. + """ + state: str | None = None + """ + (String) : + : + + Controls provisioning of IP addresses from the CIDR block. Defaults to AVAILABLE. + + #### Supported values + + Controls provisioning of IP addresses from this pool to other pools + or allocations. Defaults to AVAILABLE. + Possible values: + + - `STATE_UNSPECIFIED` - Not used, mandated by the protocol. + - `AVAILABLE` - Default state. Provision of the IP addresses from this CIDR block is allowed. + - `DISABLED` - Provision of the IP addresses from this CIDR block is denied. + """ + + +class Pool(BaseModel): + cidrs: list[Cidr] | None = None + """ + instead. + """ + + +class Ipv4PrivatePools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) : + """ + useNetworkPools: bool | None = None + """ + is true. (see below for nested schema) + : + + If true, inherit private IPv4 pools from the network. Defaults to true. + Must be false if `pools` is specified. + """ + + +class Ipv4PublicPools(BaseModel): + pools: list[Pool] | None = None + """ + (Attributes List) : + """ + useNetworkPools: bool | None = None + """ + is true. (see below for nested schema) + : + + If true, inherit public IPv4 pools from the network. + Must be false if `pools` is specified. + """ + + +class Policy(BaseModel): + resolution: Literal['Required', 'Optional'] | None = 'Required' + """ + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + """ + resolve: Literal['Always', 'IfNotPresent'] | None = None + """ + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + """ + + +class NetworkIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class NetworkIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class RouteTableIdRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class RouteTableIdSelector(BaseModel): + matchControllerRef: bool | None = None + """ + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + """ + matchLabels: dict[str, str] | None = None + """ + MatchLabels ensures an object with matching labels is selected. + """ + policy: Policy | None = None + """ + Policies for selection. + """ + + +class ForProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the network this subnet belongs to. + ID of the network this subnet belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + routeTableId: str | None = None + """ + (String) : + : + + ID of the route table to associate with the subnet. + If unspecified, the network's default route table is used. + """ + routeTableIdRef: RouteTableIdRef | None = None + """ + Reference to a RouteTable in vpc to populate routeTableId. + """ + routeTableIdSelector: RouteTableIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate routeTableId. + """ + + +class InitProvider(BaseModel): + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the network this subnet belongs to. + ID of the network this subnet belongs to. + """ + networkIdRef: NetworkIdRef | None = None + """ + Reference to a Network in vpc to populate networkId. + """ + networkIdSelector: NetworkIdSelector | None = None + """ + Selector for a Network in vpc to populate networkId. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + routeTableId: str | None = None + """ + (String) : + : + + ID of the route table to associate with the subnet. + If unspecified, the network's default route table is used. + """ + routeTableIdRef: RouteTableIdRef | None = None + """ + Reference to a RouteTable in vpc to populate routeTableId. + """ + routeTableIdSelector: RouteTableIdSelector | None = None + """ + Selector for a RouteTable in vpc to populate routeTableId. + """ + + +class ProviderConfigRef(BaseModel): + name: str + """ + Name of the referenced object. + """ + policy: Policy | None = None + """ + Policies for referencing. + """ + + +class WriteConnectionSecretToRef(BaseModel): + name: str + """ + Name of the secret. + """ + namespace: str + """ + Namespace of the secret. + """ + + +class Spec(BaseModel): + deletionPolicy: Literal['Orphan', 'Delete'] | None = 'Delete' + """ + DeletionPolicy specifies what will happen to the underlying external + when this managed resource is deleted - either "Delete" or "Orphan" the + external resource. + This field is planned to be deprecated in favor of the ManagementPolicies + field in a future release. Currently, both could be set independently and + non-default values would be honored if the feature flag is enabled. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + """ + forProvider: ForProvider + initProvider: InitProvider | None = None + """ + THIS IS A BETA FIELD. It will be honored + unless the Management Policies feature flag is disabled. + InitProvider holds the same fields as ForProvider, with the exception + of Identifier and other resource reference fields. The fields that are + in InitProvider are merged into ForProvider when the resource is created. + The same fields are also added to the terraform ignore_changes hook, to + avoid updating them after creation. This is useful for fields that are + required on creation, but we do not desire to update them after creation, + for example because of an external controller is managing them, like an + autoscaler. + """ + managementPolicies: ( + list[Literal['Observe', 'Create', 'Update', 'Delete', 'LateInitialize', '*']] + | None + ) = ['*'] + """ + THIS IS A BETA FIELD. It is on by default but can be opted out + through a Crossplane feature flag. + ManagementPolicies specify the array of actions Crossplane is allowed to + take on the managed and external resources. + This field is planned to replace the DeletionPolicy field in a future + release. Currently, both could be set independently and non-default + values would be honored if the feature flag is enabled. If both are + custom, the DeletionPolicy field will be ignored. + See the design doc for more information: https://github.com/crossplane/crossplane/blob/499895a25d1a1a0ba1604944ef98ac7a1a71f197/design/design-doc-observe-only-resources.md?plain=1#L223 + and this one: https://github.com/crossplane/crossplane/blob/444267e84783136daa93568b364a5f01228cacbe/design/one-pager-ignore-changes.md + """ + providerConfigRef: ProviderConfigRef | None = Field( + {'name': 'default'}, validate_default=True + ) + """ + ProviderConfigReference specifies how the provider that will be used to + create, observe, update, and delete this managed resource should be + configured. + """ + writeConnectionSecretToRef: WriteConnectionSecretToRef | None = None + """ + WriteConnectionSecretToReference specifies the namespace and name of a + Secret to which any connection details for this managed resource should + be written. Connection details frequently include the endpoint, username, + and password required to connect to the managed resource. + """ + + +class Ipv4PrivatePool(BaseModel): + cidrs: list[str] | None = None + """ + instead. + CIDR blocks sourced from this pool. + """ + poolId: str | None = None + """ + (String) ID of the pool available for allocations in this subnet. + ID of the pool available for allocations in this subnet. + """ + + +class Ipv4PublicPool(BaseModel): + cidrs: list[str] | None = None + """ + instead. + CIDR blocks sourced from this pool. + """ + poolId: str | None = None + """ + (String) ID of the pool available for allocations in this subnet. + ID of the pool available for allocations in this subnet. + """ + + +class RouteTable(BaseModel): + default: bool | None = None + """ + (Boolean) : + : + + Indicates whether this is the network's default route table. + If true, this is the default route table inherited from the network. + If false, this is a custom route table explicitly associated with the subnet via spec. + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + ID of the route table. + """ + + +class Status(BaseModel): + ipv4PrivateCidrs: list[str] | None = None + """ + (List of String, Deprecated) : + : + + CIDR blocks. + Deprecated: Use `ipv4_private_pools.cidrs` instead. + """ + ipv4PrivatePools: list[Ipv4PrivatePool] | None = None + """ + (Attributes) : + """ + ipv4PublicCidrs: list[str] | None = None + """ + (List of String, Deprecated) : + : + + CIDR blocks. + Deprecated: Use `ipv4_public_pools.cidrs` instead. + """ + ipv4PublicPools: list[Ipv4PublicPool] | None = None + """ + (Attributes) : + """ + routeTable: RouteTable | None = None + """ + (Attributes) : + """ + state: str | None = None + """ + (String) : + : + + Current state of the subnet. + + #### Supported values + + Enumeration of possible states of the subnet. + Possible values: + + - `STATE_UNSPECIFIED` - Default state, unspecified. + - `CREATING` - Subnet is being created. + - `READY` - Subnet is ready for use. + - `DELETING` - Subnet is being deleted. + """ + + +class AtProvider(BaseModel): + createdAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was created. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + id: str | None = None + """ + (String) Identifier for the resource, unique for its resource type. + """ + ipv4PrivatePools: Ipv4PrivatePools | None = None + """ + (Attributes) : + """ + ipv4PublicPools: Ipv4PublicPools | None = None + """ + (Attributes) : + """ + labels: dict[str, str] | None = None + """ + (Map of String) Labels associated with the resource. + Labels associated with the resource. + """ + metadata: dict[str, Any] | None = None + """ + (Attributes) : + """ + name: str | None = None + """ + (String) Human readable name for the resource. + Human readable name for the resource. + """ + networkId: str | None = None + """ + (String) ID of the network this subnet belongs to. + ID of the network this subnet belongs to. + """ + parentId: str | None = None + """ + (String) Identifier of the parent resource to which the resource belongs. + Identifier of the parent resource to which the resource belongs. + """ + resourceVersion: float | None = None + """ + (Number) : + : + + Version of the resource for safe concurrent modifications and consistent reads. + Positive and monotonically increases on each resource spec change (but *not* on each change of the + resource's container(s) or status). + Service allows zero value or current. + """ + routeTableId: str | None = None + """ + (String) : + : + + ID of the route table to associate with the subnet. + If unspecified, the network's default route table is used. + """ + status: Status | None = None + """ + (Attributes) Status of the subnet. (see below for nested schema) + """ + updatedAt: str | None = None + """ + (String) : + : + + Timestamp indicating when the resource was last updated. + + A string representing a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ` or `YYYY-MM-DDTHH:MM:SS.SSS±HH:MM` + """ + + +class Condition(BaseModel): + lastTransitionTime: AwareDatetime + """ + LastTransitionTime is the last time this condition transitioned from one + status to another. + """ + message: str | None = None + """ + A Message containing details about this condition's last transition from + one status to another, if any. + """ + observedGeneration: int | None = None + """ + ObservedGeneration represents the .metadata.generation that the condition was set based upon. + For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date + with respect to the current state of the instance. + """ + reason: str + """ + A Reason for this condition's last transition from one status to another. + """ + status: str + """ + Status of this condition; is it currently True, False, or Unknown? + """ + type: str + """ + Type of this condition. At most one of each condition type may apply to + a resource at any point in time. + """ + + +class StatusModel(BaseModel): + atProvider: AtProvider | None = None + conditions: list[Condition] | None = None + """ + Conditions of the resource. + """ + observedGeneration: int | None = None + """ + ObservedGeneration is the latest metadata.generation + which resulted in either a ready state, or stalled due to error + it can not recover from without human intervention. + """ + + +class Subnet(BaseModel): + apiVersion: Literal['vpc.nebius.upbound.io/v1beta1'] | None = ( + 'vpc.nebius.upbound.io/v1beta1' + ) + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + kind: Literal['Subnet'] | None = 'Subnet' + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ObjectMeta | None = None + """ + Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + """ + spec: Spec + """ + SubnetSpec defines the desired state of Subnet + """ + status: StatusModel | None = None + """ + SubnetStatus defines the observed state of Subnet. + """ + + +class SubnetList(BaseModel): + apiVersion: str | None = None + """ + APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources + """ + items: list[Subnet] + """ + List of subnets. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md + """ + kind: str | None = None + """ + Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ + metadata: v1.ListMeta | None = None + """ + Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds + """ \ No newline at end of file diff --git a/uv.lock b/uv.lock index 383f8870c..7c63b5233 100644 --- a/uv.lock +++ b/uv.lock @@ -18,6 +18,7 @@ members = [ "compose-model-endpoint", "compose-model-replica", "compose-model-service", + "compose-nebius-cluster", "compose-serving-stack", "compose-usages", "crossplane-models", @@ -264,6 +265,25 @@ requires-dist = [ { name = "grpcio", specifier = ">=1.73.1" }, ] +[[package]] +name = "compose-nebius-cluster" +version = "0.0.0" +source = { editable = "functions/compose-nebius-cluster" } +dependencies = [ + { name = "click" }, + { name = "crossplane-function-sdk-python" }, + { name = "crossplane-models" }, + { name = "grpcio" }, +] + +[package.metadata] +requires-dist = [ + { name = "click", specifier = ">=8.1.0" }, + { name = "crossplane-function-sdk-python", specifier = ">=0.14.0" }, + { name = "crossplane-models", editable = "schemas/python" }, + { name = "grpcio", specifier = ">=1.73.1" }, +] + [[package]] name = "compose-serving-stack" version = "0.0.0"