@pulumi/digitalocean
Version:
A Pulumi package for creating and managing DigitalOcean cloud resources.
92 lines • 2.93 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Get information on a reserved IP. This data source provides the region and Droplet id
* as configured on your DigitalOcean account. This is useful if the reserved IP
* in question is not managed by Terraform or you need to find the Droplet the IP is
* attached to.
*
* An error is triggered if the provided reserved IP does not exist.
*
* ## Example Usage
*
* Get the reserved IP:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as digitalocean from "@pulumi/digitalocean";
*
* const config = new pulumi.Config();
* const publicIp = config.requireObject<any>("publicIp");
* const example = digitalocean.getReservedIp({
* ipAddress: publicIp,
* });
* export const fipOutput = example.then(example => example.dropletId);
* ```
*/
export declare function getReservedIp(args: GetReservedIpArgs, opts?: pulumi.InvokeOptions): Promise<GetReservedIpResult>;
/**
* A collection of arguments for invoking getReservedIp.
*/
export interface GetReservedIpArgs {
/**
* The allocated IP address of the specific reserved IP to retrieve.
*/
ipAddress: string;
}
/**
* A collection of values returned by getReservedIp.
*/
export interface GetReservedIpResult {
/**
* The Droplet id that the reserved IP has been assigned to.
*/
readonly dropletId: number;
/**
* The provider-assigned unique ID for this managed resource.
*/
readonly id: string;
readonly ipAddress: string;
/**
* The region that the reserved IP is reserved to.
*/
readonly region: string;
/**
* The uniform resource name of the reserved IP.
*/
readonly urn: string;
}
/**
* Get information on a reserved IP. This data source provides the region and Droplet id
* as configured on your DigitalOcean account. This is useful if the reserved IP
* in question is not managed by Terraform or you need to find the Droplet the IP is
* attached to.
*
* An error is triggered if the provided reserved IP does not exist.
*
* ## Example Usage
*
* Get the reserved IP:
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as digitalocean from "@pulumi/digitalocean";
*
* const config = new pulumi.Config();
* const publicIp = config.requireObject<any>("publicIp");
* const example = digitalocean.getReservedIp({
* ipAddress: publicIp,
* });
* export const fipOutput = example.then(example => example.dropletId);
* ```
*/
export declare function getReservedIpOutput(args: GetReservedIpOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetReservedIpResult>;
/**
* A collection of arguments for invoking getReservedIp.
*/
export interface GetReservedIpOutputArgs {
/**
* The allocated IP address of the specific reserved IP to retrieve.
*/
ipAddress: pulumi.Input<string>;
}
//# sourceMappingURL=getReservedIp.d.ts.map