/
VolumeAttachment.ts
executable file
·105 lines (92 loc) · 4.51 KB
/
VolumeAttachment.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
// *** WARNING: this file was generated by the Pulumi Kubernetes codegen tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
import * as pulumi from "@pulumi/pulumi";
import * as inputApi from "../../types/input";
import * as outputApi from "../../types/output";
import { getVersion } from "../../version";
/**
* VolumeAttachment captures the intent to attach or detach the specified volume to/from the
* specified node.
*
* VolumeAttachment objects are non-namespaced.
*/
export class VolumeAttachment extends pulumi.CustomResource {
/**
* 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/api-conventions.md#resources
*/
public readonly apiVersion: pulumi.Output<"storage.k8s.io/v1alpha1">;
/**
* 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/api-conventions.md#types-kinds
*/
public readonly kind: pulumi.Output<"VolumeAttachment">;
/**
* Standard object metadata. More info:
* https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata
*/
public readonly metadata: pulumi.Output<outputApi.meta.v1.ObjectMeta>;
/**
* Specification of the desired attach/detach volume behavior. Populated by the Kubernetes
* system.
*/
public readonly spec: pulumi.Output<outputApi.storage.v1alpha1.VolumeAttachmentSpec>;
/**
* Status of the VolumeAttachment request. Populated by the entity completing the attach or
* detach operation, i.e. the external-attacher.
*/
public readonly status: pulumi.Output<outputApi.storage.v1alpha1.VolumeAttachmentStatus>;
/**
* Get the state of an existing `VolumeAttachment` resource, as identified by `id`.
* Typically this ID is of the form <namespace>/<name>; if <namespace> is omitted, then (per
* Kubernetes convention) the ID becomes default/<name>.
*
* Pulumi will keep track of this resource using `name` as the Pulumi ID.
*
* @param name _Unique_ name used to register this resource with Pulumi.
* @param id An ID for the Kubernetes resource to retrieve. Takes the form
* <namespace>/<name> or <name>.
* @param opts Uniquely specifies a CustomResource to select.
*/
public static get(name: string, id: pulumi.Input<pulumi.ID>, opts?: pulumi.CustomResourceOptions): VolumeAttachment {
return new VolumeAttachment(name, undefined, { ...opts, id: id });
}
/** @internal */
private static readonly __pulumiType = "kubernetes:storage.k8s.io/v1alpha1:VolumeAttachment";
/**
* Returns true if the given object is an instance of VolumeAttachment. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
public static isInstance(obj: any): obj is VolumeAttachment {
if (obj === undefined || obj === null) {
return false;
}
return obj["__pulumiType"] === VolumeAttachment.__pulumiType;
}
/**
* Create a storage.v1alpha1.VolumeAttachment resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args?: inputApi.storage.v1alpha1.VolumeAttachment, opts?: pulumi.CustomResourceOptions) {
let inputs: pulumi.Inputs = {};
inputs["apiVersion"] = "storage.k8s.io/v1alpha1";
inputs["kind"] = "VolumeAttachment";
inputs["metadata"] = args && args.metadata || undefined;
inputs["spec"] = args && args.spec || undefined;
inputs["status"] = args && args.status || undefined;
if (!opts) {
opts = {};
}
if (!opts.version) {
opts.version = getVersion();
}
super(VolumeAttachment.__pulumiType, name, inputs, opts);
}
}