@pulumi/hcloud
Version:
A Pulumi package for creating and managing hcloud cloud resources.
126 lines (125 loc) • 4.66 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* Provides a Hetzner Cloud Network to represent a Network in the Hetzner Cloud.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as hcloud from "@pulumi/hcloud";
*
* const privNet = new hcloud.Network("privNet", {
* name: "my-net",
* ipRange: "10.0.1.0/24",
* });
* ```
*
* ## Import
*
* Networks can be imported using its `id`:
*
* ```sh
* $ pulumi import hcloud:index/network:Network example "$NETWORK_ID"
* ```
*/
export declare class Network extends pulumi.CustomResource {
/**
* Get an existing Network resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: NetworkState, opts?: pulumi.CustomResourceOptions): Network;
/**
* Returns true if the given object is an instance of Network. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is Network;
/**
* Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
*/
readonly deleteProtection: pulumi.Output<boolean | undefined>;
/**
* Enable or disable exposing the routes to the vSwitch connection. The exposing only takes effect if a vSwitch connection is active.
*/
readonly exposeRoutesToVswitch: pulumi.Output<boolean | undefined>;
/**
* IP Range of the whole Network which must span all included subnets and route destinations. Must be one of the private ipv4 ranges of RFC1918.
*/
readonly ipRange: pulumi.Output<string>;
/**
* User-defined labels (key-value pairs) should be created with.
*/
readonly labels: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* Name of the Network to create (must be unique per project).
*/
readonly name: pulumi.Output<string>;
/**
* Create a Network resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: NetworkArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering Network resources.
*/
export interface NetworkState {
/**
* Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
*/
deleteProtection?: pulumi.Input<boolean>;
/**
* Enable or disable exposing the routes to the vSwitch connection. The exposing only takes effect if a vSwitch connection is active.
*/
exposeRoutesToVswitch?: pulumi.Input<boolean>;
/**
* IP Range of the whole Network which must span all included subnets and route destinations. Must be one of the private ipv4 ranges of RFC1918.
*/
ipRange?: pulumi.Input<string>;
/**
* User-defined labels (key-value pairs) should be created with.
*/
labels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Name of the Network to create (must be unique per project).
*/
name?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a Network resource.
*/
export interface NetworkArgs {
/**
* Enable or disable delete protection. See "Delete Protection" in the Provider Docs for details.
*/
deleteProtection?: pulumi.Input<boolean>;
/**
* Enable or disable exposing the routes to the vSwitch connection. The exposing only takes effect if a vSwitch connection is active.
*/
exposeRoutesToVswitch?: pulumi.Input<boolean>;
/**
* IP Range of the whole Network which must span all included subnets and route destinations. Must be one of the private ipv4 ranges of RFC1918.
*/
ipRange: pulumi.Input<string>;
/**
* User-defined labels (key-value pairs) should be created with.
*/
labels?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Name of the Network to create (must be unique per project).
*/
name?: pulumi.Input<string>;
}