pulumi-render 0.1.1__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.
- pulumi_render/__init__.py +68 -0
- pulumi_render/_utilities.py +291 -0
- pulumi_render/config/__init__.py +8 -0
- pulumi_render/config/__init__.pyi +22 -0
- pulumi_render/config/vars.py +32 -0
- pulumi_render/owners/__init__.py +11 -0
- pulumi_render/owners/_enums.py +17 -0
- pulumi_render/owners/get_owner.py +67 -0
- pulumi_render/owners/list_owners.py +60 -0
- pulumi_render/owners/outputs.py +104 -0
- pulumi_render/provider.py +96 -0
- pulumi_render/pulumi-plugin.json +5 -0
- pulumi_render/py.typed +0 -0
- pulumi_render/registrycredentials/__init__.py +11 -0
- pulumi_render/registrycredentials/get_registry_credential.py +59 -0
- pulumi_render/registrycredentials/list_registry_credentials.py +59 -0
- pulumi_render/registrycredentials/outputs.py +90 -0
- pulumi_render/registrycredentials/registry_credential.py +193 -0
- pulumi_render/services/__init__.py +37 -0
- pulumi_render/services/_enums.py +227 -0
- pulumi_render/services/_inputs.py +1073 -0
- pulumi_render/services/auto_scaling.py +210 -0
- pulumi_render/services/background_worker.py +459 -0
- pulumi_render/services/cron_job.py +459 -0
- pulumi_render/services/custom_domains.py +173 -0
- pulumi_render/services/deploys.py +142 -0
- pulumi_render/services/env_vars.py +132 -0
- pulumi_render/services/get_background_worker.py +67 -0
- pulumi_render/services/get_cron_job.py +67 -0
- pulumi_render/services/get_custom_domain.py +72 -0
- pulumi_render/services/get_deploy.py +72 -0
- pulumi_render/services/get_job.py +71 -0
- pulumi_render/services/get_private_service.py +67 -0
- pulumi_render/services/get_static_site.py +67 -0
- pulumi_render/services/get_web_service.py +67 -0
- pulumi_render/services/jobs.py +180 -0
- pulumi_render/services/list_custom_domains.py +67 -0
- pulumi_render/services/list_deploys.py +67 -0
- pulumi_render/services/list_env_vars.py +67 -0
- pulumi_render/services/list_headers.py +66 -0
- pulumi_render/services/list_jobs.py +66 -0
- pulumi_render/services/list_routes.py +67 -0
- pulumi_render/services/list_services.py +60 -0
- pulumi_render/services/outputs.py +2889 -0
- pulumi_render/services/private_service.py +459 -0
- pulumi_render/services/scale.py +130 -0
- pulumi_render/services/static_site.py +463 -0
- pulumi_render/services/suspend.py +108 -0
- pulumi_render/services/web_service.py +459 -0
- pulumi_render-0.1.1.dist-info/METADATA +55 -0
- pulumi_render-0.1.1.dist-info/RECORD +53 -0
- pulumi_render-0.1.1.dist-info/WHEEL +5 -0
- pulumi_render-0.1.1.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
3
|
+
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
|
|
5
|
+
from . import _utilities
|
|
6
|
+
import typing
|
|
7
|
+
# Export this package's modules as members:
|
|
8
|
+
from .provider import *
|
|
9
|
+
|
|
10
|
+
# Make subpackages available:
|
|
11
|
+
if typing.TYPE_CHECKING:
|
|
12
|
+
import pulumi_render.config as __config
|
|
13
|
+
config = __config
|
|
14
|
+
import pulumi_render.owners as __owners
|
|
15
|
+
owners = __owners
|
|
16
|
+
import pulumi_render.registrycredentials as __registrycredentials
|
|
17
|
+
registrycredentials = __registrycredentials
|
|
18
|
+
import pulumi_render.services as __services
|
|
19
|
+
services = __services
|
|
20
|
+
else:
|
|
21
|
+
config = _utilities.lazy_import('pulumi_render.config')
|
|
22
|
+
owners = _utilities.lazy_import('pulumi_render.owners')
|
|
23
|
+
registrycredentials = _utilities.lazy_import('pulumi_render.registrycredentials')
|
|
24
|
+
services = _utilities.lazy_import('pulumi_render.services')
|
|
25
|
+
|
|
26
|
+
_utilities.register(
|
|
27
|
+
resource_modules="""
|
|
28
|
+
[
|
|
29
|
+
{
|
|
30
|
+
"pkg": "render",
|
|
31
|
+
"mod": "registrycredentials",
|
|
32
|
+
"fqn": "pulumi_render.registrycredentials",
|
|
33
|
+
"classes": {
|
|
34
|
+
"render:registrycredentials:RegistryCredential": "RegistryCredential"
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"pkg": "render",
|
|
39
|
+
"mod": "services",
|
|
40
|
+
"fqn": "pulumi_render.services",
|
|
41
|
+
"classes": {
|
|
42
|
+
"render:services:AutoScaling": "AutoScaling",
|
|
43
|
+
"render:services:BackgroundWorker": "BackgroundWorker",
|
|
44
|
+
"render:services:CronJob": "CronJob",
|
|
45
|
+
"render:services:CustomDomains": "CustomDomains",
|
|
46
|
+
"render:services:Deploys": "Deploys",
|
|
47
|
+
"render:services:EnvVars": "EnvVars",
|
|
48
|
+
"render:services:Jobs": "Jobs",
|
|
49
|
+
"render:services:PrivateService": "PrivateService",
|
|
50
|
+
"render:services:Scale": "Scale",
|
|
51
|
+
"render:services:StaticSite": "StaticSite",
|
|
52
|
+
"render:services:Suspend": "Suspend",
|
|
53
|
+
"render:services:WebService": "WebService"
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
]
|
|
57
|
+
""",
|
|
58
|
+
resource_packages="""
|
|
59
|
+
[
|
|
60
|
+
{
|
|
61
|
+
"pkg": "render",
|
|
62
|
+
"token": "pulumi:providers:render",
|
|
63
|
+
"fqn": "pulumi_render",
|
|
64
|
+
"class": "Provider"
|
|
65
|
+
}
|
|
66
|
+
]
|
|
67
|
+
"""
|
|
68
|
+
)
|
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
3
|
+
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
import asyncio
|
|
7
|
+
import importlib.metadata
|
|
8
|
+
import importlib.util
|
|
9
|
+
import inspect
|
|
10
|
+
import json
|
|
11
|
+
import os
|
|
12
|
+
import sys
|
|
13
|
+
import typing
|
|
14
|
+
|
|
15
|
+
import pulumi
|
|
16
|
+
import pulumi.runtime
|
|
17
|
+
from pulumi.runtime.sync_await import _sync_await
|
|
18
|
+
|
|
19
|
+
from semver import VersionInfo as SemverVersion
|
|
20
|
+
from parver import Version as PEP440Version
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
def get_env(*args):
|
|
24
|
+
for v in args:
|
|
25
|
+
value = os.getenv(v)
|
|
26
|
+
if value is not None:
|
|
27
|
+
return value
|
|
28
|
+
return None
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def get_env_bool(*args):
|
|
32
|
+
str = get_env(*args)
|
|
33
|
+
if str is not None:
|
|
34
|
+
# NOTE: these values are taken from https://golang.org/src/strconv/atob.go?s=351:391#L1, which is what
|
|
35
|
+
# Terraform uses internally when parsing boolean values.
|
|
36
|
+
if str in ["1", "t", "T", "true", "TRUE", "True"]:
|
|
37
|
+
return True
|
|
38
|
+
if str in ["0", "f", "F", "false", "FALSE", "False"]:
|
|
39
|
+
return False
|
|
40
|
+
return None
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def get_env_int(*args):
|
|
44
|
+
str = get_env(*args)
|
|
45
|
+
if str is not None:
|
|
46
|
+
try:
|
|
47
|
+
return int(str)
|
|
48
|
+
except:
|
|
49
|
+
return None
|
|
50
|
+
return None
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
def get_env_float(*args):
|
|
54
|
+
str = get_env(*args)
|
|
55
|
+
if str is not None:
|
|
56
|
+
try:
|
|
57
|
+
return float(str)
|
|
58
|
+
except:
|
|
59
|
+
return None
|
|
60
|
+
return None
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
def _get_semver_version():
|
|
64
|
+
# __name__ is set to the fully-qualified name of the current module, In our case, it will be
|
|
65
|
+
# <some module>._utilities. <some module> is the module we want to query the version for.
|
|
66
|
+
root_package, *rest = __name__.split('.')
|
|
67
|
+
|
|
68
|
+
# pkg_resources uses setuptools to inspect the set of installed packages. We use it here to ask
|
|
69
|
+
# for the currently installed version of the root package (i.e. us) and get its version.
|
|
70
|
+
|
|
71
|
+
# Unfortunately, PEP440 and semver differ slightly in incompatible ways. The Pulumi engine expects
|
|
72
|
+
# to receive a valid semver string when receiving requests from the language host, so it's our
|
|
73
|
+
# responsibility as the library to convert our own PEP440 version into a valid semver string.
|
|
74
|
+
|
|
75
|
+
pep440_version_string = importlib.metadata.version(root_package)
|
|
76
|
+
pep440_version = PEP440Version.parse(pep440_version_string)
|
|
77
|
+
(major, minor, patch) = pep440_version.release
|
|
78
|
+
prerelease = None
|
|
79
|
+
if pep440_version.pre_tag == 'a':
|
|
80
|
+
prerelease = f"alpha.{pep440_version.pre}"
|
|
81
|
+
elif pep440_version.pre_tag == 'b':
|
|
82
|
+
prerelease = f"beta.{pep440_version.pre}"
|
|
83
|
+
elif pep440_version.pre_tag == 'rc':
|
|
84
|
+
prerelease = f"rc.{pep440_version.pre}"
|
|
85
|
+
elif pep440_version.dev is not None:
|
|
86
|
+
prerelease = f"dev.{pep440_version.dev}"
|
|
87
|
+
|
|
88
|
+
# The only significant difference between PEP440 and semver as it pertains to us is that PEP440 has explicit support
|
|
89
|
+
# for dev builds, while semver encodes them as "prerelease" versions. In order to bridge between the two, we convert
|
|
90
|
+
# our dev build version into a prerelease tag. This matches what all of our other packages do when constructing
|
|
91
|
+
# their own semver string.
|
|
92
|
+
return SemverVersion(major=major, minor=minor, patch=patch, prerelease=prerelease)
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
# Determine the version once and cache the value, which measurably improves program performance.
|
|
96
|
+
_version = _get_semver_version()
|
|
97
|
+
_version_str = str(_version)
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
def get_version():
|
|
101
|
+
return _version_str
|
|
102
|
+
|
|
103
|
+
def get_resource_opts_defaults() -> pulumi.ResourceOptions:
|
|
104
|
+
return pulumi.ResourceOptions(
|
|
105
|
+
version=get_version(),
|
|
106
|
+
plugin_download_url=get_plugin_download_url(),
|
|
107
|
+
)
|
|
108
|
+
|
|
109
|
+
def get_invoke_opts_defaults() -> pulumi.InvokeOptions:
|
|
110
|
+
return pulumi.InvokeOptions(
|
|
111
|
+
version=get_version(),
|
|
112
|
+
plugin_download_url=get_plugin_download_url(),
|
|
113
|
+
)
|
|
114
|
+
|
|
115
|
+
def get_resource_args_opts(resource_args_type, resource_options_type, *args, **kwargs):
|
|
116
|
+
"""
|
|
117
|
+
Return the resource args and options given the *args and **kwargs of a resource's
|
|
118
|
+
__init__ method.
|
|
119
|
+
"""
|
|
120
|
+
|
|
121
|
+
resource_args, opts = None, None
|
|
122
|
+
|
|
123
|
+
# If the first item is the resource args type, save it and remove it from the args list.
|
|
124
|
+
if args and isinstance(args[0], resource_args_type):
|
|
125
|
+
resource_args, args = args[0], args[1:]
|
|
126
|
+
|
|
127
|
+
# Now look at the first item in the args list again.
|
|
128
|
+
# If the first item is the resource options class, save it.
|
|
129
|
+
if args and isinstance(args[0], resource_options_type):
|
|
130
|
+
opts = args[0]
|
|
131
|
+
|
|
132
|
+
# If resource_args is None, see if "args" is in kwargs, and, if so, if it's typed as the
|
|
133
|
+
# the resource args type.
|
|
134
|
+
if resource_args is None:
|
|
135
|
+
a = kwargs.get("args")
|
|
136
|
+
if isinstance(a, resource_args_type):
|
|
137
|
+
resource_args = a
|
|
138
|
+
|
|
139
|
+
# If opts is None, look it up in kwargs.
|
|
140
|
+
if opts is None:
|
|
141
|
+
opts = kwargs.get("opts")
|
|
142
|
+
|
|
143
|
+
return resource_args, opts
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
# Temporary: just use pulumi._utils.lazy_import once everyone upgrades.
|
|
147
|
+
def lazy_import(fullname):
|
|
148
|
+
|
|
149
|
+
import pulumi._utils as u
|
|
150
|
+
f = getattr(u, 'lazy_import', None)
|
|
151
|
+
if f is None:
|
|
152
|
+
f = _lazy_import_temp
|
|
153
|
+
|
|
154
|
+
return f(fullname)
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
# Copied from pulumi._utils.lazy_import, see comments there.
|
|
158
|
+
def _lazy_import_temp(fullname):
|
|
159
|
+
m = sys.modules.get(fullname, None)
|
|
160
|
+
if m is not None:
|
|
161
|
+
return m
|
|
162
|
+
|
|
163
|
+
spec = importlib.util.find_spec(fullname)
|
|
164
|
+
|
|
165
|
+
m = sys.modules.get(fullname, None)
|
|
166
|
+
if m is not None:
|
|
167
|
+
return m
|
|
168
|
+
|
|
169
|
+
loader = importlib.util.LazyLoader(spec.loader)
|
|
170
|
+
spec.loader = loader
|
|
171
|
+
module = importlib.util.module_from_spec(spec)
|
|
172
|
+
|
|
173
|
+
m = sys.modules.get(fullname, None)
|
|
174
|
+
if m is not None:
|
|
175
|
+
return m
|
|
176
|
+
|
|
177
|
+
sys.modules[fullname] = module
|
|
178
|
+
loader.exec_module(module)
|
|
179
|
+
return module
|
|
180
|
+
|
|
181
|
+
|
|
182
|
+
class Package(pulumi.runtime.ResourcePackage):
|
|
183
|
+
def __init__(self, pkg_info):
|
|
184
|
+
super().__init__()
|
|
185
|
+
self.pkg_info = pkg_info
|
|
186
|
+
|
|
187
|
+
def version(self):
|
|
188
|
+
return _version
|
|
189
|
+
|
|
190
|
+
def construct_provider(self, name: str, typ: str, urn: str) -> pulumi.ProviderResource:
|
|
191
|
+
if typ != self.pkg_info['token']:
|
|
192
|
+
raise Exception(f"unknown provider type {typ}")
|
|
193
|
+
Provider = getattr(lazy_import(self.pkg_info['fqn']), self.pkg_info['class'])
|
|
194
|
+
return Provider(name, pulumi.ResourceOptions(urn=urn))
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
class Module(pulumi.runtime.ResourceModule):
|
|
198
|
+
def __init__(self, mod_info):
|
|
199
|
+
super().__init__()
|
|
200
|
+
self.mod_info = mod_info
|
|
201
|
+
|
|
202
|
+
def version(self):
|
|
203
|
+
return _version
|
|
204
|
+
|
|
205
|
+
def construct(self, name: str, typ: str, urn: str) -> pulumi.Resource:
|
|
206
|
+
class_name = self.mod_info['classes'].get(typ, None)
|
|
207
|
+
|
|
208
|
+
if class_name is None:
|
|
209
|
+
raise Exception(f"unknown resource type {typ}")
|
|
210
|
+
|
|
211
|
+
TheClass = getattr(lazy_import(self.mod_info['fqn']), class_name)
|
|
212
|
+
return TheClass(name, pulumi.ResourceOptions(urn=urn))
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
def register(resource_modules, resource_packages):
|
|
216
|
+
resource_modules = json.loads(resource_modules)
|
|
217
|
+
resource_packages = json.loads(resource_packages)
|
|
218
|
+
|
|
219
|
+
for pkg_info in resource_packages:
|
|
220
|
+
pulumi.runtime.register_resource_package(pkg_info['pkg'], Package(pkg_info))
|
|
221
|
+
|
|
222
|
+
for mod_info in resource_modules:
|
|
223
|
+
pulumi.runtime.register_resource_module(
|
|
224
|
+
mod_info['pkg'],
|
|
225
|
+
mod_info['mod'],
|
|
226
|
+
Module(mod_info))
|
|
227
|
+
|
|
228
|
+
|
|
229
|
+
_F = typing.TypeVar('_F', bound=typing.Callable[..., typing.Any])
|
|
230
|
+
|
|
231
|
+
|
|
232
|
+
def lift_output_func(func: typing.Any) -> typing.Callable[[_F], _F]:
|
|
233
|
+
"""Decorator internally used on {fn}_output lifted function versions
|
|
234
|
+
to implement them automatically from the un-lifted function."""
|
|
235
|
+
|
|
236
|
+
func_sig = inspect.signature(func)
|
|
237
|
+
|
|
238
|
+
def lifted_func(*args, opts=None, **kwargs):
|
|
239
|
+
bound_args = func_sig.bind(*args, **kwargs)
|
|
240
|
+
# Convert tuple to list, see pulumi/pulumi#8172
|
|
241
|
+
args_list = list(bound_args.args)
|
|
242
|
+
return pulumi.Output.from_input({
|
|
243
|
+
'args': args_list,
|
|
244
|
+
'kwargs': bound_args.kwargs
|
|
245
|
+
}).apply(lambda resolved_args: func(*resolved_args['args'],
|
|
246
|
+
opts=opts,
|
|
247
|
+
**resolved_args['kwargs']))
|
|
248
|
+
|
|
249
|
+
return (lambda _: lifted_func)
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
def call_plain(
|
|
253
|
+
tok: str,
|
|
254
|
+
props: pulumi.Inputs,
|
|
255
|
+
res: typing.Optional[pulumi.Resource] = None,
|
|
256
|
+
typ: typing.Optional[type] = None,
|
|
257
|
+
) -> typing.Any:
|
|
258
|
+
"""
|
|
259
|
+
Wraps pulumi.runtime.plain to force the output and return it plainly.
|
|
260
|
+
"""
|
|
261
|
+
|
|
262
|
+
output = pulumi.runtime.call(tok, props, res, typ)
|
|
263
|
+
|
|
264
|
+
# Ingoring deps silently. They are typically non-empty, r.f() calls include r as a dependency.
|
|
265
|
+
result, known, secret, _ = _sync_await(asyncio.ensure_future(_await_output(output)))
|
|
266
|
+
|
|
267
|
+
problem = None
|
|
268
|
+
if not known:
|
|
269
|
+
problem = ' an unknown value'
|
|
270
|
+
elif secret:
|
|
271
|
+
problem = ' a secret value'
|
|
272
|
+
|
|
273
|
+
if problem:
|
|
274
|
+
raise AssertionError(
|
|
275
|
+
f"Plain resource method '{tok}' incorrectly returned {problem}. "
|
|
276
|
+
+ "This is an error in the provider, please report this to the provider developer."
|
|
277
|
+
)
|
|
278
|
+
|
|
279
|
+
return result
|
|
280
|
+
|
|
281
|
+
|
|
282
|
+
async def _await_output(o: pulumi.Output[typing.Any]) -> typing.Tuple[object, bool, bool, set]:
|
|
283
|
+
return (
|
|
284
|
+
await o._future,
|
|
285
|
+
await o._is_known,
|
|
286
|
+
await o._is_secret,
|
|
287
|
+
await o._resources,
|
|
288
|
+
)
|
|
289
|
+
|
|
290
|
+
def get_plugin_download_url():
|
|
291
|
+
return "github://api.github.com/cloudy-sky-software/pulumi-render"
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
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
|
+
from .. import services
|
|
12
|
+
|
|
13
|
+
apiKey: Optional[str]
|
|
14
|
+
"""
|
|
15
|
+
The Render API key
|
|
16
|
+
"""
|
|
17
|
+
|
|
18
|
+
clearCacheOnServiceUpdateDeployments: Optional[str]
|
|
19
|
+
"""
|
|
20
|
+
When a service is updated, a deployment is automatically triggered. This variable controls whether or not the service cache should be cleared upon deployment.
|
|
21
|
+
"""
|
|
22
|
+
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
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
|
+
from .. import services
|
|
12
|
+
|
|
13
|
+
import types
|
|
14
|
+
|
|
15
|
+
__config__ = pulumi.Config('render')
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class _ExportableConfig(types.ModuleType):
|
|
19
|
+
@property
|
|
20
|
+
def api_key(self) -> Optional[str]:
|
|
21
|
+
"""
|
|
22
|
+
The Render API key
|
|
23
|
+
"""
|
|
24
|
+
return __config__.get('apiKey')
|
|
25
|
+
|
|
26
|
+
@property
|
|
27
|
+
def clear_cache_on_service_update_deployments(self) -> Optional[str]:
|
|
28
|
+
"""
|
|
29
|
+
When a service is updated, a deployment is automatically triggered. This variable controls whether or not the service cache should be cleared upon deployment.
|
|
30
|
+
"""
|
|
31
|
+
return __config__.get('clearCacheOnServiceUpdateDeployments')
|
|
32
|
+
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
3
|
+
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
|
|
5
|
+
from .. import _utilities
|
|
6
|
+
import typing
|
|
7
|
+
# Export this package's modules as members:
|
|
8
|
+
from ._enums import *
|
|
9
|
+
from .get_owner import *
|
|
10
|
+
from .list_owners import *
|
|
11
|
+
from . import outputs
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
3
|
+
# *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
|
|
5
|
+
from enum import Enum
|
|
6
|
+
|
|
7
|
+
__all__ = [
|
|
8
|
+
'OwnerType',
|
|
9
|
+
]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class OwnerType(str, Enum):
|
|
13
|
+
"""
|
|
14
|
+
The type of the authorized user.
|
|
15
|
+
"""
|
|
16
|
+
USER = "user"
|
|
17
|
+
TEAM = "team"
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
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
|
+
from . import outputs
|
|
12
|
+
from ._enums import *
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
'GetOwnerResult',
|
|
16
|
+
'AwaitableGetOwnerResult',
|
|
17
|
+
'get_owner',
|
|
18
|
+
'get_owner_output',
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
@pulumi.output_type
|
|
22
|
+
class GetOwnerResult:
|
|
23
|
+
def __init__(__self__, items=None):
|
|
24
|
+
if items and not isinstance(items, dict):
|
|
25
|
+
raise TypeError("Expected argument 'items' to be a dict")
|
|
26
|
+
pulumi.set(__self__, "items", items)
|
|
27
|
+
|
|
28
|
+
@property
|
|
29
|
+
@pulumi.getter
|
|
30
|
+
def items(self) -> 'outputs.Owner':
|
|
31
|
+
return pulumi.get(self, "items")
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class AwaitableGetOwnerResult(GetOwnerResult):
|
|
35
|
+
# pylint: disable=using-constant-test
|
|
36
|
+
def __await__(self):
|
|
37
|
+
if False:
|
|
38
|
+
yield self
|
|
39
|
+
return GetOwnerResult(
|
|
40
|
+
items=self.items)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def get_owner(id: Optional[str] = None,
|
|
44
|
+
opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetOwnerResult:
|
|
45
|
+
"""
|
|
46
|
+
Use this data source to access information about an existing resource.
|
|
47
|
+
|
|
48
|
+
:param str id: (Required) The ID of the user or team
|
|
49
|
+
"""
|
|
50
|
+
__args__ = dict()
|
|
51
|
+
__args__['id'] = id
|
|
52
|
+
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
53
|
+
__ret__ = pulumi.runtime.invoke('render:owners:getOwner', __args__, opts=opts, typ=GetOwnerResult).value
|
|
54
|
+
|
|
55
|
+
return AwaitableGetOwnerResult(
|
|
56
|
+
items=pulumi.get(__ret__, 'items'))
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
@_utilities.lift_output_func(get_owner)
|
|
60
|
+
def get_owner_output(id: Optional[pulumi.Input[str]] = None,
|
|
61
|
+
opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetOwnerResult]:
|
|
62
|
+
"""
|
|
63
|
+
Use this data source to access information about an existing resource.
|
|
64
|
+
|
|
65
|
+
:param str id: (Required) The ID of the user or team
|
|
66
|
+
"""
|
|
67
|
+
...
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
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
|
+
from . import outputs
|
|
12
|
+
from ._enums import *
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
'ListOwnersResult',
|
|
16
|
+
'AwaitableListOwnersResult',
|
|
17
|
+
'list_owners',
|
|
18
|
+
'list_owners_output',
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
@pulumi.output_type
|
|
22
|
+
class ListOwnersResult:
|
|
23
|
+
def __init__(__self__, items=None):
|
|
24
|
+
if items and not isinstance(items, list):
|
|
25
|
+
raise TypeError("Expected argument 'items' to be a list")
|
|
26
|
+
pulumi.set(__self__, "items", items)
|
|
27
|
+
|
|
28
|
+
@property
|
|
29
|
+
@pulumi.getter
|
|
30
|
+
def items(self) -> Sequence['outputs.ListOwnersResponse']:
|
|
31
|
+
return pulumi.get(self, "items")
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class AwaitableListOwnersResult(ListOwnersResult):
|
|
35
|
+
# pylint: disable=using-constant-test
|
|
36
|
+
def __await__(self):
|
|
37
|
+
if False:
|
|
38
|
+
yield self
|
|
39
|
+
return ListOwnersResult(
|
|
40
|
+
items=self.items)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def list_owners(opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableListOwnersResult:
|
|
44
|
+
"""
|
|
45
|
+
Use this data source to access information about an existing resource.
|
|
46
|
+
"""
|
|
47
|
+
__args__ = dict()
|
|
48
|
+
opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
|
|
49
|
+
__ret__ = pulumi.runtime.invoke('render:owners:listOwners', __args__, opts=opts, typ=ListOwnersResult).value
|
|
50
|
+
|
|
51
|
+
return AwaitableListOwnersResult(
|
|
52
|
+
items=pulumi.get(__ret__, 'items'))
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
@_utilities.lift_output_func(list_owners)
|
|
56
|
+
def list_owners_output(opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[ListOwnersResult]:
|
|
57
|
+
"""
|
|
58
|
+
Use this data source to access information about an existing resource.
|
|
59
|
+
"""
|
|
60
|
+
...
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# coding=utf-8
|
|
2
|
+
# *** WARNING: this file was generated by pulumigen. ***
|
|
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
|
+
from . import outputs
|
|
12
|
+
from ._enums import *
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
'ListOwnersResponse',
|
|
16
|
+
'Owner',
|
|
17
|
+
]
|
|
18
|
+
|
|
19
|
+
@pulumi.output_type
|
|
20
|
+
class ListOwnersResponse(dict):
|
|
21
|
+
def __init__(__self__, *,
|
|
22
|
+
cursor: Optional[str] = None,
|
|
23
|
+
owner: Optional['outputs.Owner'] = None):
|
|
24
|
+
"""
|
|
25
|
+
:param 'Owner' owner: The owner object represents an authorized user or team. The `type` property indicates if the owner is a user or team.
|
|
26
|
+
"""
|
|
27
|
+
if cursor is not None:
|
|
28
|
+
pulumi.set(__self__, "cursor", cursor)
|
|
29
|
+
if owner is not None:
|
|
30
|
+
pulumi.set(__self__, "owner", owner)
|
|
31
|
+
|
|
32
|
+
@property
|
|
33
|
+
@pulumi.getter
|
|
34
|
+
def cursor(self) -> Optional[str]:
|
|
35
|
+
return pulumi.get(self, "cursor")
|
|
36
|
+
|
|
37
|
+
@property
|
|
38
|
+
@pulumi.getter
|
|
39
|
+
def owner(self) -> Optional['outputs.Owner']:
|
|
40
|
+
"""
|
|
41
|
+
The owner object represents an authorized user or team. The `type` property indicates if the owner is a user or team.
|
|
42
|
+
"""
|
|
43
|
+
return pulumi.get(self, "owner")
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
@pulumi.output_type
|
|
47
|
+
class Owner(dict):
|
|
48
|
+
"""
|
|
49
|
+
The owner object represents an authorized user or team. The `type` property indicates if the owner is a user or team.
|
|
50
|
+
"""
|
|
51
|
+
def __init__(__self__, *,
|
|
52
|
+
email: Optional[str] = None,
|
|
53
|
+
id: Optional[str] = None,
|
|
54
|
+
name: Optional[str] = None,
|
|
55
|
+
type: Optional['OwnerType'] = None):
|
|
56
|
+
"""
|
|
57
|
+
The owner object represents an authorized user or team. The `type` property indicates if the owner is a user or team.
|
|
58
|
+
:param str email: The email of the owner.
|
|
59
|
+
:param str id: The owner ID.
|
|
60
|
+
:param str name: The name of the owner.
|
|
61
|
+
:param 'OwnerType' type: The type of the authorized user.
|
|
62
|
+
"""
|
|
63
|
+
if email is not None:
|
|
64
|
+
pulumi.set(__self__, "email", email)
|
|
65
|
+
if id is not None:
|
|
66
|
+
pulumi.set(__self__, "id", id)
|
|
67
|
+
if name is not None:
|
|
68
|
+
pulumi.set(__self__, "name", name)
|
|
69
|
+
if type is not None:
|
|
70
|
+
pulumi.set(__self__, "type", type)
|
|
71
|
+
|
|
72
|
+
@property
|
|
73
|
+
@pulumi.getter
|
|
74
|
+
def email(self) -> Optional[str]:
|
|
75
|
+
"""
|
|
76
|
+
The email of the owner.
|
|
77
|
+
"""
|
|
78
|
+
return pulumi.get(self, "email")
|
|
79
|
+
|
|
80
|
+
@property
|
|
81
|
+
@pulumi.getter
|
|
82
|
+
def id(self) -> Optional[str]:
|
|
83
|
+
"""
|
|
84
|
+
The owner ID.
|
|
85
|
+
"""
|
|
86
|
+
return pulumi.get(self, "id")
|
|
87
|
+
|
|
88
|
+
@property
|
|
89
|
+
@pulumi.getter
|
|
90
|
+
def name(self) -> Optional[str]:
|
|
91
|
+
"""
|
|
92
|
+
The name of the owner.
|
|
93
|
+
"""
|
|
94
|
+
return pulumi.get(self, "name")
|
|
95
|
+
|
|
96
|
+
@property
|
|
97
|
+
@pulumi.getter
|
|
98
|
+
def type(self) -> Optional['OwnerType']:
|
|
99
|
+
"""
|
|
100
|
+
The type of the authorized user.
|
|
101
|
+
"""
|
|
102
|
+
return pulumi.get(self, "type")
|
|
103
|
+
|
|
104
|
+
|