UNPKG

@cuemby/equinix

Version:

A Pulumi package for creating and managing equinix cloud resources.

629 lines (628 loc) 20.2 kB
import * as pulumi from "@pulumi/pulumi"; import { input as inputs, output as outputs } from "./types"; /** * Resource `equinix.NetworkDevice` allows creation and management of Equinix Network Edge virtual * network devices. * * Network Edge virtual network devices can be created in two modes: * * * **managed** - (default) Where Equinix manages connectivity and services in the device and * customer gets limited access to the device. * * **self-configured** - Where customer provisions and manages own services in the device with less * restricted access. Some device types are offered only in this mode. * * In addition to management modes, there are two software license modes available: * * * **subscription** - Where Equinix provides software license, including end-to-end support, and * bills for the service respectively. * * **BYOL** - [bring your own license] Where customer brings his own, already procured device * software license. There are no charges associated with such license. It is the only licensing mode * for `self-configured` devices. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as equinix from "@cuemby/equinix"; * import * as equinix from "@pulumi/equinix"; * * const dc = equinix.GetNetworkAccount({ * metroCode: "DC", * }); * const sv = equinix.GetNetworkAccount({ * metroCode: "SV", * }); * const csr1000v_ha = new equinix.NetworkDevice("csr1000v-ha", { * throughput: 500, * throughputUnit: "Mbps", * metroCode: dc.then(dc => dc.metroCode), * typeCode: "CSR1000V", * packageCode: "SEC", * notifications: [ * "john@equinix.com", * "marry@equinix.com", * "fred@equinix.com", * ], * hostname: "csr1000v-p", * termLength: 6, * accountNumber: dc.then(dc => dc.number), * version: "16.09.05", * coreCount: 2, * secondaryDevice: { * name: "tf-csr1000v-s", * metroCode: sv.then(sv => sv.metroCode), * hostname: "csr1000v-s", * notifications: [ * "john@equinix.com", * "marry@equinix.com", * ], * accountNumber: sv.then(sv => sv.number), * }, * }); * ``` * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as equinix from "@cuemby/equinix"; * import * as equinix from "@pulumi/equinix"; * * const sv = equinix.GetNetworkAccount({ * metroCode: "SV", * }); * const panw_cluster = new equinix.NetworkDevice("panw-cluster", { * metroCode: sv.then(sv => sv.metroCode), * typeCode: "PA-VM", * selfManaged: true, * byol: true, * packageCode: "VM100", * notifications: [ * "john@equinix.com", * "marry@equinix.com", * "fred@equinix.com", * ], * termLength: 6, * accountNumber: sv.then(sv => sv.number), * version: "10.1.3", * interfaceCount: 10, * coreCount: 2, * sshKey: { * username: "test", * keyName: "test-key", * }, * aclTemplateId: "0bff6e05-f0e7-44cd-804a-25b92b835f8b", * clusterDetails: { * clusterName: "tf-panw-cluster", * node0: { * vendorConfiguration: { * hostname: "panw-node0", * }, * licenseToken: "licenseToken", * }, * node1: { * vendorConfiguration: { * hostname: "panw-node1", * }, * licenseToken: "licenseToken", * }, * }, * }); * ``` * * ## Import * * This resource can be imported using an existing ID * * ```sh * $ pulumi import equinix:index/networkDevice:NetworkDevice example {existing_id} * ``` * * The `license_token` and `mgtm_acl_template_uuid` fields can not be imported. */ export declare class NetworkDevice extends pulumi.CustomResource { /** * Get an existing NetworkDevice 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?: NetworkDeviceState, opts?: pulumi.CustomResourceOptions): NetworkDevice; /** * Returns true if the given object is an instance of NetworkDevice. 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 NetworkDevice; /** * Billing account number for a device. */ readonly accountNumber: pulumi.Output<string>; /** * Identifier of an ACL template that will be applied on the device. */ readonly aclTemplateId: pulumi.Output<string | undefined>; /** * Additional Internet bandwidth, in Mbps, that will be * allocated to the device (in addition to default 15Mbps). */ readonly additionalBandwidth: pulumi.Output<number>; /** * (Autonomous System Number) Unique identifier for a network on the internet. */ readonly asn: pulumi.Output<number>; /** * Boolean value that determines device licensing mode, i.e., * `bring your own license` or `subscription` (default). */ readonly byol: pulumi.Output<boolean | undefined>; /** * An object that has the cluster details. See * Cluster Details below for more details. */ readonly clusterDetails: pulumi.Output<outputs.NetworkDeviceClusterDetails | undefined>; /** * Number of CPU cores used by device. */ readonly coreCount: pulumi.Output<number>; /** * Device hostname prefix. */ readonly hostname: pulumi.Output<string>; /** * Device location Equinix Business Exchange name. */ readonly ibx: pulumi.Output<string>; /** * Number of network interfaces on a device. If not specified, * default number for a given device type will be used. */ readonly interfaceCount: pulumi.Output<number>; /** * List of device interfaces. See Interface Attribute below * for more details. */ readonly interfaces: pulumi.Output<outputs.NetworkDeviceInterface[]>; /** * Path to the license file that will be uploaded and applied on a * device. Applicable for some devices types in BYOL licensing mode. */ readonly licenseFile: pulumi.Output<string | undefined>; /** * License file id. This is necessary for Fortinet and Juniper clusters. */ readonly licenseFileId: pulumi.Output<string>; /** * Device license registration status. Possible values are `APPLYING_LICENSE`, * `REGISTERED`, `APPLIED`, `WAITING_FOR_CLUSTER_SETUP`, `REGISTRATION_FAILED`. */ readonly licenseStatus: pulumi.Output<string>; /** * License token. This is necessary for Palo Alto clusters. */ readonly licenseToken: pulumi.Output<string | undefined>; /** * Device location metro code. */ readonly metroCode: pulumi.Output<string>; /** * Identifier of an MGMT interface ACL template that will be * applied on the device. */ readonly mgmtAclTemplateUuid: pulumi.Output<string | undefined>; /** * Device name. */ readonly name: pulumi.Output<string>; /** * List of email addresses that will receive device status * notifications. */ readonly notifications: pulumi.Output<string[]>; /** * Name/number used to identify device order on the invoice. */ readonly orderReference: pulumi.Output<string | undefined>; /** * Device software package code. */ readonly packageCode: pulumi.Output<string>; /** * Purchase order number associated with a device order. */ readonly purchaseOrderNumber: pulumi.Output<string | undefined>; /** * Device redundancy type applicable for HA devices, either * primary or secondary. */ readonly redundancyType: pulumi.Output<string>; /** * Unique identifier for a redundant device applicable for HA devices. */ readonly redundantId: pulumi.Output<string>; /** * Device location region. */ readonly region: pulumi.Output<string>; /** * Definition of secondary device for redundant * device configurations. See Secondary Device below for more details. */ readonly secondaryDevice: pulumi.Output<outputs.NetworkDeviceSecondaryDevice | undefined>; /** * Boolean value that determines device management mode, i.e., * `self-managed` or `Equinix managed` (default). */ readonly selfManaged: pulumi.Output<boolean | undefined>; /** * IP address of SSH enabled interface on the device. */ readonly sshIpAddress: pulumi.Output<string>; /** * FQDN of SSH enabled interface on the device. */ readonly sshIpFqdn: pulumi.Output<string>; /** * Definition of SSH key that will be provisioned on a device */ readonly sshKey: pulumi.Output<outputs.NetworkDeviceSshKey | undefined>; /** * interface status. One of `AVAILABLE`, `RESERVED`, `ASSIGNED`. */ readonly status: pulumi.Output<string>; /** * Device term length. */ readonly termLength: pulumi.Output<number>; /** * Device license throughput. */ readonly throughput: pulumi.Output<number | undefined>; /** * License throughput unit. One of `Mbps` or `Gbps`. */ readonly throughputUnit: pulumi.Output<string | undefined>; /** * Device type code. */ readonly typeCode: pulumi.Output<string>; /** * Device unique identifier. */ readonly uuid: pulumi.Output<string>; /** * An object that has fields relevant to the vendor of the * cluster device. See Cluster Details - Nodes - Vendor Configuration * below for more details. */ readonly vendorConfiguration: pulumi.Output<{ [key: string]: string; }>; /** * Device software software version. */ readonly version: pulumi.Output<string>; /** * device interface id picked for WAN */ readonly wanInterfaceId: pulumi.Output<string | undefined>; /** * Device location zone code. */ readonly zoneCode: pulumi.Output<string>; /** * Create a NetworkDevice 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: NetworkDeviceArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering NetworkDevice resources. */ export interface NetworkDeviceState { /** * Billing account number for a device. */ accountNumber?: pulumi.Input<string>; /** * Identifier of an ACL template that will be applied on the device. */ aclTemplateId?: pulumi.Input<string>; /** * Additional Internet bandwidth, in Mbps, that will be * allocated to the device (in addition to default 15Mbps). */ additionalBandwidth?: pulumi.Input<number>; /** * (Autonomous System Number) Unique identifier for a network on the internet. */ asn?: pulumi.Input<number>; /** * Boolean value that determines device licensing mode, i.e., * `bring your own license` or `subscription` (default). */ byol?: pulumi.Input<boolean>; /** * An object that has the cluster details. See * Cluster Details below for more details. */ clusterDetails?: pulumi.Input<inputs.NetworkDeviceClusterDetails>; /** * Number of CPU cores used by device. */ coreCount?: pulumi.Input<number>; /** * Device hostname prefix. */ hostname?: pulumi.Input<string>; /** * Device location Equinix Business Exchange name. */ ibx?: pulumi.Input<string>; /** * Number of network interfaces on a device. If not specified, * default number for a given device type will be used. */ interfaceCount?: pulumi.Input<number>; /** * List of device interfaces. See Interface Attribute below * for more details. */ interfaces?: pulumi.Input<pulumi.Input<inputs.NetworkDeviceInterface>[]>; /** * Path to the license file that will be uploaded and applied on a * device. Applicable for some devices types in BYOL licensing mode. */ licenseFile?: pulumi.Input<string>; /** * License file id. This is necessary for Fortinet and Juniper clusters. */ licenseFileId?: pulumi.Input<string>; /** * Device license registration status. Possible values are `APPLYING_LICENSE`, * `REGISTERED`, `APPLIED`, `WAITING_FOR_CLUSTER_SETUP`, `REGISTRATION_FAILED`. */ licenseStatus?: pulumi.Input<string>; /** * License token. This is necessary for Palo Alto clusters. */ licenseToken?: pulumi.Input<string>; /** * Device location metro code. */ metroCode?: pulumi.Input<string>; /** * Identifier of an MGMT interface ACL template that will be * applied on the device. */ mgmtAclTemplateUuid?: pulumi.Input<string>; /** * Device name. */ name?: pulumi.Input<string>; /** * List of email addresses that will receive device status * notifications. */ notifications?: pulumi.Input<pulumi.Input<string>[]>; /** * Name/number used to identify device order on the invoice. */ orderReference?: pulumi.Input<string>; /** * Device software package code. */ packageCode?: pulumi.Input<string>; /** * Purchase order number associated with a device order. */ purchaseOrderNumber?: pulumi.Input<string>; /** * Device redundancy type applicable for HA devices, either * primary or secondary. */ redundancyType?: pulumi.Input<string>; /** * Unique identifier for a redundant device applicable for HA devices. */ redundantId?: pulumi.Input<string>; /** * Device location region. */ region?: pulumi.Input<string>; /** * Definition of secondary device for redundant * device configurations. See Secondary Device below for more details. */ secondaryDevice?: pulumi.Input<inputs.NetworkDeviceSecondaryDevice>; /** * Boolean value that determines device management mode, i.e., * `self-managed` or `Equinix managed` (default). */ selfManaged?: pulumi.Input<boolean>; /** * IP address of SSH enabled interface on the device. */ sshIpAddress?: pulumi.Input<string>; /** * FQDN of SSH enabled interface on the device. */ sshIpFqdn?: pulumi.Input<string>; /** * Definition of SSH key that will be provisioned on a device */ sshKey?: pulumi.Input<inputs.NetworkDeviceSshKey>; /** * interface status. One of `AVAILABLE`, `RESERVED`, `ASSIGNED`. */ status?: pulumi.Input<string>; /** * Device term length. */ termLength?: pulumi.Input<number>; /** * Device license throughput. */ throughput?: pulumi.Input<number>; /** * License throughput unit. One of `Mbps` or `Gbps`. */ throughputUnit?: pulumi.Input<string>; /** * Device type code. */ typeCode?: pulumi.Input<string>; /** * Device unique identifier. */ uuid?: pulumi.Input<string>; /** * An object that has fields relevant to the vendor of the * cluster device. See Cluster Details - Nodes - Vendor Configuration * below for more details. */ vendorConfiguration?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * Device software software version. */ version?: pulumi.Input<string>; /** * device interface id picked for WAN */ wanInterfaceId?: pulumi.Input<string>; /** * Device location zone code. */ zoneCode?: pulumi.Input<string>; } /** * The set of arguments for constructing a NetworkDevice resource. */ export interface NetworkDeviceArgs { /** * Billing account number for a device. */ accountNumber: pulumi.Input<string>; /** * Identifier of an ACL template that will be applied on the device. */ aclTemplateId?: pulumi.Input<string>; /** * Additional Internet bandwidth, in Mbps, that will be * allocated to the device (in addition to default 15Mbps). */ additionalBandwidth?: pulumi.Input<number>; /** * Boolean value that determines device licensing mode, i.e., * `bring your own license` or `subscription` (default). */ byol?: pulumi.Input<boolean>; /** * An object that has the cluster details. See * Cluster Details below for more details. */ clusterDetails?: pulumi.Input<inputs.NetworkDeviceClusterDetails>; /** * Number of CPU cores used by device. */ coreCount: pulumi.Input<number>; /** * Device hostname prefix. */ hostname?: pulumi.Input<string>; /** * Number of network interfaces on a device. If not specified, * default number for a given device type will be used. */ interfaceCount?: pulumi.Input<number>; /** * Path to the license file that will be uploaded and applied on a * device. Applicable for some devices types in BYOL licensing mode. */ licenseFile?: pulumi.Input<string>; /** * License token. This is necessary for Palo Alto clusters. */ licenseToken?: pulumi.Input<string>; /** * Device location metro code. */ metroCode: pulumi.Input<string>; /** * Identifier of an MGMT interface ACL template that will be * applied on the device. */ mgmtAclTemplateUuid?: pulumi.Input<string>; /** * Device name. */ name?: pulumi.Input<string>; /** * List of email addresses that will receive device status * notifications. */ notifications: pulumi.Input<pulumi.Input<string>[]>; /** * Name/number used to identify device order on the invoice. */ orderReference?: pulumi.Input<string>; /** * Device software package code. */ packageCode: pulumi.Input<string>; /** * Purchase order number associated with a device order. */ purchaseOrderNumber?: pulumi.Input<string>; /** * Definition of secondary device for redundant * device configurations. See Secondary Device below for more details. */ secondaryDevice?: pulumi.Input<inputs.NetworkDeviceSecondaryDevice>; /** * Boolean value that determines device management mode, i.e., * `self-managed` or `Equinix managed` (default). */ selfManaged?: pulumi.Input<boolean>; /** * Definition of SSH key that will be provisioned on a device */ sshKey?: pulumi.Input<inputs.NetworkDeviceSshKey>; /** * Device term length. */ termLength: pulumi.Input<number>; /** * Device license throughput. */ throughput?: pulumi.Input<number>; /** * License throughput unit. One of `Mbps` or `Gbps`. */ throughputUnit?: pulumi.Input<string>; /** * Device type code. */ typeCode: pulumi.Input<string>; /** * An object that has fields relevant to the vendor of the * cluster device. See Cluster Details - Nodes - Vendor Configuration * below for more details. */ vendorConfiguration?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; /** * Device software software version. */ version: pulumi.Input<string>; /** * device interface id picked for WAN */ wanInterfaceId?: pulumi.Input<string>; }