@pulumi/digitalocean 4.7.0-alpha.1633346817

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.
Files changed (240) hide show
  1. package/LICENSE +202 -0
  2. package/README.md +68 -0
  3. package/app.d.ts +203 -0
  4. package/app.js +174 -0
  5. package/app.js.map +1 -0
  6. package/cdn.d.ts +169 -0
  7. package/cdn.js +116 -0
  8. package/cdn.js.map +1 -0
  9. package/certificate.d.ts +225 -0
  10. package/certificate.js +137 -0
  11. package/certificate.js.map +1 -0
  12. package/config/index.d.ts +1 -0
  13. package/config/index.js +10 -0
  14. package/config/index.js.map +1 -0
  15. package/config/vars.d.ts +20 -0
  16. package/config/vars.js +28 -0
  17. package/config/vars.js.map +1 -0
  18. package/containerRegistry.d.ts +88 -0
  19. package/containerRegistry.js +83 -0
  20. package/containerRegistry.js.map +1 -0
  21. package/containerRegistryDockerCredentials.d.ts +108 -0
  22. package/containerRegistryDockerCredentials.js +93 -0
  23. package/containerRegistryDockerCredentials.js.map +1 -0
  24. package/customImage.d.ts +155 -0
  25. package/customImage.js +113 -0
  26. package/customImage.js.map +1 -0
  27. package/databaseCluster.d.ts +306 -0
  28. package/databaseCluster.js +165 -0
  29. package/databaseCluster.js.map +1 -0
  30. package/databaseConnectionPool.d.ts +189 -0
  31. package/databaseConnectionPool.js +120 -0
  32. package/databaseConnectionPool.js.map +1 -0
  33. package/databaseDb.d.ts +87 -0
  34. package/databaseDb.js +82 -0
  35. package/databaseDb.js.map +1 -0
  36. package/databaseFirewall.d.ts +129 -0
  37. package/databaseFirewall.js +126 -0
  38. package/databaseFirewall.js.map +1 -0
  39. package/databaseReplica.d.ts +204 -0
  40. package/databaseReplica.js +110 -0
  41. package/databaseReplica.js.map +1 -0
  42. package/databaseUser.d.ts +117 -0
  43. package/databaseUser.js +90 -0
  44. package/databaseUser.js.map +1 -0
  45. package/dnsRecord.d.ts +200 -0
  46. package/dnsRecord.js +114 -0
  47. package/dnsRecord.js.map +1 -0
  48. package/domain.d.ts +103 -0
  49. package/domain.js +83 -0
  50. package/domain.js.map +1 -0
  51. package/droplet.d.ts +386 -0
  52. package/droplet.js +137 -0
  53. package/droplet.js.map +1 -0
  54. package/dropletSnapshot.d.ts +117 -0
  55. package/dropletSnapshot.js +88 -0
  56. package/dropletSnapshot.js.map +1 -0
  57. package/firewall.d.ts +226 -0
  58. package/firewall.js +150 -0
  59. package/firewall.js.map +1 -0
  60. package/floatingIp.d.ts +112 -0
  61. package/floatingIp.js +91 -0
  62. package/floatingIp.js.map +1 -0
  63. package/floatingIpAssignment.d.ts +85 -0
  64. package/floatingIpAssignment.js +83 -0
  65. package/floatingIpAssignment.js.map +1 -0
  66. package/getAccount.d.ts +32 -0
  67. package/getAccount.js +31 -0
  68. package/getAccount.js.map +1 -0
  69. package/getApp.d.ts +63 -0
  70. package/getApp.js +36 -0
  71. package/getApp.js.map +1 -0
  72. package/getCertificate.d.ts +48 -0
  73. package/getCertificate.js +40 -0
  74. package/getCertificate.js.map +1 -0
  75. package/getContainerRegistry.d.ts +54 -0
  76. package/getContainerRegistry.js +41 -0
  77. package/getContainerRegistry.js.map +1 -0
  78. package/getDatabaseCluster.d.ts +103 -0
  79. package/getDatabaseCluster.js +35 -0
  80. package/getDatabaseCluster.js.map +1 -0
  81. package/getDatabaseReplica.d.ts +87 -0
  82. package/getDatabaseReplica.js +40 -0
  83. package/getDatabaseReplica.js.map +1 -0
  84. package/getDomain.d.ts +37 -0
  85. package/getDomain.js +28 -0
  86. package/getDomain.js.map +1 -0
  87. package/getDomains.d.ts +61 -0
  88. package/getDomains.js +49 -0
  89. package/getDomains.js.map +1 -0
  90. package/getDroplet.d.ts +161 -0
  91. package/getDroplet.js +67 -0
  92. package/getDroplet.js.map +1 -0
  93. package/getDropletSnapshot.d.ts +76 -0
  94. package/getDropletSnapshot.js +43 -0
  95. package/getDropletSnapshot.js.map +1 -0
  96. package/getDroplets.d.ts +85 -0
  97. package/getDroplets.js +73 -0
  98. package/getDroplets.js.map +1 -0
  99. package/getFirewall.d.ts +83 -0
  100. package/getFirewall.js +40 -0
  101. package/getFirewall.js.map +1 -0
  102. package/getFloatingIp.d.ts +48 -0
  103. package/getFloatingIp.js +43 -0
  104. package/getFloatingIp.js.map +1 -0
  105. package/getImage.d.ts +110 -0
  106. package/getImage.js +71 -0
  107. package/getImage.js.map +1 -0
  108. package/getImages.d.ts +90 -0
  109. package/getImages.js +74 -0
  110. package/getImages.js.map +1 -0
  111. package/getKubernetesCluster.d.ts +95 -0
  112. package/getKubernetesCluster.js +23 -0
  113. package/getKubernetesCluster.js.map +1 -0
  114. package/getKubernetesVersions.d.ts +79 -0
  115. package/getKubernetesVersions.js +70 -0
  116. package/getKubernetesVersions.js.map +1 -0
  117. package/getLoadBalancer.d.ts +59 -0
  118. package/getLoadBalancer.js +41 -0
  119. package/getLoadBalancer.js.map +1 -0
  120. package/getProject.d.ts +72 -0
  121. package/getProject.js +37 -0
  122. package/getProject.js.map +1 -0
  123. package/getProjects.d.ts +85 -0
  124. package/getProjects.js +72 -0
  125. package/getProjects.js.map +1 -0
  126. package/getRecord.d.ts +42 -0
  127. package/getRecord.js +28 -0
  128. package/getRecord.js.map +1 -0
  129. package/getRecords.d.ts +39 -0
  130. package/getRecords.js +25 -0
  131. package/getRecords.js.map +1 -0
  132. package/getRegion.d.ts +56 -0
  133. package/getRegion.js +35 -0
  134. package/getRegion.js.map +1 -0
  135. package/getRegions.d.ts +82 -0
  136. package/getRegions.js +70 -0
  137. package/getRegions.js.map +1 -0
  138. package/getSizes.d.ts +35 -0
  139. package/getSizes.js +26 -0
  140. package/getSizes.js.map +1 -0
  141. package/getSpacesBucket.d.ts +59 -0
  142. package/getSpacesBucket.js +39 -0
  143. package/getSpacesBucket.js.map +1 -0
  144. package/getSpacesBucketObject.d.ts +125 -0
  145. package/getSpacesBucketObject.js +53 -0
  146. package/getSpacesBucketObject.js.map +1 -0
  147. package/getSpacesBucketObjects.d.ts +83 -0
  148. package/getSpacesBucketObjects.js +49 -0
  149. package/getSpacesBucketObjects.js.map +1 -0
  150. package/getSpacesBuckets.d.ts +75 -0
  151. package/getSpacesBuckets.js +63 -0
  152. package/getSpacesBuckets.js.map +1 -0
  153. package/getSshKey.d.ts +47 -0
  154. package/getSshKey.js +46 -0
  155. package/getSshKey.js.map +1 -0
  156. package/getSshKeys.d.ts +58 -0
  157. package/getSshKeys.js +46 -0
  158. package/getSshKeys.js.map +1 -0
  159. package/getTag.d.ts +71 -0
  160. package/getTag.js +45 -0
  161. package/getTag.js.map +1 -0
  162. package/getTags.d.ts +50 -0
  163. package/getTags.js +41 -0
  164. package/getTags.js.map +1 -0
  165. package/getVolume.d.ts +98 -0
  166. package/getVolume.js +64 -0
  167. package/getVolume.js.map +1 -0
  168. package/getVolumeSnapshot.d.ts +98 -0
  169. package/getVolumeSnapshot.js +61 -0
  170. package/getVolumeSnapshot.js.map +1 -0
  171. package/getVpc.d.ts +95 -0
  172. package/getVpc.js +61 -0
  173. package/getVpc.js.map +1 -0
  174. package/index.d.ts +74 -0
  175. package/index.js +240 -0
  176. package/index.js.map +1 -0
  177. package/kubernetesCluster.d.ts +220 -0
  178. package/kubernetesCluster.js +102 -0
  179. package/kubernetesCluster.js.map +1 -0
  180. package/kubernetesNodePool.d.ts +242 -0
  181. package/kubernetesNodePool.js +141 -0
  182. package/kubernetesNodePool.js.map +1 -0
  183. package/loadBalancer.d.ts +307 -0
  184. package/loadBalancer.js +161 -0
  185. package/loadBalancer.js.map +1 -0
  186. package/monitorAlert.d.ts +193 -0
  187. package/monitorAlert.js +99 -0
  188. package/monitorAlert.js.map +1 -0
  189. package/package.json +28 -0
  190. package/package.json.bak +27 -0
  191. package/package.json.dev +27 -0
  192. package/project.d.ts +191 -0
  193. package/project.js +129 -0
  194. package/project.js.map +1 -0
  195. package/projectResources.d.ts +100 -0
  196. package/projectResources.js +98 -0
  197. package/projectResources.js.map +1 -0
  198. package/provider.d.ts +67 -0
  199. package/provider.js +51 -0
  200. package/provider.js.map +1 -0
  201. package/scripts/install-pulumi-plugin.js +21 -0
  202. package/spacesBucket.d.ts +210 -0
  203. package/spacesBucket.js +139 -0
  204. package/spacesBucket.js.map +1 -0
  205. package/spacesBucketObject.d.ts +293 -0
  206. package/spacesBucketObject.js +139 -0
  207. package/spacesBucketObject.js.map +1 -0
  208. package/sshKey.d.ts +103 -0
  209. package/sshKey.js +89 -0
  210. package/sshKey.js.map +1 -0
  211. package/tag.d.ts +127 -0
  212. package/tag.js +93 -0
  213. package/tag.js.map +1 -0
  214. package/types/enums/index.d.ts +151 -0
  215. package/types/enums/index.js +148 -0
  216. package/types/enums/index.js.map +1 -0
  217. package/types/index.d.ts +4 -0
  218. package/types/index.js +12 -0
  219. package/types/index.js.map +1 -0
  220. package/types/input.d.ts +1584 -0
  221. package/types/input.js +5 -0
  222. package/types/input.js.map +1 -0
  223. package/types/output.d.ts +2730 -0
  224. package/types/output.js +5 -0
  225. package/types/output.js.map +1 -0
  226. package/utilities.d.ts +4 -0
  227. package/utilities.js +51 -0
  228. package/utilities.js.map +1 -0
  229. package/volume.d.ts +225 -0
  230. package/volume.js +128 -0
  231. package/volume.js.map +1 -0
  232. package/volumeAttachment.d.ts +88 -0
  233. package/volumeAttachment.js +86 -0
  234. package/volumeAttachment.js.map +1 -0
  235. package/volumeSnapshot.d.ts +129 -0
  236. package/volumeSnapshot.js +90 -0
  237. package/volumeSnapshot.js.map +1 -0
  238. package/vpc.d.ts +152 -0
  239. package/vpc.js +109 -0
  240. package/vpc.js.map +1 -0
