Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceDefinitionSpecArgs Maven / Gradle / Ivy
Go to download
A Pulumi package for creating and managing Kubernetes resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.kubernetes.apiextensions.v1beta1.inputs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceColumnDefinitionArgs;
import com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceConversionArgs;
import com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceDefinitionNamesArgs;
import com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceDefinitionVersionArgs;
import com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceSubresourcesArgs;
import com.pulumi.kubernetes.apiextensions.v1beta1.inputs.CustomResourceValidationArgs;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
/**
* CustomResourceDefinitionSpec describes how a user wants their resource to appear
*
*/
public final class CustomResourceDefinitionSpecArgs extends com.pulumi.resources.ResourceArgs {
public static final CustomResourceDefinitionSpecArgs Empty = new CustomResourceDefinitionSpecArgs();
/**
* additionalPrinterColumns specifies additional columns returned in Table output. See https://kubernetes.io/docs/reference/using-api/api-concepts/#receiving-resources-as-tables for details. If present, this field configures columns for all versions. Top-level and per-version columns are mutually exclusive. If no top-level or per-version columns are specified, a single column displaying the age of the custom resource is used.
*
*/
@Import(name="additionalPrinterColumns")
private @Nullable Output> additionalPrinterColumns;
/**
* @return additionalPrinterColumns specifies additional columns returned in Table output. See https://kubernetes.io/docs/reference/using-api/api-concepts/#receiving-resources-as-tables for details. If present, this field configures columns for all versions. Top-level and per-version columns are mutually exclusive. If no top-level or per-version columns are specified, a single column displaying the age of the custom resource is used.
*
*/
public Optional>> additionalPrinterColumns() {
return Optional.ofNullable(this.additionalPrinterColumns);
}
/**
* conversion defines conversion settings for the CRD.
*
*/
@Import(name="conversion")
private @Nullable Output conversion;
/**
* @return conversion defines conversion settings for the CRD.
*
*/
public Optional> conversion() {
return Optional.ofNullable(this.conversion);
}
/**
* group is the API group of the defined custom resource. The custom resources are served under `/apis/<group>/...`. Must match the name of the CustomResourceDefinition (in the form `<names.plural>.<group>`).
*
*/
@Import(name="group", required=true)
private Output group;
/**
* @return group is the API group of the defined custom resource. The custom resources are served under `/apis/<group>/...`. Must match the name of the CustomResourceDefinition (in the form `<names.plural>.<group>`).
*
*/
public Output group() {
return this.group;
}
/**
* names specify the resource and kind names for the custom resource.
*
*/
@Import(name="names", required=true)
private Output names;
/**
* @return names specify the resource and kind names for the custom resource.
*
*/
public Output names() {
return this.names;
}
/**
* preserveUnknownFields indicates that object fields which are not specified in the OpenAPI schema should be preserved when persisting to storage. apiVersion, kind, metadata and known fields inside metadata are always preserved. If false, schemas must be defined for all versions. Defaults to true in v1beta for backwards compatibility. Deprecated: will be required to be false in v1. Preservation of unknown fields can be specified in the validation schema using the `x-kubernetes-preserve-unknown-fields: true` extension. See https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#pruning-versus-preserving-unknown-fields for details.
*
*/
@Import(name="preserveUnknownFields")
private @Nullable Output preserveUnknownFields;
/**
* @return preserveUnknownFields indicates that object fields which are not specified in the OpenAPI schema should be preserved when persisting to storage. apiVersion, kind, metadata and known fields inside metadata are always preserved. If false, schemas must be defined for all versions. Defaults to true in v1beta for backwards compatibility. Deprecated: will be required to be false in v1. Preservation of unknown fields can be specified in the validation schema using the `x-kubernetes-preserve-unknown-fields: true` extension. See https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#pruning-versus-preserving-unknown-fields for details.
*
*/
public Optional> preserveUnknownFields() {
return Optional.ofNullable(this.preserveUnknownFields);
}
/**
* scope indicates whether the defined custom resource is cluster- or namespace-scoped. Allowed values are `Cluster` and `Namespaced`. Default is `Namespaced`.
*
*/
@Import(name="scope", required=true)
private Output scope;
/**
* @return scope indicates whether the defined custom resource is cluster- or namespace-scoped. Allowed values are `Cluster` and `Namespaced`. Default is `Namespaced`.
*
*/
public Output scope() {
return this.scope;
}
/**
* subresources specify what subresources the defined custom resource has. If present, this field configures subresources for all versions. Top-level and per-version subresources are mutually exclusive.
*
*/
@Import(name="subresources")
private @Nullable Output subresources;
/**
* @return subresources specify what subresources the defined custom resource has. If present, this field configures subresources for all versions. Top-level and per-version subresources are mutually exclusive.
*
*/
public Optional> subresources() {
return Optional.ofNullable(this.subresources);
}
/**
* validation describes the schema used for validation and pruning of the custom resource. If present, this validation schema is used to validate all versions. Top-level and per-version schemas are mutually exclusive.
*
*/
@Import(name="validation")
private @Nullable Output validation;
/**
* @return validation describes the schema used for validation and pruning of the custom resource. If present, this validation schema is used to validate all versions. Top-level and per-version schemas are mutually exclusive.
*
*/
public Optional> validation() {
return Optional.ofNullable(this.validation);
}
/**
* version is the API version of the defined custom resource. The custom resources are served under `/apis/<group>/<version>/...`. Must match the name of the first item in the `versions` list if `version` and `versions` are both specified. Optional if `versions` is specified. Deprecated: use `versions` instead.
*
*/
@Import(name="version")
private @Nullable Output version;
/**
* @return version is the API version of the defined custom resource. The custom resources are served under `/apis/<group>/<version>/...`. Must match the name of the first item in the `versions` list if `version` and `versions` are both specified. Optional if `versions` is specified. Deprecated: use `versions` instead.
*
*/
public Optional> version() {
return Optional.ofNullable(this.version);
}
/**
* versions is the list of all API versions of the defined custom resource. Optional if `version` is specified. The name of the first item in the `versions` list must match the `version` field if `version` and `versions` are both specified. Version names are used to compute the order in which served versions are listed in API discovery. If the version string is "kube-like", it will sort above non "kube-like" version strings, which are ordered lexicographically. "Kube-like" versions start with a "v", then are followed by a number (the major version), then optionally the string "alpha" or "beta" and another number (the minor version). These are sorted first by GA > beta > alpha (where GA is a version with no suffix such as beta or alpha), and then by comparing major version, then minor version. An example sorted list of versions: v10, v2, v1, v11beta2, v10beta3, v3beta1, v12alpha1, v11alpha2, foo1, foo10.
*
*/
@Import(name="versions")
private @Nullable Output> versions;
/**
* @return versions is the list of all API versions of the defined custom resource. Optional if `version` is specified. The name of the first item in the `versions` list must match the `version` field if `version` and `versions` are both specified. Version names are used to compute the order in which served versions are listed in API discovery. If the version string is "kube-like", it will sort above non "kube-like" version strings, which are ordered lexicographically. "Kube-like" versions start with a "v", then are followed by a number (the major version), then optionally the string "alpha" or "beta" and another number (the minor version). These are sorted first by GA > beta > alpha (where GA is a version with no suffix such as beta or alpha), and then by comparing major version, then minor version. An example sorted list of versions: v10, v2, v1, v11beta2, v10beta3, v3beta1, v12alpha1, v11alpha2, foo1, foo10.
*
*/
public Optional>> versions() {
return Optional.ofNullable(this.versions);
}
private CustomResourceDefinitionSpecArgs() {}
private CustomResourceDefinitionSpecArgs(CustomResourceDefinitionSpecArgs $) {
this.additionalPrinterColumns = $.additionalPrinterColumns;
this.conversion = $.conversion;
this.group = $.group;
this.names = $.names;
this.preserveUnknownFields = $.preserveUnknownFields;
this.scope = $.scope;
this.subresources = $.subresources;
this.validation = $.validation;
this.version = $.version;
this.versions = $.versions;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(CustomResourceDefinitionSpecArgs defaults) {
return new Builder(defaults);
}
public static final class Builder {
private CustomResourceDefinitionSpecArgs $;
public Builder() {
$ = new CustomResourceDefinitionSpecArgs();
}
public Builder(CustomResourceDefinitionSpecArgs defaults) {
$ = new CustomResourceDefinitionSpecArgs(Objects.requireNonNull(defaults));
}
/**
* @param additionalPrinterColumns additionalPrinterColumns specifies additional columns returned in Table output. See https://kubernetes.io/docs/reference/using-api/api-concepts/#receiving-resources-as-tables for details. If present, this field configures columns for all versions. Top-level and per-version columns are mutually exclusive. If no top-level or per-version columns are specified, a single column displaying the age of the custom resource is used.
*
* @return builder
*
*/
public Builder additionalPrinterColumns(@Nullable Output> additionalPrinterColumns) {
$.additionalPrinterColumns = additionalPrinterColumns;
return this;
}
/**
* @param additionalPrinterColumns additionalPrinterColumns specifies additional columns returned in Table output. See https://kubernetes.io/docs/reference/using-api/api-concepts/#receiving-resources-as-tables for details. If present, this field configures columns for all versions. Top-level and per-version columns are mutually exclusive. If no top-level or per-version columns are specified, a single column displaying the age of the custom resource is used.
*
* @return builder
*
*/
public Builder additionalPrinterColumns(List additionalPrinterColumns) {
return additionalPrinterColumns(Output.of(additionalPrinterColumns));
}
/**
* @param additionalPrinterColumns additionalPrinterColumns specifies additional columns returned in Table output. See https://kubernetes.io/docs/reference/using-api/api-concepts/#receiving-resources-as-tables for details. If present, this field configures columns for all versions. Top-level and per-version columns are mutually exclusive. If no top-level or per-version columns are specified, a single column displaying the age of the custom resource is used.
*
* @return builder
*
*/
public Builder additionalPrinterColumns(CustomResourceColumnDefinitionArgs... additionalPrinterColumns) {
return additionalPrinterColumns(List.of(additionalPrinterColumns));
}
/**
* @param conversion conversion defines conversion settings for the CRD.
*
* @return builder
*
*/
public Builder conversion(@Nullable Output conversion) {
$.conversion = conversion;
return this;
}
/**
* @param conversion conversion defines conversion settings for the CRD.
*
* @return builder
*
*/
public Builder conversion(CustomResourceConversionArgs conversion) {
return conversion(Output.of(conversion));
}
/**
* @param group group is the API group of the defined custom resource. The custom resources are served under `/apis/<group>/...`. Must match the name of the CustomResourceDefinition (in the form `<names.plural>.<group>`).
*
* @return builder
*
*/
public Builder group(Output group) {
$.group = group;
return this;
}
/**
* @param group group is the API group of the defined custom resource. The custom resources are served under `/apis/<group>/...`. Must match the name of the CustomResourceDefinition (in the form `<names.plural>.<group>`).
*
* @return builder
*
*/
public Builder group(String group) {
return group(Output.of(group));
}
/**
* @param names names specify the resource and kind names for the custom resource.
*
* @return builder
*
*/
public Builder names(Output names) {
$.names = names;
return this;
}
/**
* @param names names specify the resource and kind names for the custom resource.
*
* @return builder
*
*/
public Builder names(CustomResourceDefinitionNamesArgs names) {
return names(Output.of(names));
}
/**
* @param preserveUnknownFields preserveUnknownFields indicates that object fields which are not specified in the OpenAPI schema should be preserved when persisting to storage. apiVersion, kind, metadata and known fields inside metadata are always preserved. If false, schemas must be defined for all versions. Defaults to true in v1beta for backwards compatibility. Deprecated: will be required to be false in v1. Preservation of unknown fields can be specified in the validation schema using the `x-kubernetes-preserve-unknown-fields: true` extension. See https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#pruning-versus-preserving-unknown-fields for details.
*
* @return builder
*
*/
public Builder preserveUnknownFields(@Nullable Output preserveUnknownFields) {
$.preserveUnknownFields = preserveUnknownFields;
return this;
}
/**
* @param preserveUnknownFields preserveUnknownFields indicates that object fields which are not specified in the OpenAPI schema should be preserved when persisting to storage. apiVersion, kind, metadata and known fields inside metadata are always preserved. If false, schemas must be defined for all versions. Defaults to true in v1beta for backwards compatibility. Deprecated: will be required to be false in v1. Preservation of unknown fields can be specified in the validation schema using the `x-kubernetes-preserve-unknown-fields: true` extension. See https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#pruning-versus-preserving-unknown-fields for details.
*
* @return builder
*
*/
public Builder preserveUnknownFields(Boolean preserveUnknownFields) {
return preserveUnknownFields(Output.of(preserveUnknownFields));
}
/**
* @param scope scope indicates whether the defined custom resource is cluster- or namespace-scoped. Allowed values are `Cluster` and `Namespaced`. Default is `Namespaced`.
*
* @return builder
*
*/
public Builder scope(Output scope) {
$.scope = scope;
return this;
}
/**
* @param scope scope indicates whether the defined custom resource is cluster- or namespace-scoped. Allowed values are `Cluster` and `Namespaced`. Default is `Namespaced`.
*
* @return builder
*
*/
public Builder scope(String scope) {
return scope(Output.of(scope));
}
/**
* @param subresources subresources specify what subresources the defined custom resource has. If present, this field configures subresources for all versions. Top-level and per-version subresources are mutually exclusive.
*
* @return builder
*
*/
public Builder subresources(@Nullable Output subresources) {
$.subresources = subresources;
return this;
}
/**
* @param subresources subresources specify what subresources the defined custom resource has. If present, this field configures subresources for all versions. Top-level and per-version subresources are mutually exclusive.
*
* @return builder
*
*/
public Builder subresources(CustomResourceSubresourcesArgs subresources) {
return subresources(Output.of(subresources));
}
/**
* @param validation validation describes the schema used for validation and pruning of the custom resource. If present, this validation schema is used to validate all versions. Top-level and per-version schemas are mutually exclusive.
*
* @return builder
*
*/
public Builder validation(@Nullable Output validation) {
$.validation = validation;
return this;
}
/**
* @param validation validation describes the schema used for validation and pruning of the custom resource. If present, this validation schema is used to validate all versions. Top-level and per-version schemas are mutually exclusive.
*
* @return builder
*
*/
public Builder validation(CustomResourceValidationArgs validation) {
return validation(Output.of(validation));
}
/**
* @param version version is the API version of the defined custom resource. The custom resources are served under `/apis/<group>/<version>/...`. Must match the name of the first item in the `versions` list if `version` and `versions` are both specified. Optional if `versions` is specified. Deprecated: use `versions` instead.
*
* @return builder
*
*/
public Builder version(@Nullable Output version) {
$.version = version;
return this;
}
/**
* @param version version is the API version of the defined custom resource. The custom resources are served under `/apis/<group>/<version>/...`. Must match the name of the first item in the `versions` list if `version` and `versions` are both specified. Optional if `versions` is specified. Deprecated: use `versions` instead.
*
* @return builder
*
*/
public Builder version(String version) {
return version(Output.of(version));
}
/**
* @param versions versions is the list of all API versions of the defined custom resource. Optional if `version` is specified. The name of the first item in the `versions` list must match the `version` field if `version` and `versions` are both specified. Version names are used to compute the order in which served versions are listed in API discovery. If the version string is "kube-like", it will sort above non "kube-like" version strings, which are ordered lexicographically. "Kube-like" versions start with a "v", then are followed by a number (the major version), then optionally the string "alpha" or "beta" and another number (the minor version). These are sorted first by GA > beta > alpha (where GA is a version with no suffix such as beta or alpha), and then by comparing major version, then minor version. An example sorted list of versions: v10, v2, v1, v11beta2, v10beta3, v3beta1, v12alpha1, v11alpha2, foo1, foo10.
*
* @return builder
*
*/
public Builder versions(@Nullable Output> versions) {
$.versions = versions;
return this;
}
/**
* @param versions versions is the list of all API versions of the defined custom resource. Optional if `version` is specified. The name of the first item in the `versions` list must match the `version` field if `version` and `versions` are both specified. Version names are used to compute the order in which served versions are listed in API discovery. If the version string is "kube-like", it will sort above non "kube-like" version strings, which are ordered lexicographically. "Kube-like" versions start with a "v", then are followed by a number (the major version), then optionally the string "alpha" or "beta" and another number (the minor version). These are sorted first by GA > beta > alpha (where GA is a version with no suffix such as beta or alpha), and then by comparing major version, then minor version. An example sorted list of versions: v10, v2, v1, v11beta2, v10beta3, v3beta1, v12alpha1, v11alpha2, foo1, foo10.
*
* @return builder
*
*/
public Builder versions(List versions) {
return versions(Output.of(versions));
}
/**
* @param versions versions is the list of all API versions of the defined custom resource. Optional if `version` is specified. The name of the first item in the `versions` list must match the `version` field if `version` and `versions` are both specified. Version names are used to compute the order in which served versions are listed in API discovery. If the version string is "kube-like", it will sort above non "kube-like" version strings, which are ordered lexicographically. "Kube-like" versions start with a "v", then are followed by a number (the major version), then optionally the string "alpha" or "beta" and another number (the minor version). These are sorted first by GA > beta > alpha (where GA is a version with no suffix such as beta or alpha), and then by comparing major version, then minor version. An example sorted list of versions: v10, v2, v1, v11beta2, v10beta3, v3beta1, v12alpha1, v11alpha2, foo1, foo10.
*
* @return builder
*
*/
public Builder versions(CustomResourceDefinitionVersionArgs... versions) {
return versions(List.of(versions));
}
public CustomResourceDefinitionSpecArgs build() {
if ($.group == null) {
throw new MissingRequiredPropertyException("CustomResourceDefinitionSpecArgs", "group");
}
if ($.names == null) {
throw new MissingRequiredPropertyException("CustomResourceDefinitionSpecArgs", "names");
}
if ($.scope == null) {
throw new MissingRequiredPropertyException("CustomResourceDefinitionSpecArgs", "scope");
}
return $;
}
}
}