pulumi-dnsimple 3.5.0a1710156168__py3-none-any.whl → 4.3.0a1736849266__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.
- pulumi_dnsimple/__init__.py +43 -3
- pulumi_dnsimple/_enums.py +31 -0
- pulumi_dnsimple/_inputs.py +378 -0
- pulumi_dnsimple/_utilities.py +41 -5
- pulumi_dnsimple/config/__init__.pyi +5 -0
- pulumi_dnsimple/config/vars.py +5 -0
- pulumi_dnsimple/contact.py +1204 -0
- pulumi_dnsimple/domain.py +79 -8
- pulumi_dnsimple/domain_delegation.py +263 -0
- pulumi_dnsimple/ds_record.py +601 -0
- pulumi_dnsimple/email_forward.py +51 -28
- pulumi_dnsimple/get_certificate.py +50 -26
- pulumi_dnsimple/get_registrant_change_check.py +172 -0
- pulumi_dnsimple/get_zone.py +21 -13
- pulumi_dnsimple/lets_encrypt_certificate.py +171 -105
- pulumi_dnsimple/outputs.py +321 -0
- pulumi_dnsimple/provider.py +29 -26
- pulumi_dnsimple/pulumi-plugin.json +2 -1
- pulumi_dnsimple/registered_domain.py +810 -0
- pulumi_dnsimple/zone.py +432 -0
- pulumi_dnsimple/zone_record.py +170 -76
- {pulumi_dnsimple-3.5.0a1710156168.dist-info → pulumi_dnsimple-4.3.0a1736849266.dist-info}/METADATA +9 -8
- pulumi_dnsimple-4.3.0a1736849266.dist-info/RECORD +27 -0
- {pulumi_dnsimple-3.5.0a1710156168.dist-info → pulumi_dnsimple-4.3.0a1736849266.dist-info}/WHEEL +1 -1
- pulumi_dnsimple/record.py +0 -353
- pulumi_dnsimple-3.5.0a1710156168.dist-info/RECORD +0 -19
- {pulumi_dnsimple-3.5.0a1710156168.dist-info → pulumi_dnsimple-4.3.0a1736849266.dist-info}/top_level.txt +0 -0
pulumi_dnsimple/domain.py
CHANGED
|
@@ -4,9 +4,14 @@
|
|
|
4
4
|
|
|
5
5
|
import copy
|
|
6
6
|
import warnings
|
|
7
|
+
import sys
|
|
7
8
|
import pulumi
|
|
8
9
|
import pulumi.runtime
|
|
9
10
|
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
10
15
|
from . import _utilities
|
|
11
16
|
|
|
12
17
|
__all__ = ['DomainArgs', 'Domain']
|
|
@@ -18,6 +23,8 @@ class DomainArgs:
|
|
|
18
23
|
"""
|
|
19
24
|
The set of arguments for constructing a Domain resource.
|
|
20
25
|
:param pulumi.Input[str] name: The domain name to be created
|
|
26
|
+
|
|
27
|
+
# Attributes Reference
|
|
21
28
|
"""
|
|
22
29
|
pulumi.set(__self__, "name", name)
|
|
23
30
|
|
|
@@ -26,6 +33,8 @@ class DomainArgs:
|
|
|
26
33
|
def name(self) -> pulumi.Input[str]:
|
|
27
34
|
"""
|
|
28
35
|
The domain name to be created
|
|
36
|
+
|
|
37
|
+
# Attributes Reference
|
|
29
38
|
"""
|
|
30
39
|
return pulumi.get(self, "name")
|
|
31
40
|
|
|
@@ -46,7 +55,15 @@ class _DomainState:
|
|
|
46
55
|
unicode_name: Optional[pulumi.Input[str]] = None):
|
|
47
56
|
"""
|
|
48
57
|
Input properties used for looking up and filtering Domain resources.
|
|
58
|
+
:param pulumi.Input[int] account_id: The account ID for the domain.
|
|
59
|
+
:param pulumi.Input[bool] auto_renew: Whether the domain is set to auto-renew.
|
|
49
60
|
:param pulumi.Input[str] name: The domain name to be created
|
|
61
|
+
|
|
62
|
+
# Attributes Reference
|
|
63
|
+
:param pulumi.Input[bool] private_whois: Whether the domain has WhoIs privacy enabled.
|
|
64
|
+
:param pulumi.Input[int] registrant_id: The ID of the registrant (contact) for the domain.
|
|
65
|
+
:param pulumi.Input[str] state: The state of the domain.
|
|
66
|
+
:param pulumi.Input[str] unicode_name: The domain name in Unicode format.
|
|
50
67
|
"""
|
|
51
68
|
if account_id is not None:
|
|
52
69
|
pulumi.set(__self__, "account_id", account_id)
|
|
@@ -66,6 +83,9 @@ class _DomainState:
|
|
|
66
83
|
@property
|
|
67
84
|
@pulumi.getter(name="accountId")
|
|
68
85
|
def account_id(self) -> Optional[pulumi.Input[int]]:
|
|
86
|
+
"""
|
|
87
|
+
The account ID for the domain.
|
|
88
|
+
"""
|
|
69
89
|
return pulumi.get(self, "account_id")
|
|
70
90
|
|
|
71
91
|
@account_id.setter
|
|
@@ -75,6 +95,9 @@ class _DomainState:
|
|
|
75
95
|
@property
|
|
76
96
|
@pulumi.getter(name="autoRenew")
|
|
77
97
|
def auto_renew(self) -> Optional[pulumi.Input[bool]]:
|
|
98
|
+
"""
|
|
99
|
+
Whether the domain is set to auto-renew.
|
|
100
|
+
"""
|
|
78
101
|
return pulumi.get(self, "auto_renew")
|
|
79
102
|
|
|
80
103
|
@auto_renew.setter
|
|
@@ -86,6 +109,8 @@ class _DomainState:
|
|
|
86
109
|
def name(self) -> Optional[pulumi.Input[str]]:
|
|
87
110
|
"""
|
|
88
111
|
The domain name to be created
|
|
112
|
+
|
|
113
|
+
# Attributes Reference
|
|
89
114
|
"""
|
|
90
115
|
return pulumi.get(self, "name")
|
|
91
116
|
|
|
@@ -96,6 +121,9 @@ class _DomainState:
|
|
|
96
121
|
@property
|
|
97
122
|
@pulumi.getter(name="privateWhois")
|
|
98
123
|
def private_whois(self) -> Optional[pulumi.Input[bool]]:
|
|
124
|
+
"""
|
|
125
|
+
Whether the domain has WhoIs privacy enabled.
|
|
126
|
+
"""
|
|
99
127
|
return pulumi.get(self, "private_whois")
|
|
100
128
|
|
|
101
129
|
@private_whois.setter
|
|
@@ -105,6 +133,9 @@ class _DomainState:
|
|
|
105
133
|
@property
|
|
106
134
|
@pulumi.getter(name="registrantId")
|
|
107
135
|
def registrant_id(self) -> Optional[pulumi.Input[int]]:
|
|
136
|
+
"""
|
|
137
|
+
The ID of the registrant (contact) for the domain.
|
|
138
|
+
"""
|
|
108
139
|
return pulumi.get(self, "registrant_id")
|
|
109
140
|
|
|
110
141
|
@registrant_id.setter
|
|
@@ -114,6 +145,9 @@ class _DomainState:
|
|
|
114
145
|
@property
|
|
115
146
|
@pulumi.getter
|
|
116
147
|
def state(self) -> Optional[pulumi.Input[str]]:
|
|
148
|
+
"""
|
|
149
|
+
The state of the domain.
|
|
150
|
+
"""
|
|
117
151
|
return pulumi.get(self, "state")
|
|
118
152
|
|
|
119
153
|
@state.setter
|
|
@@ -123,6 +157,9 @@ class _DomainState:
|
|
|
123
157
|
@property
|
|
124
158
|
@pulumi.getter(name="unicodeName")
|
|
125
159
|
def unicode_name(self) -> Optional[pulumi.Input[str]]:
|
|
160
|
+
"""
|
|
161
|
+
The domain name in Unicode format.
|
|
162
|
+
"""
|
|
126
163
|
return pulumi.get(self, "unicode_name")
|
|
127
164
|
|
|
128
165
|
@unicode_name.setter
|
|
@@ -142,27 +179,29 @@ class Domain(pulumi.CustomResource):
|
|
|
142
179
|
|
|
143
180
|
## Example Usage
|
|
144
181
|
|
|
145
|
-
<!--Start PulumiCodeChooser -->
|
|
146
182
|
```python
|
|
147
183
|
import pulumi
|
|
148
184
|
import pulumi_dnsimple as dnsimple
|
|
149
185
|
|
|
150
186
|
# Create a domain
|
|
151
|
-
foobar = dnsimple.Domain("foobar", name=
|
|
187
|
+
foobar = dnsimple.Domain("foobar", name=dnsimple["domain"])
|
|
152
188
|
```
|
|
153
|
-
<!--End PulumiCodeChooser -->
|
|
154
189
|
|
|
155
190
|
## Import
|
|
156
191
|
|
|
157
192
|
DNSimple domains can be imported using their numeric record ID.
|
|
158
193
|
|
|
194
|
+
bash
|
|
195
|
+
|
|
159
196
|
```sh
|
|
160
197
|
$ pulumi import dnsimple:index/domain:Domain resource_name 5678
|
|
161
198
|
```
|
|
162
199
|
|
|
163
200
|
The record ID can be found within [DNSimple Domains API](https://developer.dnsimple.com/v2/domains/#listDomains). Check out [Authentication](https://developer.dnsimple.com/v2/#authentication) in API Overview for available options.
|
|
164
201
|
|
|
165
|
-
|
|
202
|
+
bash
|
|
203
|
+
|
|
204
|
+
curl -u 'EMAIL:PASSWORD' https://api.dnsimple.com/v2/1234/domains?name_like=example.com | jq
|
|
166
205
|
|
|
167
206
|
{
|
|
168
207
|
|
|
@@ -215,6 +254,8 @@ class Domain(pulumi.CustomResource):
|
|
|
215
254
|
:param str resource_name: The name of the resource.
|
|
216
255
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
217
256
|
:param pulumi.Input[str] name: The domain name to be created
|
|
257
|
+
|
|
258
|
+
# Attributes Reference
|
|
218
259
|
"""
|
|
219
260
|
...
|
|
220
261
|
@overload
|
|
@@ -227,27 +268,29 @@ class Domain(pulumi.CustomResource):
|
|
|
227
268
|
|
|
228
269
|
## Example Usage
|
|
229
270
|
|
|
230
|
-
<!--Start PulumiCodeChooser -->
|
|
231
271
|
```python
|
|
232
272
|
import pulumi
|
|
233
273
|
import pulumi_dnsimple as dnsimple
|
|
234
274
|
|
|
235
275
|
# Create a domain
|
|
236
|
-
foobar = dnsimple.Domain("foobar", name=
|
|
276
|
+
foobar = dnsimple.Domain("foobar", name=dnsimple["domain"])
|
|
237
277
|
```
|
|
238
|
-
<!--End PulumiCodeChooser -->
|
|
239
278
|
|
|
240
279
|
## Import
|
|
241
280
|
|
|
242
281
|
DNSimple domains can be imported using their numeric record ID.
|
|
243
282
|
|
|
283
|
+
bash
|
|
284
|
+
|
|
244
285
|
```sh
|
|
245
286
|
$ pulumi import dnsimple:index/domain:Domain resource_name 5678
|
|
246
287
|
```
|
|
247
288
|
|
|
248
289
|
The record ID can be found within [DNSimple Domains API](https://developer.dnsimple.com/v2/domains/#listDomains). Check out [Authentication](https://developer.dnsimple.com/v2/#authentication) in API Overview for available options.
|
|
249
290
|
|
|
250
|
-
|
|
291
|
+
bash
|
|
292
|
+
|
|
293
|
+
curl -u 'EMAIL:PASSWORD' https://api.dnsimple.com/v2/1234/domains?name_like=example.com | jq
|
|
251
294
|
|
|
252
295
|
{
|
|
253
296
|
|
|
@@ -355,7 +398,15 @@ class Domain(pulumi.CustomResource):
|
|
|
355
398
|
:param str resource_name: The unique name of the resulting resource.
|
|
356
399
|
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
|
|
357
400
|
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
401
|
+
:param pulumi.Input[int] account_id: The account ID for the domain.
|
|
402
|
+
:param pulumi.Input[bool] auto_renew: Whether the domain is set to auto-renew.
|
|
358
403
|
:param pulumi.Input[str] name: The domain name to be created
|
|
404
|
+
|
|
405
|
+
# Attributes Reference
|
|
406
|
+
:param pulumi.Input[bool] private_whois: Whether the domain has WhoIs privacy enabled.
|
|
407
|
+
:param pulumi.Input[int] registrant_id: The ID of the registrant (contact) for the domain.
|
|
408
|
+
:param pulumi.Input[str] state: The state of the domain.
|
|
409
|
+
:param pulumi.Input[str] unicode_name: The domain name in Unicode format.
|
|
359
410
|
"""
|
|
360
411
|
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
|
361
412
|
|
|
@@ -373,11 +424,17 @@ class Domain(pulumi.CustomResource):
|
|
|
373
424
|
@property
|
|
374
425
|
@pulumi.getter(name="accountId")
|
|
375
426
|
def account_id(self) -> pulumi.Output[int]:
|
|
427
|
+
"""
|
|
428
|
+
The account ID for the domain.
|
|
429
|
+
"""
|
|
376
430
|
return pulumi.get(self, "account_id")
|
|
377
431
|
|
|
378
432
|
@property
|
|
379
433
|
@pulumi.getter(name="autoRenew")
|
|
380
434
|
def auto_renew(self) -> pulumi.Output[bool]:
|
|
435
|
+
"""
|
|
436
|
+
Whether the domain is set to auto-renew.
|
|
437
|
+
"""
|
|
381
438
|
return pulumi.get(self, "auto_renew")
|
|
382
439
|
|
|
383
440
|
@property
|
|
@@ -385,26 +442,40 @@ class Domain(pulumi.CustomResource):
|
|
|
385
442
|
def name(self) -> pulumi.Output[str]:
|
|
386
443
|
"""
|
|
387
444
|
The domain name to be created
|
|
445
|
+
|
|
446
|
+
# Attributes Reference
|
|
388
447
|
"""
|
|
389
448
|
return pulumi.get(self, "name")
|
|
390
449
|
|
|
391
450
|
@property
|
|
392
451
|
@pulumi.getter(name="privateWhois")
|
|
393
452
|
def private_whois(self) -> pulumi.Output[bool]:
|
|
453
|
+
"""
|
|
454
|
+
Whether the domain has WhoIs privacy enabled.
|
|
455
|
+
"""
|
|
394
456
|
return pulumi.get(self, "private_whois")
|
|
395
457
|
|
|
396
458
|
@property
|
|
397
459
|
@pulumi.getter(name="registrantId")
|
|
398
460
|
def registrant_id(self) -> pulumi.Output[int]:
|
|
461
|
+
"""
|
|
462
|
+
The ID of the registrant (contact) for the domain.
|
|
463
|
+
"""
|
|
399
464
|
return pulumi.get(self, "registrant_id")
|
|
400
465
|
|
|
401
466
|
@property
|
|
402
467
|
@pulumi.getter
|
|
403
468
|
def state(self) -> pulumi.Output[str]:
|
|
469
|
+
"""
|
|
470
|
+
The state of the domain.
|
|
471
|
+
"""
|
|
404
472
|
return pulumi.get(self, "state")
|
|
405
473
|
|
|
406
474
|
@property
|
|
407
475
|
@pulumi.getter(name="unicodeName")
|
|
408
476
|
def unicode_name(self) -> pulumi.Output[str]:
|
|
477
|
+
"""
|
|
478
|
+
The domain name in Unicode format.
|
|
479
|
+
"""
|
|
409
480
|
return pulumi.get(self, "unicode_name")
|
|
410
481
|
|
|
@@ -0,0 +1,263 @@
|
|
|
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 sys
|
|
8
|
+
import pulumi
|
|
9
|
+
import pulumi.runtime
|
|
10
|
+
from typing import Any, Mapping, Optional, Sequence, Union, overload
|
|
11
|
+
if sys.version_info >= (3, 11):
|
|
12
|
+
from typing import NotRequired, TypedDict, TypeAlias
|
|
13
|
+
else:
|
|
14
|
+
from typing_extensions import NotRequired, TypedDict, TypeAlias
|
|
15
|
+
from . import _utilities
|
|
16
|
+
|
|
17
|
+
__all__ = ['DomainDelegationArgs', 'DomainDelegation']
|
|
18
|
+
|
|
19
|
+
@pulumi.input_type
|
|
20
|
+
class DomainDelegationArgs:
|
|
21
|
+
def __init__(__self__, *,
|
|
22
|
+
domain: pulumi.Input[str],
|
|
23
|
+
name_servers: pulumi.Input[Sequence[pulumi.Input[str]]]):
|
|
24
|
+
"""
|
|
25
|
+
The set of arguments for constructing a DomainDelegation resource.
|
|
26
|
+
:param pulumi.Input[str] domain: The domain name.
|
|
27
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
|
|
28
|
+
|
|
29
|
+
# Attributes Reference
|
|
30
|
+
"""
|
|
31
|
+
pulumi.set(__self__, "domain", domain)
|
|
32
|
+
pulumi.set(__self__, "name_servers", name_servers)
|
|
33
|
+
|
|
34
|
+
@property
|
|
35
|
+
@pulumi.getter
|
|
36
|
+
def domain(self) -> pulumi.Input[str]:
|
|
37
|
+
"""
|
|
38
|
+
The domain name.
|
|
39
|
+
"""
|
|
40
|
+
return pulumi.get(self, "domain")
|
|
41
|
+
|
|
42
|
+
@domain.setter
|
|
43
|
+
def domain(self, value: pulumi.Input[str]):
|
|
44
|
+
pulumi.set(self, "domain", value)
|
|
45
|
+
|
|
46
|
+
@property
|
|
47
|
+
@pulumi.getter(name="nameServers")
|
|
48
|
+
def name_servers(self) -> pulumi.Input[Sequence[pulumi.Input[str]]]:
|
|
49
|
+
"""
|
|
50
|
+
The list of name servers to delegate to.
|
|
51
|
+
|
|
52
|
+
# Attributes Reference
|
|
53
|
+
"""
|
|
54
|
+
return pulumi.get(self, "name_servers")
|
|
55
|
+
|
|
56
|
+
@name_servers.setter
|
|
57
|
+
def name_servers(self, value: pulumi.Input[Sequence[pulumi.Input[str]]]):
|
|
58
|
+
pulumi.set(self, "name_servers", value)
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
@pulumi.input_type
|
|
62
|
+
class _DomainDelegationState:
|
|
63
|
+
def __init__(__self__, *,
|
|
64
|
+
domain: Optional[pulumi.Input[str]] = None,
|
|
65
|
+
name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None):
|
|
66
|
+
"""
|
|
67
|
+
Input properties used for looking up and filtering DomainDelegation resources.
|
|
68
|
+
:param pulumi.Input[str] domain: The domain name.
|
|
69
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
|
|
70
|
+
|
|
71
|
+
# Attributes Reference
|
|
72
|
+
"""
|
|
73
|
+
if domain is not None:
|
|
74
|
+
pulumi.set(__self__, "domain", domain)
|
|
75
|
+
if name_servers is not None:
|
|
76
|
+
pulumi.set(__self__, "name_servers", name_servers)
|
|
77
|
+
|
|
78
|
+
@property
|
|
79
|
+
@pulumi.getter
|
|
80
|
+
def domain(self) -> Optional[pulumi.Input[str]]:
|
|
81
|
+
"""
|
|
82
|
+
The domain name.
|
|
83
|
+
"""
|
|
84
|
+
return pulumi.get(self, "domain")
|
|
85
|
+
|
|
86
|
+
@domain.setter
|
|
87
|
+
def domain(self, value: Optional[pulumi.Input[str]]):
|
|
88
|
+
pulumi.set(self, "domain", value)
|
|
89
|
+
|
|
90
|
+
@property
|
|
91
|
+
@pulumi.getter(name="nameServers")
|
|
92
|
+
def name_servers(self) -> Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]:
|
|
93
|
+
"""
|
|
94
|
+
The list of name servers to delegate to.
|
|
95
|
+
|
|
96
|
+
# Attributes Reference
|
|
97
|
+
"""
|
|
98
|
+
return pulumi.get(self, "name_servers")
|
|
99
|
+
|
|
100
|
+
@name_servers.setter
|
|
101
|
+
def name_servers(self, value: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]]):
|
|
102
|
+
pulumi.set(self, "name_servers", value)
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
class DomainDelegation(pulumi.CustomResource):
|
|
106
|
+
@overload
|
|
107
|
+
def __init__(__self__,
|
|
108
|
+
resource_name: str,
|
|
109
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
|
110
|
+
domain: Optional[pulumi.Input[str]] = None,
|
|
111
|
+
name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
112
|
+
__props__=None):
|
|
113
|
+
"""
|
|
114
|
+
## Example Usage
|
|
115
|
+
|
|
116
|
+
```python
|
|
117
|
+
import pulumi
|
|
118
|
+
import pulumi_dnsimple as dnsimple
|
|
119
|
+
|
|
120
|
+
# Create a domain delegation
|
|
121
|
+
foobar = dnsimple.DomainDelegation("foobar",
|
|
122
|
+
domain=dnsimple["domain"],
|
|
123
|
+
name_servers=[
|
|
124
|
+
"ns1.example.org",
|
|
125
|
+
"ns2.example.com",
|
|
126
|
+
])
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
## Import
|
|
130
|
+
|
|
131
|
+
DNSimple domain delegations can be imported using the domain name.
|
|
132
|
+
|
|
133
|
+
**Importing domain delegation for example.com**
|
|
134
|
+
|
|
135
|
+
bash
|
|
136
|
+
|
|
137
|
+
```sh
|
|
138
|
+
$ pulumi import dnsimple:index/domainDelegation:DomainDelegation resource_name example.com
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
:param str resource_name: The name of the resource.
|
|
142
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
143
|
+
:param pulumi.Input[str] domain: The domain name.
|
|
144
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
|
|
145
|
+
|
|
146
|
+
# Attributes Reference
|
|
147
|
+
"""
|
|
148
|
+
...
|
|
149
|
+
@overload
|
|
150
|
+
def __init__(__self__,
|
|
151
|
+
resource_name: str,
|
|
152
|
+
args: DomainDelegationArgs,
|
|
153
|
+
opts: Optional[pulumi.ResourceOptions] = None):
|
|
154
|
+
"""
|
|
155
|
+
## Example Usage
|
|
156
|
+
|
|
157
|
+
```python
|
|
158
|
+
import pulumi
|
|
159
|
+
import pulumi_dnsimple as dnsimple
|
|
160
|
+
|
|
161
|
+
# Create a domain delegation
|
|
162
|
+
foobar = dnsimple.DomainDelegation("foobar",
|
|
163
|
+
domain=dnsimple["domain"],
|
|
164
|
+
name_servers=[
|
|
165
|
+
"ns1.example.org",
|
|
166
|
+
"ns2.example.com",
|
|
167
|
+
])
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
## Import
|
|
171
|
+
|
|
172
|
+
DNSimple domain delegations can be imported using the domain name.
|
|
173
|
+
|
|
174
|
+
**Importing domain delegation for example.com**
|
|
175
|
+
|
|
176
|
+
bash
|
|
177
|
+
|
|
178
|
+
```sh
|
|
179
|
+
$ pulumi import dnsimple:index/domainDelegation:DomainDelegation resource_name example.com
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
:param str resource_name: The name of the resource.
|
|
183
|
+
:param DomainDelegationArgs args: The arguments to use to populate this resource's properties.
|
|
184
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
185
|
+
"""
|
|
186
|
+
...
|
|
187
|
+
def __init__(__self__, resource_name: str, *args, **kwargs):
|
|
188
|
+
resource_args, opts = _utilities.get_resource_args_opts(DomainDelegationArgs, pulumi.ResourceOptions, *args, **kwargs)
|
|
189
|
+
if resource_args is not None:
|
|
190
|
+
__self__._internal_init(resource_name, opts, **resource_args.__dict__)
|
|
191
|
+
else:
|
|
192
|
+
__self__._internal_init(resource_name, *args, **kwargs)
|
|
193
|
+
|
|
194
|
+
def _internal_init(__self__,
|
|
195
|
+
resource_name: str,
|
|
196
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
|
197
|
+
domain: Optional[pulumi.Input[str]] = None,
|
|
198
|
+
name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
|
|
199
|
+
__props__=None):
|
|
200
|
+
opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
|
|
201
|
+
if not isinstance(opts, pulumi.ResourceOptions):
|
|
202
|
+
raise TypeError('Expected resource options to be a ResourceOptions instance')
|
|
203
|
+
if opts.id is None:
|
|
204
|
+
if __props__ is not None:
|
|
205
|
+
raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
|
|
206
|
+
__props__ = DomainDelegationArgs.__new__(DomainDelegationArgs)
|
|
207
|
+
|
|
208
|
+
if domain is None and not opts.urn:
|
|
209
|
+
raise TypeError("Missing required property 'domain'")
|
|
210
|
+
__props__.__dict__["domain"] = domain
|
|
211
|
+
if name_servers is None and not opts.urn:
|
|
212
|
+
raise TypeError("Missing required property 'name_servers'")
|
|
213
|
+
__props__.__dict__["name_servers"] = name_servers
|
|
214
|
+
super(DomainDelegation, __self__).__init__(
|
|
215
|
+
'dnsimple:index/domainDelegation:DomainDelegation',
|
|
216
|
+
resource_name,
|
|
217
|
+
__props__,
|
|
218
|
+
opts)
|
|
219
|
+
|
|
220
|
+
@staticmethod
|
|
221
|
+
def get(resource_name: str,
|
|
222
|
+
id: pulumi.Input[str],
|
|
223
|
+
opts: Optional[pulumi.ResourceOptions] = None,
|
|
224
|
+
domain: Optional[pulumi.Input[str]] = None,
|
|
225
|
+
name_servers: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None) -> 'DomainDelegation':
|
|
226
|
+
"""
|
|
227
|
+
Get an existing DomainDelegation resource's state with the given name, id, and optional extra
|
|
228
|
+
properties used to qualify the lookup.
|
|
229
|
+
|
|
230
|
+
:param str resource_name: The unique name of the resulting resource.
|
|
231
|
+
:param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
|
|
232
|
+
:param pulumi.ResourceOptions opts: Options for the resource.
|
|
233
|
+
:param pulumi.Input[str] domain: The domain name.
|
|
234
|
+
:param pulumi.Input[Sequence[pulumi.Input[str]]] name_servers: The list of name servers to delegate to.
|
|
235
|
+
|
|
236
|
+
# Attributes Reference
|
|
237
|
+
"""
|
|
238
|
+
opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
|
|
239
|
+
|
|
240
|
+
__props__ = _DomainDelegationState.__new__(_DomainDelegationState)
|
|
241
|
+
|
|
242
|
+
__props__.__dict__["domain"] = domain
|
|
243
|
+
__props__.__dict__["name_servers"] = name_servers
|
|
244
|
+
return DomainDelegation(resource_name, opts=opts, __props__=__props__)
|
|
245
|
+
|
|
246
|
+
@property
|
|
247
|
+
@pulumi.getter
|
|
248
|
+
def domain(self) -> pulumi.Output[str]:
|
|
249
|
+
"""
|
|
250
|
+
The domain name.
|
|
251
|
+
"""
|
|
252
|
+
return pulumi.get(self, "domain")
|
|
253
|
+
|
|
254
|
+
@property
|
|
255
|
+
@pulumi.getter(name="nameServers")
|
|
256
|
+
def name_servers(self) -> pulumi.Output[Sequence[str]]:
|
|
257
|
+
"""
|
|
258
|
+
The list of name servers to delegate to.
|
|
259
|
+
|
|
260
|
+
# Attributes Reference
|
|
261
|
+
"""
|
|
262
|
+
return pulumi.get(self, "name_servers")
|
|
263
|
+
|