@@ -0,0 +1,85 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ import { input as inputs, output as outputs } from "./types";
3
+ /**
4
+ * Get information on Droplets for use in other resources, with the ability to filter and sort the results.
5
+ * If no filters are specified, all Droplets will be returned.
6
+ *
7
+ * This data source is useful if the Droplets in question are not managed by the provider or you need to
8
+ * utilize any of the Droplets' data.
9
+ *
10
+ * Note: You can use the `digitalocean.Droplet` data source to obtain metadata
11
+ * about a single Droplet if you already know the `id`, unique `name`, or unique `tag` to retrieve.
12
+ *
13
+ * ## Example Usage
14
+ *
15
+ * Use the `filter` block with a `key` string and `values` list to filter images.
16
+ *
17
+ * For example to find all Droplets with size `s-1vcpu-1gb`:
18
+ *
19
+ * ```typescript
20
+ * import * as pulumi from "@pulumi/pulumi";
21
+ * import * as digitalocean from "@pulumi/digitalocean";
22
+ *
23
+ * const small = pulumi.output(digitalocean.getDroplets({
24
+ * filters: [{
25
+ * key: "size",
26
+ * values: ["s-1vcpu-1gb"],
27
+ * }],
28
+ * }));
29
+ * ```
30
+ *
31
+ * You can filter on multiple fields and sort the results as well:
32
+ *
33
+ * ```typescript
34
+ * import * as pulumi from "@pulumi/pulumi";
35
+ * import * as digitalocean from "@pulumi/digitalocean";
36
+ *
37
+ * const small_with_backups = pulumi.output(digitalocean.getDroplets({
38
+ * filters: [
39
+ * {
40
+ * key: "size",
41
+ * values: ["s-1vcpu-1gb"],
42
+ * },
43
+ * {
44
+ * key: "backups",
45
+ * values: ["true"],
46
+ * },
47
+ * ],
48
+ * sorts: [{
49
+ * direction: "desc",
50
+ * key: "created_at",
51
+ * }],
52
+ * }));
53
+ * ```
54
+ */
55
+ export declare function getDroplets(args?: GetDropletsArgs, opts?: pulumi.InvokeOptions): Promise<GetDropletsResult>;
56
+ /**
57
+ * A collection of arguments for invoking getDroplets.
58
+ */
59
+ export interface GetDropletsArgs {
60
+ /**
61
+ * Filter the results.
62
+ * The `filter` block is documented below.
63
+ */
64
+ filters?: inputs.GetDropletsFilter[];
65
+ /**
66
+ * Sort the results.
67
+ * The `sort` block is documented below.
68
+ */
69
+ sorts?: inputs.GetDropletsSort[];
70
+ }
71
+ /**
72
+ * A collection of values returned by getDroplets.
73
+ */
74
+ export interface GetDropletsResult {
75
+ /**
76
+ * A list of Droplets satisfying any `filter` and `sort` criteria. Each Droplet has the following attributes:
77
+ */
78
+ readonly droplets: outputs.GetDropletsDroplet[];
79
+ readonly filters?: outputs.GetDropletsFilter[];
80
+ /**
81
+ * The provider-assigned unique ID for this managed resource.
82
+ */
83
+ readonly id: string;
84
+ readonly sorts?: outputs.GetDropletsSort[];
85
+ }
package/getDroplets.js ADDED
@@ -0,0 +1,73 @@
1
+ "use strict";
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
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ const pulumi = require("@pulumi/pulumi");
6
+ const utilities = require("./utilities");
7
+ /**
8
+ * Get information on Droplets for use in other resources, with the ability to filter and sort the results.
9
+ * If no filters are specified, all Droplets will be returned.
10
+ *
11
+ * This data source is useful if the Droplets in question are not managed by the provider or you need to
12
+ * utilize any of the Droplets' data.
13
+ *
14
+ * Note: You can use the `digitalocean.Droplet` data source to obtain metadata
15
+ * about a single Droplet if you already know the `id`, unique `name`, or unique `tag` to retrieve.
16
+ *
17
+ * ## Example Usage
18
+ *
19
+ * Use the `filter` block with a `key` string and `values` list to filter images.
20
+ *
21
+ * For example to find all Droplets with size `s-1vcpu-1gb`:
22
+ *
23
+ * ```typescript
24
+ * import * as pulumi from "@pulumi/pulumi";
25
+ * import * as digitalocean from "@pulumi/digitalocean";
26
+ *
27
+ * const small = pulumi.output(digitalocean.getDroplets({
28
+ * filters: [{
29
+ * key: "size",
30
+ * values: ["s-1vcpu-1gb"],
31
+ * }],
32
+ * }));
33
+ * ```
34
+ *
35
+ * You can filter on multiple fields and sort the results as well:
36
+ *
37
+ * ```typescript
38
+ * import * as pulumi from "@pulumi/pulumi";
39
+ * import * as digitalocean from "@pulumi/digitalocean";
40
+ *
41
+ * const small_with_backups = pulumi.output(digitalocean.getDroplets({
42
+ * filters: [
43
+ * {
44
+ * key: "size",
45
+ * values: ["s-1vcpu-1gb"],
46
+ * },
47
+ * {
48
+ * key: "backups",
49
+ * values: ["true"],
50
+ * },
51
+ * ],
52
+ * sorts: [{
53
+ * direction: "desc",
54
+ * key: "created_at",
55
+ * }],
56
+ * }));
57
+ * ```
58
+ */
59
+ function getDroplets(args, opts) {
60
+ args = args || {};
61
+ if (!opts) {
62
+ opts = {};
63
+ }
64
+ if (!opts.version) {
65
+ opts.version = utilities.getVersion();
66
+ }
67
+ return pulumi.runtime.invoke("digitalocean:index/getDroplets:getDroplets", {
68
+ "filters": args.filters,
69
+ "sorts": args.sorts,
70
+ }, opts);
71
+ }
72
+ exports.getDroplets = getDroplets;
73
+ //# sourceMappingURL=getDroplets.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getDroplets.js","sourceRoot":"","sources":["../getDroplets.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;AAEjF,yCAAyC;AAEzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AACH,SAAgB,WAAW,CAAC,IAAsB,EAAE,IAA2B;IAC3E,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;IAClB,IAAI,CAAC,IAAI,EAAE;QACP,IAAI,GAAG,EAAE,CAAA;KACZ;IAED,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;QACf,IAAI,CAAC,OAAO,GAAG,SAAS,CAAC,UAAU,EAAE,CAAC;KACzC;IACD,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,4CAA4C,EAAE;QACvE,SAAS,EAAE,IAAI,CAAC,OAAO;QACvB,OAAO,EAAE,IAAI,CAAC,KAAK;KACtB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAbD,kCAaC"}
@@ -0,0 +1,83 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ import { input as inputs, output as outputs } from "./types";
3
+ /**
4
+ * Get information on a DigitalOcean Firewall.
5
+ *
6
+ * ## Example Usage
7
+ *
8
+ * Get the firewall:
9
+ *
10
+ * ```typescript
11
+ * import * as pulumi from "@pulumi/pulumi";
12
+ * import * as digitalocean from "@pulumi/digitalocean";
13
+ *
14
+ * const example = digitalocean.getFirewall({
15
+ * firewallId: "1df48973-6eef-4214-854f-fa7726e7e583",
16
+ * });
17
+ * export const exampleFirewallName = example.then(example => example.name);
18
+ * ```
19
+ */
20
+ export declare function getFirewall(args: GetFirewallArgs, opts?: pulumi.InvokeOptions): Promise<GetFirewallResult>;
21
+ /**
22
+ * A collection of arguments for invoking getFirewall.
23
+ */
24
+ export interface GetFirewallArgs {
25
+ /**
26
+ * The list of the IDs of the Droplets assigned to
27
+ * the Firewall.
28
+ */
29
+ dropletIds?: number[];
30
+ /**
31
+ * The ID of the firewall to retrieve information
32
+ * about.
33
+ */
34
+ firewallId: string;
35
+ inboundRules?: inputs.GetFirewallInboundRule[];
36
+ outboundRules?: inputs.GetFirewallOutboundRule[];
37
+ /**
38
+ * The names of the Tags assigned to the Firewall.
39
+ */
40
+ tags?: string[];
41
+ }
42
+ /**
43
+ * A collection of values returned by getFirewall.
44
+ */
45
+ export interface GetFirewallResult {
46
+ /**
47
+ * A time value given in ISO8601 combined date and time format
48
+ * that represents when the Firewall was created.
49
+ */
50
+ readonly createdAt: string;
51
+ /**
52
+ * The list of the IDs of the Droplets assigned to
53
+ * the Firewall.
54
+ */
55
+ readonly dropletIds: number[];
56
+ readonly firewallId: string;
57
+ /**
58
+ * The provider-assigned unique ID for this managed resource.
59
+ */
60
+ readonly id: string;
61
+ readonly inboundRules: outputs.GetFirewallInboundRule[];
62
+ /**
63
+ * The name of the Firewall.
64
+ */
65
+ readonly name: string;
66
+ readonly outboundRules: outputs.GetFirewallOutboundRule[];
67
+ /**
68
+ * A set of object containing the fields, `dropletId`,
69
+ * `removing`, and `status`. It is provided to detail exactly which Droplets
70
+ * are having their security policies updated. When empty, all changes
71
+ * have been successfully applied.
72
+ */
73
+ readonly pendingChanges: outputs.GetFirewallPendingChange[];
74
+ /**
75
+ * A status string indicating the current state of the Firewall.
76
+ * This can be "waiting", "succeeded", or "failed".
77
+ */
78
+ readonly status: string;
79
+ /**
80
+ * The names of the Tags assigned to the Firewall.
81
+ */
82
+ readonly tags: string[];
83
+ }
package/getFirewall.js ADDED
@@ -0,0 +1,40 @@
1
+ "use strict";
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
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ const pulumi = require("@pulumi/pulumi");
6
+ const utilities = require("./utilities");
7
+ /**
8
+ * Get information on a DigitalOcean Firewall.
9
+ *
10
+ * ## Example Usage
11
+ *
12
+ * Get the firewall:
13
+ *
14
+ * ```typescript
15
+ * import * as pulumi from "@pulumi/pulumi";
16
+ * import * as digitalocean from "@pulumi/digitalocean";
17
+ *
18
+ * const example = digitalocean.getFirewall({
19
+ * firewallId: "1df48973-6eef-4214-854f-fa7726e7e583",
20
+ * });
21
+ * export const exampleFirewallName = example.then(example => example.name);
22
+ * ```
23
+ */
24
+ function getFirewall(args, opts) {
25
+ if (!opts) {
26
+ opts = {};
27
+ }
28
+ if (!opts.version) {
29
+ opts.version = utilities.getVersion();
30
+ }
31
+ return pulumi.runtime.invoke("digitalocean:index/getFirewall:getFirewall", {
32
+ "dropletIds": args.dropletIds,
33
+ "firewallId": args.firewallId,
34
+ "inboundRules": args.inboundRules,
35
+ "outboundRules": args.outboundRules,
36
+ "tags": args.tags,
37
+ }, opts);
38
+ }
39
+ exports.getFirewall = getFirewall;
40
+ //# sourceMappingURL=getFirewall.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getFirewall.js","sourceRoot":"","sources":["../getFirewall.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;AAEjF,yCAAyC;AAEzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;GAgBG;AACH,SAAgB,WAAW,CAAC,IAAqB,EAAE,IAA2B;IAC1E,IAAI,CAAC,IAAI,EAAE;QACP,IAAI,GAAG,EAAE,CAAA;KACZ;IAED,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;QACf,IAAI,CAAC,OAAO,GAAG,SAAS,CAAC,UAAU,EAAE,CAAC;KACzC;IACD,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,4CAA4C,EAAE;QACvE,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,YAAY,EAAE,IAAI,CAAC,UAAU;QAC7B,cAAc,EAAE,IAAI,CAAC,YAAY;QACjC,eAAe,EAAE,IAAI,CAAC,aAAa;QACnC,MAAM,EAAE,IAAI,CAAC,IAAI;KACpB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAfD,kCAeC"}
@@ -0,0 +1,48 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ /**
3
+ * Get information on a floating ip. This data source provides the region and Droplet id
4
+ * as configured on your DigitalOcean account. This is useful if the floating IP
5
+ * in question is not managed by the provider or you need to find the Droplet the IP is
6
+ * attached to.
7
+ *
8
+ * An error is triggered if the provided floating IP does not exist.
9
+ *
10
+ * ## Example Usage
11
+ *
12
+ * Get the floating IP:
13
+ *
14
+ * ```typescript
15
+ * import * as pulumi from "@pulumi/pulumi";
16
+ * import * as digitalocean from "@pulumi/digitalocean";
17
+ *
18
+ * const config = new pulumi.Config();
19
+ * const publicIp = config.requireObject("publicIp");
20
+ * const example = digitalocean.getFloatingIp({
21
+ * ipAddress: publicIp,
22
+ * });
23
+ * export const fipOutput = example.then(example => example.dropletId);
24
+ * ```
25
+ */
26
+ export declare function getFloatingIp(args: GetFloatingIpArgs, opts?: pulumi.InvokeOptions): Promise<GetFloatingIpResult>;
27
+ /**
28
+ * A collection of arguments for invoking getFloatingIp.
29
+ */
30
+ export interface GetFloatingIpArgs {
31
+ /**
32
+ * The allocated IP address of the specific floating IP to retrieve.
33
+ */
34
+ ipAddress: string;
35
+ }
36
+ /**
37
+ * A collection of values returned by getFloatingIp.
38
+ */
39
+ export interface GetFloatingIpResult {
40
+ readonly dropletId: number;
41
+ readonly floatingIpUrn: string;
42
+ /**
43
+ * The provider-assigned unique ID for this managed resource.
44
+ */
45
+ readonly id: string;
46
+ readonly ipAddress: string;
47
+ readonly region: string;
48
+ }
@@ -0,0 +1,43 @@
1
+ "use strict";
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
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ const pulumi = require("@pulumi/pulumi");
6
+ const utilities = require("./utilities");
7
+ /**
8
+ * Get information on a floating ip. This data source provides the region and Droplet id
9
+ * as configured on your DigitalOcean account. This is useful if the floating IP
10
+ * in question is not managed by the provider or you need to find the Droplet the IP is
11
+ * attached to.
12
+ *
13
+ * An error is triggered if the provided floating IP does not exist.
14
+ *
15
+ * ## Example Usage
16
+ *
17
+ * Get the floating IP:
18
+ *
19
+ * ```typescript
20
+ * import * as pulumi from "@pulumi/pulumi";
21
+ * import * as digitalocean from "@pulumi/digitalocean";
22
+ *
23
+ * const config = new pulumi.Config();
24
+ * const publicIp = config.requireObject("publicIp");
25
+ * const example = digitalocean.getFloatingIp({
26
+ * ipAddress: publicIp,
27
+ * });
28
+ * export const fipOutput = example.then(example => example.dropletId);
29
+ * ```
30
+ */
31
+ function getFloatingIp(args, opts) {
32
+ if (!opts) {
33
+ opts = {};
34
+ }
35
+ if (!opts.version) {
36
+ opts.version = utilities.getVersion();
37
+ }
38
+ return pulumi.runtime.invoke("digitalocean:index/getFloatingIp:getFloatingIp", {
39
+ "ipAddress": args.ipAddress,
40
+ }, opts);
41
+ }
42
+ exports.getFloatingIp = getFloatingIp;
43
+ //# sourceMappingURL=getFloatingIp.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getFloatingIp.js","sourceRoot":"","sources":["../getFloatingIp.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;AAEjF,yCAAyC;AAEzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,SAAgB,aAAa,CAAC,IAAuB,EAAE,IAA2B;IAC9E,IAAI,CAAC,IAAI,EAAE;QACP,IAAI,GAAG,EAAE,CAAA;KACZ;IAED,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;QACf,IAAI,CAAC,OAAO,GAAG,SAAS,CAAC,UAAU,EAAE,CAAC;KACzC;IACD,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,gDAAgD,EAAE;QAC3E,WAAW,EAAE,IAAI,CAAC,SAAS;KAC9B,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAXD,sCAWC"}
package/getImage.d.ts ADDED
@@ -0,0 +1,110 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ /**
3
+ * Get information on an image for use in other resources (e.g. creating a Droplet
4
+ * based on snapshot). This data source provides all of the image properties as
5
+ * configured on your DigitalOcean account. This is useful if the image in question
6
+ * is not managed by the provider or you need to utilize any of the image's data.
7
+ *
8
+ * An error is triggered if zero or more than one result is returned by the query.
9
+ *
10
+ * ## Example Usage
11
+ *
12
+ * Get the data about a snapshot:
13
+ *
14
+ * ```typescript
15
+ * import * as pulumi from "@pulumi/pulumi";
16
+ * import * as digitalocean from "@pulumi/digitalocean";
17
+ *
18
+ * const example1 = pulumi.output(digitalocean.getImage({
19
+ * name: "example-1.0.0",
20
+ * }));
21
+ * ```
22
+ *
23
+ * Reuse the data about a snapshot to create a Droplet:
24
+ *
25
+ * ```typescript
26
+ * import * as pulumi from "@pulumi/pulumi";
27
+ * import * as digitalocean from "@pulumi/digitalocean";
28
+ *
29
+ * const exampleImage = digitalocean.getImage({
30
+ * name: "example-1.0.0",
31
+ * });
32
+ * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", {
33
+ * image: exampleImage.then(exampleImage => exampleImage.id),
34
+ * region: "nyc2",
35
+ * size: "s-1vcpu-1gb",
36
+ * });
37
+ * ```
38
+ *
39
+ * Get the data about an official image:
40
+ *
41
+ * ```typescript
42
+ * import * as pulumi from "@pulumi/pulumi";
43
+ * import * as digitalocean from "@pulumi/digitalocean";
44
+ *
45
+ * const example2 = pulumi.output(digitalocean.getImage({
46
+ * slug: "ubuntu-18-04-x64",
47
+ * }));
48
+ * ```
49
+ */
50
+ export declare function getImage(args?: GetImageArgs, opts?: pulumi.InvokeOptions): Promise<GetImageResult>;
51
+ /**
52
+ * A collection of arguments for invoking getImage.
53
+ */
54
+ export interface GetImageArgs {
55
+ /**
56
+ * The id of the image
57
+ */
58
+ id?: number;
59
+ /**
60
+ * The name of the image.
61
+ */
62
+ name?: string;
63
+ /**
64
+ * The slug of the official image.
65
+ */
66
+ slug?: string;
67
+ /**
68
+ * Restrict the search to one of the following categories of images:
69
+ */
70
+ source?: string;
71
+ }
72
+ /**
73
+ * A collection of values returned by getImage.
74
+ */
75
+ export interface GetImageResult {
76
+ readonly created: string;
77
+ readonly description: string;
78
+ /**
79
+ * The name of the distribution of the OS of the image.
80
+ * * `minDiskSize`: The minimum 'disk' required for the image.
81
+ * * `sizeGigabytes`: The size of the image in GB.
82
+ */
83
+ readonly distribution: string;
84
+ readonly errorMessage: string;
85
+ readonly id: number;
86
+ /**
87
+ * The id of the image (legacy parameter).
88
+ */
89
+ readonly image: string;
90
+ readonly minDiskSize: number;
91
+ readonly name: string;
92
+ /**
93
+ * Is image a public image or not. Public images represent
94
+ * Linux distributions or One-Click Applications, while non-public images represent
95
+ * snapshots and backups and are only available within your account.
96
+ * * `regions`: A set of the regions that the image is available in.
97
+ * * `tags`: A set of tags applied to the image
98
+ * * `created`: When the image was created
99
+ * * `status`: Current status of the image
100
+ * * `errorMessage`: Any applicable error message pertaining to the image
101
+ */
102
+ readonly private: boolean;
103
+ readonly regions: string[];
104
+ readonly sizeGigabytes: number;
105
+ readonly slug: string;
106
+ readonly source?: string;
107
+ readonly status: string;
108
+ readonly tags: string[];
109
+ readonly type: string;
110
+ }
package/getImage.js ADDED
@@ -0,0 +1,71 @@
1
+ "use strict";
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
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ const pulumi = require("@pulumi/pulumi");
6
+ const utilities = require("./utilities");
7
+ /**
8
+ * Get information on an image for use in other resources (e.g. creating a Droplet
9
+ * based on snapshot). This data source provides all of the image properties as
10
+ * configured on your DigitalOcean account. This is useful if the image in question
11
+ * is not managed by the provider or you need to utilize any of the image's data.
12
+ *
13
+ * An error is triggered if zero or more than one result is returned by the query.
14
+ *
15
+ * ## Example Usage
16
+ *
17
+ * Get the data about a snapshot:
18
+ *
19
+ * ```typescript
20
+ * import * as pulumi from "@pulumi/pulumi";
21
+ * import * as digitalocean from "@pulumi/digitalocean";
22
+ *
23
+ * const example1 = pulumi.output(digitalocean.getImage({
24
+ * name: "example-1.0.0",
25
+ * }));
26
+ * ```
27
+ *
28
+ * Reuse the data about a snapshot to create a Droplet:
29
+ *
30
+ * ```typescript
31
+ * import * as pulumi from "@pulumi/pulumi";
32
+ * import * as digitalocean from "@pulumi/digitalocean";
33
+ *
34
+ * const exampleImage = digitalocean.getImage({
35
+ * name: "example-1.0.0",
36
+ * });
37
+ * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", {
38
+ * image: exampleImage.then(exampleImage => exampleImage.id),
39
+ * region: "nyc2",
40
+ * size: "s-1vcpu-1gb",
41
+ * });
42
+ * ```
43
+ *
44
+ * Get the data about an official image:
45
+ *
46
+ * ```typescript
47
+ * import * as pulumi from "@pulumi/pulumi";
48
+ * import * as digitalocean from "@pulumi/digitalocean";
49
+ *
50
+ * const example2 = pulumi.output(digitalocean.getImage({
51
+ * slug: "ubuntu-18-04-x64",
52
+ * }));
53
+ * ```
54
+ */
55
+ function getImage(args, opts) {
56
+ args = args || {};
57
+ if (!opts) {
58
+ opts = {};
59
+ }
60
+ if (!opts.version) {
61
+ opts.version = utilities.getVersion();
62
+ }
63
+ return pulumi.runtime.invoke("digitalocean:index/getImage:getImage", {
64
+ "id": args.id,
65
+ "name": args.name,
66
+ "slug": args.slug,
67
+ "source": args.source,
68
+ }, opts);
69
+ }
70
+ exports.getImage = getImage;
71
+ //# sourceMappingURL=getImage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getImage.js","sourceRoot":"","sources":["../getImage.ts"],"names":[],"mappings":";AAAA,wFAAwF;AACxF,iFAAiF;;AAEjF,yCAAyC;AAEzC,yCAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AACH,SAAgB,QAAQ,CAAC,IAAmB,EAAE,IAA2B;IACrE,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;IAClB,IAAI,CAAC,IAAI,EAAE;QACP,IAAI,GAAG,EAAE,CAAA;KACZ;IAED,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;QACf,IAAI,CAAC,OAAO,GAAG,SAAS,CAAC,UAAU,EAAE,CAAC;KACzC;IACD,OAAO,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,sCAAsC,EAAE;QACjE,IAAI,EAAE,IAAI,CAAC,EAAE;QACb,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,MAAM,EAAE,IAAI,CAAC,IAAI;QACjB,QAAQ,EAAE,IAAI,CAAC,MAAM;KACxB,EAAE,IAAI,CAAC,CAAC;AACb,CAAC;AAfD,4BAeC"}
package/getImages.d.ts ADDED
@@ -0,0 +1,90 @@
1
+ import * as pulumi from "@pulumi/pulumi";
2
+ import { input as inputs, output as outputs } from "./types";
3
+ /**
4
+ * Get information on images for use in other resources (e.g. creating a Droplet
5
+ * based on a snapshot), with the ability to filter and sort the results. If no filters are specified,
6
+ * all images will be returned.
7
+ *
8
+ * This data source is useful if the image in question is not managed by the provider or you need to utilize any
9
+ * of the image's data.
10
+ *
11
+ * Note: You can use the `digitalocean.getImage` data source to obtain metadata
12
+ * about a single image if you already know the `slug`, unique `name`, or `id` to retrieve.
13
+ *
14
+ * ## Example Usage
15
+ *
16
+ * Use the `filter` block with a `key` string and `values` list to filter images.
17
+ *
18
+ * For example to find all Ubuntu images:
19
+ *
20
+ * ```typescript
21
+ * import * as pulumi from "@pulumi/pulumi";
22
+ * import * as digitalocean from "@pulumi/digitalocean";
23
+ *
24
+ * const ubuntu = pulumi.output(digitalocean.getImages({
25
+ * filters: [{
26
+ * key: "distribution",
27
+ * values: ["Ubuntu"],
28
+ * }],
29
+ * }));
30
+ * ```
31
+ *
32
+ * You can filter on multiple fields and sort the results as well:
33
+ *
34
+ * ```typescript
35
+ * import * as pulumi from "@pulumi/pulumi";
36
+ * import * as digitalocean from "@pulumi/digitalocean";
37
+ *
38
+ * const available = pulumi.output(digitalocean.getImages({
39
+ * filters: [
40
+ * {
41
+ * key: "distribution",
42
+ * values: ["Ubuntu"],
43
+ * },
44
+ * {
45
+ * key: "regions",
46
+ * values: ["nyc3"],
47
+ * },
48
+ * ],
49
+ * sorts: [{
50
+ * direction: "desc",
51
+ * key: "created",
52
+ * }],
53
+ * }));
54
+ * ```
55
+ */
56
+ export declare function getImages(args?: GetImagesArgs, opts?: pulumi.InvokeOptions): Promise<GetImagesResult>;
57
+ /**
58
+ * A collection of arguments for invoking getImages.
59
+ */
60
+ export interface GetImagesArgs {
61
+ /**
62
+ * Filter the results.
63
+ * The `filter` block is documented below.
64
+ */
65
+ filters?: inputs.GetImagesFilter[];
66
+ /**
67
+ * Sort the results.
68
+ * The `sort` block is documented below.
69
+ */
70
+ sorts?: inputs.GetImagesSort[];
71
+ }
72
+ /**
73
+ * A collection of values returned by getImages.
74
+ */
75
+ export interface GetImagesResult {
76
+ readonly filters?: outputs.GetImagesFilter[];
77
+ /**
78
+ * The provider-assigned unique ID for this managed resource.
79
+ */
80
+ readonly id: string;
81
+ /**
82
+ * A set of images satisfying any `filter` and `sort` criteria. Each image has the following attributes:
83
+ * - `slug`: Unique text identifier of the image.
84
+ * - `id`: The ID of the image.
85
+ * - `name`: The name of the image.
86
+ * - `type`: Type of the image.
87
+ */
88
+ readonly images: outputs.GetImagesImage[];
89
+ readonly sorts?: outputs.GetImagesSort[];
90
+ }