pulumi-dnsimple 3.5.0a1721425071__py3-none-any.whl → 4.0.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of pulumi-dnsimple might be problematic. Click here for more details.

@@ -0,0 +1,258 @@
1
+ # coding=utf-8
2
+ # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
3
+ # *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+
5
+ import copy
6
+ import warnings
7
+ import pulumi
8
+ import pulumi.runtime
9
+ from typing import Any, Mapping, Optional, Sequence, Union, overload
10
+ from . import _utilities
11
+
12
+ __all__ = ['DomainDelegationArgs', 'DomainDelegation']
13
+
14
+ @pulumi.input_type
15
+ class DomainDelegationArgs:
16
+ def __init__(__self__, *,
17
+ domain: pulumi.Input[str],
18
+ name_servers: pulumi.Input[Sequence[pulumi.Input[str]]]):
19
+ """
20
+ The set of arguments for constructing a DomainDelegation resource.
21
+ :param pulumi.Input[str] domain: The domain name.
22
+ :param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
23
+
24
+ # Attributes Reference
25
+ """
26
+ pulumi.set(__self__, "domain", domain)
27
+ pulumi.set(__self__, "name_servers", name_servers)
28
+
29
+ @property
30
+ @pulumi.getter
31
+ def domain(self) -> pulumi.Input[str]:
32
+ """
33
+ The domain name.
34
+ """
35
+ return pulumi.get(self, "domain")
36
+
37
+ @domain.setter
38
+ def domain(self, value: pulumi.Input[str]):
39
+ pulumi.set(self, "domain", value)
40
+
41
+ @property
42
+ @pulumi.getter(name="nameServers")
43
+ def name_servers(self) -> pulumi.Input[Sequence[pulumi.Input[str]]]:
44
+ """
45
+ The list of name servers to delegate to.
46
+
47
+ # Attributes Reference
48
+ """
49
+ return pulumi.get(self, "name_servers")
50
+
51
+ @name_servers.setter
52
+ def name_servers(self, value: pulumi.Input[Sequence[pulumi.Input[str]]]):
53
+ pulumi.set(self, "name_servers", value)
54
+
55
+
56
+ @pulumi.input_type
57
+ class _DomainDelegationState:
58
+ def __init__(__self__, *,
59
+ domain: Optional[pulumi.Input[str]] = None,
60
+ name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None):
61
+ """
62
+ Input properties used for looking up and filtering DomainDelegation resources.
63
+ :param pulumi.Input[str] domain: The domain name.
64
+ :param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
65
+
66
+ # Attributes Reference
67
+ """
68
+ if domain is not None:
69
+ pulumi.set(__self__, "domain", domain)
70
+ if name_servers is not None:
71
+ pulumi.set(__self__, "name_servers", name_servers)
72
+
73
+ @property
74
+ @pulumi.getter
75
+ def domain(self) -> Optional[pulumi.Input[str]]:
76
+ """
77
+ The domain name.
78
+ """
79
+ return pulumi.get(self, "domain")
80
+
81
+ @domain.setter
82
+ def domain(self, value: Optional[pulumi.Input[str]]):
83
+ pulumi.set(self, "domain", value)
84
+
85
+ @property
86
+ @pulumi.getter(name="nameServers")
87
+ def name_servers(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
88
+ """
89
+ The list of name servers to delegate to.
90
+
91
+ # Attributes Reference
92
+ """
93
+ return pulumi.get(self, "name_servers")
94
+
95
+ @name_servers.setter
96
+ def name_servers(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
97
+ pulumi.set(self, "name_servers", value)
98
+
99
+
100
+ class DomainDelegation(pulumi.CustomResource):
101
+ @overload
102
+ def __init__(__self__,
103
+ resource_name: str,
104
+ opts: Optional[pulumi.ResourceOptions] = None,
105
+ domain: Optional[pulumi.Input[str]] = None,
106
+ name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
107
+ __props__=None):
108
+ """
109
+ ## Example Usage
110
+
111
+ ```python
112
+ import pulumi
113
+ import pulumi_dnsimple as dnsimple
114
+
115
+ # Create a domain delegation
116
+ foobar = dnsimple.DomainDelegation("foobar",
117
+ domain=dnsimple["domain"],
118
+ name_servers=[
119
+ "ns1.example.org",
120
+ "ns2.example.com",
121
+ ])
122
+ ```
123
+
124
+ ## Import
125
+
126
+ DNSimple domain delegations can be imported using the domain name.
127
+
128
+ **Importing domain delegation for example.com**
129
+
130
+ bash
131
+
132
+ ```sh
133
+ $ pulumi import dnsimple:index/domainDelegation:DomainDelegation resource_name example.com
134
+ ```
135
+
136
+ :param str resource_name: The name of the resource.
137
+ :param pulumi.ResourceOptions opts: Options for the resource.
138
+ :param pulumi.Input[str] domain: The domain name.
139
+ :param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
140
+
141
+ # Attributes Reference
142
+ """
143
+ ...
144
+ @overload
145
+ def __init__(__self__,
146
+ resource_name: str,
147
+ args: DomainDelegationArgs,
148
+ opts: Optional[pulumi.ResourceOptions] = None):
149
+ """
150
+ ## Example Usage
151
+
152
+ ```python
153
+ import pulumi
154
+ import pulumi_dnsimple as dnsimple
155
+
156
+ # Create a domain delegation
157
+ foobar = dnsimple.DomainDelegation("foobar",
158
+ domain=dnsimple["domain"],
159
+ name_servers=[
160
+ "ns1.example.org",
161
+ "ns2.example.com",
162
+ ])
163
+ ```
164
+
165
+ ## Import
166
+
167
+ DNSimple domain delegations can be imported using the domain name.
168
+
169
+ **Importing domain delegation for example.com**
170
+
171
+ bash
172
+
173
+ ```sh
174
+ $ pulumi import dnsimple:index/domainDelegation:DomainDelegation resource_name example.com
175
+ ```
176
+
177
+ :param str resource_name: The name of the resource.
178
+ :param DomainDelegationArgs args: The arguments to use to populate this resource's properties.
179
+ :param pulumi.ResourceOptions opts: Options for the resource.
180
+ """
181
+ ...
182
+ def __init__(__self__, resource_name: str, *args, **kwargs):
183
+ resource_args, opts = _utilities.get_resource_args_opts(DomainDelegationArgs, pulumi.ResourceOptions, *args, **kwargs)
184
+ if resource_args is not None:
185
+ __self__._internal_init(resource_name, opts, **resource_args.__dict__)
186
+ else:
187
+ __self__._internal_init(resource_name, *args, **kwargs)
188
+
189
+ def _internal_init(__self__,
190
+ resource_name: str,
191
+ opts: Optional[pulumi.ResourceOptions] = None,
192
+ domain: Optional[pulumi.Input[str]] = None,
193
+ name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
194
+ __props__=None):
195
+ opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
196
+ if not isinstance(opts, pulumi.ResourceOptions):
197
+ raise TypeError('Expected resource options to be a ResourceOptions instance')
198
+ if opts.id is None:
199
+ if __props__ is not None:
200
+ raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
201
+ __props__ = DomainDelegationArgs.__new__(DomainDelegationArgs)
202
+
203
+ if domain is None and not opts.urn:
204
+ raise TypeError("Missing required property 'domain'")
205
+ __props__.__dict__["domain"] = domain
206
+ if name_servers is None and not opts.urn:
207
+ raise TypeError("Missing required property 'name_servers'")
208
+ __props__.__dict__["name_servers"] = name_servers
209
+ super(DomainDelegation, __self__).__init__(
210
+ 'dnsimple:index/domainDelegation:DomainDelegation',
211
+ resource_name,
212
+ __props__,
213
+ opts)
214
+
215
+ @staticmethod
216
+ def get(resource_name: str,
217
+ id: pulumi.Input[str],
218
+ opts: Optional[pulumi.ResourceOptions] = None,
219
+ domain: Optional[pulumi.Input[str]] = None,
220
+ name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None) -> 'DomainDelegation':
221
+ """
222
+ Get an existing DomainDelegation resource's state with the given name, id, and optional extra
223
+ properties used to qualify the lookup.
224
+
225
+ :param str resource_name: The unique name of the resulting resource.
226
+ :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
227
+ :param pulumi.ResourceOptions opts: Options for the resource.
228
+ :param pulumi.Input[str] domain: The domain name.
229
+ :param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
230
+
231
+ # Attributes Reference
232
+ """
233
+ opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
234
+
235
+ __props__ = _DomainDelegationState.__new__(_DomainDelegationState)
236
+
237
+ __props__.__dict__["domain"] = domain
238
+ __props__.__dict__["name_servers"] = name_servers
239
+ return DomainDelegation(resource_name, opts=opts, __props__=__props__)
240
+
241
+ @property
242
+ @pulumi.getter
243
+ def domain(self) -> pulumi.Output[str]:
244
+ """
245
+ The domain name.
246
+ """
247
+ return pulumi.get(self, "domain")
248
+
249
+ @property
250
+ @pulumi.getter(name="nameServers")
251
+ def name_servers(self) -> pulumi.Output[Sequence[str]]:
252
+ """
253
+ The list of name servers to delegate to.
254
+
255
+ # Attributes Reference
256
+ """
257
+ return pulumi.get(self, "name_servers")
258
+