Package @pulumi/packet

This provider is a derived work of the Terraform Provider distributed under MPL 2.0. If you encounter a bug or missing feature, first check the pulumi/pulumi-packet repo; however, if that doesn’t turn up anything, please consult the source terraform-providers/terraform-provider-packet repo.

var packet = require("@pulumi/packet");
import * as packet from "@pulumi/packet";

Modules

namespace BillingCycles

namespace Facilities

namespace IpAddressTypes

namespace IpBlockTypes

namespace NetworkTypes

namespace OperatingSystems

namespace Plans

Resources

Data Sources

Others

namespace BillingCycles

const Hourly

const Hourly: BillingCycle = "hourly";

const Monthly

const Monthly: BillingCycle = "monthly";

namespace Facilities

const AMS1

const AMS1: Facility = "ams1";

const ATL1

const ATL1: Facility = "atl1";

const DFW1

const DFW1: Facility = "dfw1";

const DFW2

const DFW2: Facility = "dfw2";

const EWR1

const EWR1: Facility = "ewr1";

const FRA2

const FRA2: Facility = "fra2";

const HKG1

const HKG1: Facility = "hkg1";

const IAD1

const IAD1: Facility = "iad1";

const LAX1

const LAX1: Facility = "lax1";

const MRS1

const MRS1: Facility = "mrs1";

const NRT1

const NRT1: Facility = "nrt1";

const ORD1

const ORD1: Facility = "ord1";

const SEA1

const SEA1: Facility = "sea1";

const SIN1

const SIN1: Facility = "sin1";

const SJC1

const SJC1: Facility = "sjc1";

const SYD1

const SYD1: Facility = "syd1";

const YYZ1

const YYZ1: Facility = "yyz1";

namespace IpAddressTypes

const PrivateIPv4

const PrivateIPv4: IpAddressType = "private_ipv4";

const PublicIPv4

const PublicIPv4: IpAddressType = "public_ipv4";

const PublicIPv6

const PublicIPv6: IpAddressType = "public_ipv6";

namespace IpBlockTypes

const GlobalIPv4

const GlobalIPv4: IpBlockType = "global_ipv4";

const PublicIPv4

const PublicIPv4: IpBlockType = "public_ipv4";

namespace NetworkTypes

const Hybrid

const Hybrid: NetworkType = "hybrid";

const Layer2Bonded

const Layer2Bonded: NetworkType = "layer2-bonded";

const Layer2Individual

const Layer2Individual: NetworkType = "layer2-individual";

const Layer3

const Layer3: NetworkType = "layer3";

namespace OperatingSystems

const Alpine3

const Alpine3: OperatingSystem = "alpine_3";

const CentOS6

const CentOS6: OperatingSystem = "centos_6";

const CentOS7

const CentOS7: OperatingSystem = "centos_7";

const CoreOSAlpha

const CoreOSAlpha: OperatingSystem = "coreos_alpha";

const CoreOSBeta

const CoreOSBeta: OperatingSystem = "coreos_beta";

const CoreOSStable

const CoreOSStable: OperatingSystem = "coreos_stable";

const CustomIPXE

const CustomIPXE: OperatingSystem = "custom_ipxe";

const Debian8

const Debian8: OperatingSystem = "debian_8";

const Debian9

const Debian9: OperatingSystem = "debian_9";

const FreeBSD10_4

const FreeBSD10_4: OperatingSystem = "freebsd_10_4";

const FreeBSD11_1

const FreeBSD11_1: OperatingSystem = "freebsd_11_1";

const FreeBSD11_2

const FreeBSD11_2: OperatingSystem = "freebsd_11_2";

const FreeBSD12Testing

const FreeBSD12Testing: OperatingSystem = "freebsd_12_testing";

const NixOS18_03

const NixOS18_03: OperatingSystem = "nixos_18_03";

const NixOS19_03

const NixOS19_03: OperatingSystem = "nixos_19_03";

const OpenSUSE42_3

const OpenSUSE42_3: OperatingSystem = "opensuse_42_3";

const RancherOS

const RancherOS: OperatingSystem = "rancher";

const RHEL7

const RHEL7: OperatingSystem = "rhel_7";

const ScientificLinux6

const ScientificLinux6: OperatingSystem = "scientific_6";

const SLES12SP3

const SLES12SP3: OperatingSystem = "suse_sles12_sp3";

const Ubuntu1404

const Ubuntu1404: OperatingSystem = "ubuntu_14_04";

const Ubuntu1604

const Ubuntu1604: OperatingSystem = "ubuntu_16_04";

const Ubuntu1710

const Ubuntu1710: OperatingSystem = "ubuntu_17_10";

const Ubuntu1804

const Ubuntu1804: OperatingSystem = "ubuntu_18_04";

const VMWareEsxi6_5

const VMWareEsxi6_5: OperatingSystem = "vmware_esxi_6_5";

const Windows2012R2

const Windows2012R2: OperatingSystem = "windows_2012_r2";

const Windows2016

const Windows2016: OperatingSystem = "windows_2016";

namespace Plans

const C1LargeARM

const C1LargeARM: Plan = "baremetal_2a";

const C1SmallX86

const C1SmallX86: Plan = "baremetal_1";

const C1XLargeX86

const C1XLargeX86: Plan = "baremetal_3";

const C2LargeARM

const C2LargeARM: Plan = "c2.large.arm";

const C2MediumX86

const C2MediumX86: Plan = "c2.medium.x86";

const G2LargeX86

const G2LargeX86: Plan = "g2.large.x86";

const M1XLargeX86

const M1XLargeX86: Plan = "baremetal_2";

const M2XLargeX86

const M2XLargeX86: Plan = "m2.xlarge.x86";

const S1LargeX86

const S1LargeX86: Plan = "baremetal_s";

const T1SmallX86

const T1SmallX86: Plan = "baremetal_0";

const X1SmallX86

const X1SmallX86: Plan = "baremetal_1e";

const X2XLargeX86

const X2XLargeX86: Plan = "x2.xlarge.x86";

Resources

Resource BgpSession

class BgpSession extends CustomResource

Provides a resource to manage BGP sessions in Packet Host. Refer to Packet BGP documentation for more details.

You need to have BGP config enabled in your project.

BGP session must be linked to a device running BIRD or other BGP routing daemon which will control route advertisements via the session to Packet’s upstream routers.

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/bgp_session.html.markdown.

constructor

new BgpSession(name: string, args: BgpSessionArgs, opts?: pulumi.CustomResourceOptions)

Create a BgpSession resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: BgpSessionState, opts?: pulumi.CustomResourceOptions): BgpSession

Get an existing BgpSession resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of BgpSession. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property addressFamily

public addressFamily: pulumi.Output<string>;

ipv4 or ipv6

property defaultRoute

public defaultRoute: pulumi.Output<boolean | undefined>;

Boolean flag to set the default route policy. False by default.

property deviceId

public deviceId: pulumi.Output<string>;

ID of device

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property status

public status: pulumi.Output<string>;

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource Connect

class Connect extends CustomResource

Provides a resource for Packet Connect, a link between Packet VLANs and VLANs in other cloud providers.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

const vlan1 = new packet.Vlan("vlan1", {
    description: "VLAN in New Jersey",
    facility: "ewr1",
    projectId: local_project_id,
});
const myExpressroute = new packet.Connect("myExpressroute", {
    facility: "ewr1",
    name: "test",
    portSpeed: 100,
    projectId: local_project_id,
    // provider ID for Azure ExpressRoute is ed5de8e0-77a9-4d3b-9de0-65281d3aa831
    providerId: "ed5de8e0-77a9-4d3b-9de0-65281d3aa831",
    // providerPayload for Azure ExpressRoute provider is your ExpressRoute
    // authorization key (in UUID format)
    providerPayload: "58b4ec12-af34-4435-5435-db3bde4a4b3a",
    vxlan: vlan1.vxlan,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/connect.html.markdown.

constructor

new Connect(name: string, args: ConnectArgs, opts?: pulumi.CustomResourceOptions)

Create a Connect resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ConnectState, opts?: pulumi.CustomResourceOptions): Connect

Get an existing Connect resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Connect. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property facility

public facility: pulumi.Output<Facility>;

Facility where to create the VLAN

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property name

public name: pulumi.Output<string>;

Name for the Connect resource

property portSpeed

public portSpeed: pulumi.Output<number>;

Port speed in Mbps

property projectId

public projectId: pulumi.Output<string>;

ID of parent project

property providerId

public providerId: pulumi.Output<string>;

ID of Connect Provider. Provider IDs are * Azure ExpressRoute - “ed5de8e0-77a9-4d3b-9de0-65281d3aa831”

property providerPayload

public providerPayload: pulumi.Output<string>;

Authorization key for the Connect provider

property status

public status: pulumi.Output<string>;

Status of the Connect resource, one of PROVISIONING, PROVISIONED, DEPROVISIONING, DEPROVISIONED

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property vxlan

public vxlan: pulumi.Output<number>;

VXLAN Network identifier of the linked Packet VLAN

Resource Device

class Device extends CustomResource

Provides a Packet device resource. This can be used to create, modify, and delete devices.

Note: All arguments including the rootPassword and userData will be stored in the raw state as plain-text. Read more about sensitive data in state.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

// Create a device and add it to coolProject
const web1 = new packet.Device("web1", {
    billingCycle: "hourly",
    facilities: ["ewr1"],
    hostname: "tf.coreos2",
    operatingSystem: "coreosStable",
    plan: "t1.small.x86",
    projectId: local_project_id,
});
import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

// Same as above, but boot via iPXE initially, using the Ignition Provider for provisioning
const pxe1 = new packet.Device("pxe1", {
    alwaysPxe: false,
    billingCycle: "hourly",
    facilities: ["ewr1"],
    hostname: "tf.coreos2-pxe",
    ipxeScriptUrl: "https://rawgit.com/cloudnativelabs/pxe/master/packet/coreos-stable-packet.ipxe",
    operatingSystem: "customIpxe",
    plan: "t1.small.x86",
    projectId: local_project_id,
    userData: ignition_config_example.rendered,
});
import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

// Deploy device on next-available reserved hardware and do custom partitioning.
const web1 = new packet.Device("web1", {
    billingCycle: "hourly",
    facilities: ["sjc1"],
    hardwareReservationId: "next-available",
    hostname: "tftest",
    operatingSystem: "ubuntu1604",
    plan: "t1.small.x86",
    projectId: local_project_id,
    storage: `{
  "disks": [
    {
      "device": "/dev/sda",
      "wipeTable": true,
      "partitions": [
        {
          "label": "BIOS",
          "number": 1,
          "size": 4096
        },
        {
          "label": "SWAP",
          "number": 2,
          "size": "3993600"
        },
        {
          "label": "ROOT",
          "number": 3,
          "size": 0
        }
      ]
    }
  ],
  "filesystems": [
    {
      "mount": {
        "device": "/dev/sda3",
        "format": "ext4",
        "point": "/",
        "create": {
          "options": [
            "-L",
            "ROOT"
          ]
        }
      }
    },
    {
      "mount": {
        "device": "/dev/sda2",
        "format": "swap",
        "point": "none",
        "create": {
          "options": [
            "-L",
            "SWAP"
          ]
        }
      }
    }
  ]
}
`,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/device.html.markdown.

constructor

new Device(name: string, args: DeviceArgs, opts?: pulumi.CustomResourceOptions)

Create a Device resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: DeviceState, opts?: pulumi.CustomResourceOptions): Device

Get an existing Device resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Device. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property accessPrivateIpv4

public accessPrivateIpv4: pulumi.Output<string>;

The ipv4 private IP assigned to the device

property accessPublicIpv4

public accessPublicIpv4: pulumi.Output<string>;

The ipv4 maintenance IP assigned to the device

property accessPublicIpv6

public accessPublicIpv6: pulumi.Output<string>;

The ipv6 maintenance IP assigned to the device

property alwaysPxe

public alwaysPxe: pulumi.Output<boolean | undefined>;

If true, a device with OS customIpxe will continue to boot via iPXE on reboots.

property billingCycle

public billingCycle: pulumi.Output<BillingCycle>;

monthly or hourly

property created

public created: pulumi.Output<string>;

The timestamp for when the device was created

property deployedFacility

public deployedFacility: pulumi.Output<string>;

The facility where the device is deployed.

property description

public description: pulumi.Output<string | undefined>;

Description string for the device

property facilities

public facilities: pulumi.Output<Facility[]>;

List of facility codes with deployment preferences. Packet API will go through the list and will deploy your device to first facility with free capacity. List items must be facility codes or any (a wildcard). To find the facility code, visit Facilities API docs, set your API auth token in the top of the page and see JSON from the API response.

property hardwareReservationId

public hardwareReservationId: pulumi.Output<string>;

The full ID of the hardware reservation where you want this device deployed, or next-available if you want to pick your next available reservation automatically.

property hostname

public hostname: pulumi.Output<string>;

The device name

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property ipAddressTypes

public ipAddressTypes: pulumi.Output<IpAddressType[] | undefined>;

A set containing one or more of [privateIpv4, publicIpv4, publicIpv6]. It specifies which IP address types a new device should obtain. If omitted, a created device will obtain all 3 addresses. If you only want private IPv4 address for the new device, pass [privateIpv4].

property ipxeScriptUrl

public ipxeScriptUrl: pulumi.Output<string | undefined>;

URL pointing to a hosted iPXE script. More information is in the Custom iPXE doc.

property locked

public locked: pulumi.Output<boolean>;

Whether the device is locked

property networkType

public networkType: pulumi.Output<NetworkType | undefined>;

property networks

public networks: pulumi.Output<outputs.DeviceNetwork[]>;

The device’s private and public IP (v4 and v6) network details. When a device is run without any special network configuration, it will have 3 networks: * Public IPv4 at packet_device.name.network.0 * IPv6 at packet_device.name.network.1 * Private IPv4 at packet_device.name.network.2 Elastic addresses then stack by type - an assigned public IPv4 will go after the management public IPv4 (to index 1), and will then shift the indices of the IPv6 and private IPv4. Assigned private IPv4 will go after the management private IPv4 (to the end of the network list). The fields of the network attributes are:

property operatingSystem

public operatingSystem: pulumi.Output<OperatingSystem>;

The operating system slug. To find the slug, or visit Operating Systems API docs, set your API auth token in the top of the page and see JSON from the API response.

property plan

public plan: pulumi.Output<Plan>;

The device plan slug. To find the plan slug, visit Device plans API docs, set your auth token in the top of the page and see JSON from the API response.

property ports

public ports: pulumi.Output<outputs.DevicePort[]>;

Ports assigned to the device

property projectId

public projectId: pulumi.Output<string>;

The ID of the project in which to create the device

property projectSshKeyIds

public projectSshKeyIds: pulumi.Output<string[] | undefined>;

Array of IDs of the project SSH keys which should be added to the device. If you omit this, SSH keys of all the members of the parent project will be added to the device. If you specify this array, only the listed project SSH keys will be added. Project SSH keys can be created with the [packet..ProjectSshKey][packet_project_ssh_key.html] resource.

property publicIpv4SubnetSize

public publicIpv4SubnetSize: pulumi.Output<number>;

Size of allocated subnet, more information is in the Custom Subnet Size doc.

property rootPassword

public rootPassword: pulumi.Output<string>;

Root password to the server (disabled after 24 hours)

property sshKeyIds

public sshKeyIds: pulumi.Output<string[]>;

List of IDs of SSH keys deployed in the device, can be both user and project SSH keys

property state

public state: pulumi.Output<string>;

The status of the device

property storage

public storage: pulumi.Output<string | undefined>;

JSON for custom partitioning. Only usable on reserved hardware. More information in in the Custom Partitioning and RAID doc.

property tags

public tags: pulumi.Output<string[] | undefined>;

Tags attached to the device

property updated

public updated: pulumi.Output<string>;

The timestamp for the last time the device was updated

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property userData

public userData: pulumi.Output<string | undefined>;

A string of the desired User Data for the device.

property waitForReservationDeprovision

public waitForReservationDeprovision: pulumi.Output<boolean | undefined>;

Only used for devices in reserved hardware. If set, the deletion of this device will block until the hardware reservation is marked provisionable (about 4 minutes in August 2019).

Resource IpAttachment

class IpAttachment extends CustomResource

Provides a resource to attach elastic IP subnets to devices.

To attach an IP subnet from a reserved block to a provisioned device, you must derive a subnet CIDR belonging to one of your reserved blocks in the same project and facility as the target device.

For example, you have reserved IPv4 address block 147.229.10.152/30, you can choose to assign either the whole block as one subnet to a device; or 2 subnets with CIDRs 147.229.10.152/31’ and 147.229.10.154/31; or 4 subnets with mask prefix length 32. More about the elastic IP subnets is here.

Device and reserved block must be in the same facility.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

// Reserve /30 block of max 2 public IPv4 addresses in Parsippany, NJ (ewr1) for myproject
const myblock = new packet.ReservedIpBlock("myblock", {
    facility: "ewr1",
    projectId: local_project_id,
    quantity: 2,
});
// Assign /32 subnet (single address) from reserved block to a device
const firstAddressAssignment = new packet.IpAttachment("firstAddressAssignment", {
    cidrNotation: myblock.cidrNotation.apply(cidrNotation => `${(() => { throw "NYI: call to cidrhost"; })()}/32`),
    deviceId: packet_device_mydevice.id,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/ip_attachment.html.markdown.

constructor

new IpAttachment(name: string, args: IpAttachmentArgs, opts?: pulumi.CustomResourceOptions)

Create a IpAttachment resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: IpAttachmentState, opts?: pulumi.CustomResourceOptions): IpAttachment

Get an existing IpAttachment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of IpAttachment. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property address

public address: pulumi.Output<string>;

property addressFamily

public addressFamily: pulumi.Output<number>;

Address family as integer (4 or 6)

property cidr

public cidr: pulumi.Output<number>;

length of CIDR prefix of the subnet as integer

property cidrNotation

public cidrNotation: pulumi.Output<string>;

CIDR notation of subnet from block reserved in the same project and facility as the device

property deviceId

public deviceId: pulumi.Output<string>;

ID of device to which to assign the subnet

property gateway

public gateway: pulumi.Output<string>;

IP address of gateway for the subnet

property global

public global: pulumi.Output<boolean>;

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property manageable

public manageable: pulumi.Output<boolean>;

property management

public management: pulumi.Output<boolean>;

property netmask

public netmask: pulumi.Output<string>;

Subnet mask in decimal notation, e.g. “255.255.255.0”

property network

public network: pulumi.Output<string>;

Subnet network address

property public

public public: pulumi.Output<boolean>;

boolean flag whether subnet is reachable from the Internet

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource Organization

class Organization extends CustomResource

Provides a resource to manage organization resource in Packet.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

// Create a new Project
const tfOrganization1 = new packet.Organization("tfOrganization1", {
    description: "quux",
    name: "foobar",
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/organization.html.markdown.

constructor

new Organization(name: string, args: OrganizationArgs, opts?: pulumi.CustomResourceOptions)

Create a Organization resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: OrganizationState, opts?: pulumi.CustomResourceOptions): Organization

Get an existing Organization resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Organization. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property created

public created: pulumi.Output<string>;

property description

public description: pulumi.Output<string | undefined>;

Description string.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

public logo: pulumi.Output<string | undefined>;

Logo URL.

property name

public name: pulumi.Output<string>;

The name of the Organization.

property twitter

public twitter: pulumi.Output<string | undefined>;

Twitter handle.

property updated

public updated: pulumi.Output<string>;

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property website

public website: pulumi.Output<string | undefined>;

Website link.

Resource PortVlanAttachment

class PortVlanAttachment extends CustomResource

Provides a resource to attach device ports to VLANs.

Device and VLAN must be in the same facility.

If you need this resource to add the port back to bond on removal, set forceBond = true.

To learn more about Layer 2 networking in Packet, refer to * https://support.packet.com/kb/articles/layer-2-configurations * https://support.packet.com/kb/articles/layer-2-overview

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

const testVlan = new packet.Vlan("test", {
    description: "VLAN in New Jersey",
    facility: "ewr1",
    projectId: local_project_id,
});
const testDevice = new packet.Device("test", {
    billingCycle: "hourly",
    facilities: ["ewr1"],
    hostname: "test",
    networkType: "layer2-individual",
    operatingSystem: "ubuntu1604",
    plan: "m1.xlarge.x86",
    projectId: local_project_id,
});
const testPortVlanAttachment = new packet.PortVlanAttachment("test", {
    deviceId: testDevice.id,
    portName: "eth1",
    vlanVnid: testVlan.vxlan,
});
const test1Vlan = new packet.Vlan("test1", {
    description: "VLAN in New Jersey",
    facility: "ewr1",
    projectId: local_project_id,
});
const test2Vlan = new packet.Vlan("test2", {
    description: "VLAN in New Jersey",
    facility: "ewr1",
    projectId: local_project_id,
});
const test1PortVlanAttachment = new packet.PortVlanAttachment("test1", {
    deviceId: testDevice.id,
    portName: "eth1",
    vlanVnid: test1Vlan.vxlan,
});
const test2PortVlanAttachment = new packet.PortVlanAttachment("test2", {
    deviceId: testDevice.id,
    native: true,
    portName: "eth1",
    vlanVnid: test2Vlan.vxlan,
}, {dependsOn: [test1PortVlanAttachment]});

Attribute Referece

  • id - UUID of device port used in the assignment
  • vlanId - UUID of VLAN API resource
  • portId - UUID of device port

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/port_vlan_attachment.html.markdown.

constructor

new PortVlanAttachment(name: string, args: PortVlanAttachmentArgs, opts?: pulumi.CustomResourceOptions)

Create a PortVlanAttachment resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: PortVlanAttachmentState, opts?: pulumi.CustomResourceOptions): PortVlanAttachment

Get an existing PortVlanAttachment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of PortVlanAttachment. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property deviceId

public deviceId: pulumi.Output<string>;

ID of device to be assigned to the VLAN

property forceBond

public forceBond: pulumi.Output<boolean | undefined>;

Add port back to the bond when this resource is removed. Default is false.

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property native

public native: pulumi.Output<boolean | undefined>;

Mark this VLAN a native VLAN on the port. This can be used only if this assignment assigns second or further VLAN to the port. To ensure that this attachment is not first on a port, you can use dependsOn pointing to another packet_port_vlan_attachment, just like in the layer2-individual example above.

property portId

public portId: pulumi.Output<string>;

property portName

public portName: pulumi.Output<string>;

Name of network port to be assigned to the VLAN

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property vlanId

public vlanId: pulumi.Output<string>;

property vlanVnid

public vlanVnid: pulumi.Output<number>;

VXLAN Network Identifier, integer

Resource Project

class Project extends CustomResource

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/project.html.markdown.

constructor

new Project(name: string, args: ProjectArgs, opts?: pulumi.CustomResourceOptions)

Create a Project resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ProjectState, opts?: pulumi.CustomResourceOptions): Project

Get an existing Project resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Project. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property backendTransfer

public backendTransfer: pulumi.Output<boolean | undefined>;

Enable or disable Backend Transfer, default is false

property bgpConfig

public bgpConfig: pulumi.Output<outputs.ProjectBgpConfig | undefined>;

Optional BGP settings. Refer to Packet guide for BGP.

property created

public created: pulumi.Output<string>;

The timestamp for when the project was created

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property name

public name: pulumi.Output<string>;

The name of the project

property organizationId

public organizationId: pulumi.Output<string>;

The UUID of organization under which you want to create the project. If you leave it out, the project will be create under your the default organization of your account.

property paymentMethodId

public paymentMethodId: pulumi.Output<string>;

The UUID of payment method for this project. The payment method and the project need to belong to the same organization (passed with organizationId, or default).

property updated

public updated: pulumi.Output<string>;

The timestamp for the last time the project was updated

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource ProjectSshKey

class ProjectSshKey extends CustomResource

Provides a Packet project SSH key resource to manage project-specific SSH keys. Project SSH keys will only be populated onto servers that belong to that project, in contrast to User SSH Keys.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

const projectId = "<UUID_of_your_project>";
const testProjectSshKey = new packet.ProjectSshKey("test", {
    name: "test",
    projectId: projectId,
    publicKey: "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDM/unxJeFqxsTJcu6mhqsMHSaVlpu+Jj/P+44zrm6X/MAoHSX3X9oLgujEjjZ74yLfdfe0bJrbL2YgJzNaEkIQQ1VPMHB5EhTKUBGnzlPP0hHTnxsjAm9qDHgUPgvgFDQSAMzdJRJ0Cexo16Ph9VxCoLh3dxiE7s2gaM2FdVg7P8aSxKypsxAhYV3D0AwqzoOyT6WWhBoQ0xZ85XevOTnJCpImSemEGs6nVGEsWcEc1d1YvdxFjAK4SdsKUMkj4Dsy/leKsdi/DEAf356vbMT1UHsXXvy5TlHu/Pa6qF53v32Enz+nhKy7/8W2Yt2yWx8HnQcT2rug9lvCXagJO6oauqRTO77C4QZn13ZLMZgLT66S/tNh2EX0gi6vmIs5dth8uF+K6nxIyKJXbcA4ASg7F1OJrHKFZdTc5v1cPeq6PcbqGgc+8SrPYQmzvQqLoMBuxyos2hUkYOmw3aeWJj9nFa8Wu5WaN89mUeOqSkU4S5cgUzWUOmKey56B/j/s1sVys9rMhZapVs0wL4L9GBBM48N5jAQZnnpo85A8KsZq5ME22bTLqnxsDXqDYZvS7PSI6Dxi7eleOFE/NYYDkrgDLHTQri8ucDMVeVWHgoMY2bPXdn7KKy5jW5jKsf8EPARXg77A4gRYmgKrcwIKqJEUPqyxJBe0CPoGTqgXPRsUiQ== tomk@hp2",
});
const testDevice = new packet.Device("test", {
    billingCycle: "hourly",
    facilities: ["ewr1"],
    hostname: "test",
    operatingSystem: "ubuntu1604",
    plan: "baremetal0",
    projectId: projectId,
    projectSshKeyIds: [testProjectSshKey.id],
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/project_ssh_key.html.markdown.

constructor

new ProjectSshKey(name: string, args: ProjectSshKeyArgs, opts?: pulumi.CustomResourceOptions)

Create a ProjectSshKey resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ProjectSshKeyState, opts?: pulumi.CustomResourceOptions): ProjectSshKey

Get an existing ProjectSshKey resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of ProjectSshKey. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property created

public created: pulumi.Output<string>;

The timestamp for when the SSH key was created

property fingerprint

public fingerprint: pulumi.Output<string>;

The fingerprint of the SSH key

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property name

public name: pulumi.Output<string>;

The name of the SSH key for identification

property projectId

public projectId: pulumi.Output<string>;

The ID of parent project

property publicKey

public publicKey: pulumi.Output<string>;

The public key. If this is a file, it can be read using the file interpolation function

property updated

public updated: pulumi.Output<string>;

The timestamp for the last time the SSH key was updated

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource Provider

class Provider extends ProviderResource

The provider type for the packet package. By default, resources use package-wide configuration settings, however an explicit Provider instance may be created and passed during resource construction to achieve fine-grained programmatic control over provider settings. See the documentation for more information.

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/index.html.markdown.

constructor

new Provider(name: string, args?: ProviderArgs, opts?: pulumi.ResourceOptions)

Create a Provider resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Provider. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

method register

static register(provider: ProviderResource | undefined): Promise<string | undefined>

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource ReservedIpBlock

class ReservedIpBlock extends CustomResource

Provides a resource to create and manage blocks of reserved IP addresses in a project.

When a user provisions first device in a facility, Packet API automatically allocates IPv6/56 and private IPv4/25 blocks. The new device then gets IPv6 and private IPv4 addresses from those block. It also gets a public IPv4/31 address. Every new device in the project and facility will automatically get IPv6 and private IPv4 addresses from these pre-allocated blocks. The IPv6 and private IPv4 blocks can’t be created, only imported. With this resource, it’s possible to create either public IPv4 blocks or global IPv4 blocks.

Public blocks are allocated in a facility. Addresses from public blocks can only be assigned to devices in the facility. Public blocks can have mask from /24 (256 addresses) to /32 (1 address). If you create public block with this resource, you must fill the facility argmument.

Addresses from global blocks can be assigned in any facility. Global blocks can have mask from /30 (4 addresses), to /32 (1 address). If you create global block with this resource, you must specify type = “globalIpv4” and you must omit the facility argument.

Once IP block is allocated or imported, an address from it can be assigned to device with the packet..IpAttachment resource.

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/reserved_ip_block.html.markdown.

constructor

new ReservedIpBlock(name: string, args: ReservedIpBlockArgs, opts?: pulumi.CustomResourceOptions)

Create a ReservedIpBlock resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: ReservedIpBlockState, opts?: pulumi.CustomResourceOptions): ReservedIpBlock

Get an existing ReservedIpBlock resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of ReservedIpBlock. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property address

public address: pulumi.Output<string>;

property addressFamily

public addressFamily: pulumi.Output<number>;

Address family as integer (4 or 6)

property cidr

public cidr: pulumi.Output<number>;

length of CIDR prefix of the block as integer

property cidrNotation

public cidrNotation: pulumi.Output<string>;

Address and mask in CIDR notation, e.g. “147.229.15.30/31”

property description

public description: pulumi.Output<string | undefined>;

Arbitrary description

property facility

public facility: pulumi.Output<Facility | undefined>;

Facility where to allocate the public IP address block, makes sense only for type==public_ipv4, must be empty for type==global_ipv4

property gateway

public gateway: pulumi.Output<string>;

property global

public global: pulumi.Output<boolean>;

boolean flag whether addresses from a block are global (i.e. can be assigned in any facility)

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property manageable

public manageable: pulumi.Output<boolean>;

property management

public management: pulumi.Output<boolean>;

property netmask

public netmask: pulumi.Output<string>;

Mask in decimal notation, e.g. “255.255.255.0”

property network

public network: pulumi.Output<string>;

Network IP address portion of the block specification

property projectId

public projectId: pulumi.Output<string>;

The packet project ID where to allocate the address block

property public

public public: pulumi.Output<boolean>;

boolean flag whether addresses from a block are public

property quantity

public quantity: pulumi.Output<number>;

The number of allocated /32 addresses, a power of 2

property type

public type: pulumi.Output<IpBlockType | undefined>;

Either “globalIpv4” or “publicIpv4”, defaults to “publicIpv4” for backward compatibility

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource SpotMarketRequest

class SpotMarketRequest extends CustomResource

Provides a Packet Spot Market Request resource to allow you to manage spot market requests on your account. https://support.packet.com/kb/articles/spot-market

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

// Create a spot market request
const req = new packet.SpotMarketRequest("req", {
    devicesMax: 1,
    devicesMin: 1,
    facilities: ["ewr1"],
    instanceParameters: {
        billingCycle: "hourly",
        hostname: "testspot",
        operatingSystem: "coreosStable",
        plan: "t1.small.x86",
    },
    maxBidPrice: 0.03,
    projectId: local_project_id,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/spot_market_request.html.markdown.

constructor

new SpotMarketRequest(name: string, args: SpotMarketRequestArgs, opts?: pulumi.CustomResourceOptions)

Create a SpotMarketRequest resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: SpotMarketRequestState, opts?: pulumi.CustomResourceOptions): SpotMarketRequest

Get an existing SpotMarketRequest resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of SpotMarketRequest. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property devicesMax

public devicesMax: pulumi.Output<number>;

Maximum number devices to be created

property devicesMin

public devicesMin: pulumi.Output<number>;

Miniumum number devices to be created

property facilities

public facilities: pulumi.Output<string[]>;

Facility IDs where devices should be created

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property instanceParameters

public instanceParameters: pulumi.Output<outputs.SpotMarketRequestInstanceParameters>;

Device parameters. See device resource for details

property maxBidPrice

public maxBidPrice: pulumi.Output<number>;

Maximum price user is willing to pay per hour per device

property projectId

public projectId: pulumi.Output<string>;

Project ID

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property waitForDevices

public waitForDevices: pulumi.Output<boolean | undefined>;

On resource creation - wait until all desired devices are active, on resource destruction - wait until devices are removed

Resource SshKey

class SshKey extends CustomResource

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/ssh_key.html.markdown.

constructor

new SshKey(name: string, args: SshKeyArgs, opts?: pulumi.CustomResourceOptions)

Create a SshKey resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: SshKeyState, opts?: pulumi.CustomResourceOptions): SshKey

Get an existing SshKey resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of SshKey. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property created

public created: pulumi.Output<string>;

The timestamp for when the SSH key was created

property fingerprint

public fingerprint: pulumi.Output<string>;

The fingerprint of the SSH key

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property name

public name: pulumi.Output<string>;

The name of the SSH key for identification

property publicKey

public publicKey: pulumi.Output<string>;

The public key. If this is a file, it can be read using the file interpolation function

property updated

public updated: pulumi.Output<string>;

The timestamp for the last time the SSH key was updated

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource Vlan

class Vlan extends CustomResource

Provides a resource to allow users to manage Virtual Networks in their projects.

To learn more about Layer 2 networking in Packet, refer to * https://support.packet.com/kb/articles/layer-2-configurations * https://support.packet.com/kb/articles/layer-2-overview

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

const vlan1 = new packet.Vlan("vlan1", {
    description: "VLAN in New Jersey",
    facility: "ewr1",
    projectId: local_project_id,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/vlan.html.markdown.

constructor

new Vlan(name: string, args: VlanArgs, opts?: pulumi.CustomResourceOptions)

Create a Vlan resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: VlanState, opts?: pulumi.CustomResourceOptions): Vlan

Get an existing Vlan resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Vlan. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property description

public description: pulumi.Output<string | undefined>;

Description string

property facility

public facility: pulumi.Output<Facility>;

Facility where to create the VLAN

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property projectId

public projectId: pulumi.Output<string>;

ID of parent project

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property vxlan

public vxlan: pulumi.Output<number>;

VXLAN segment ID

Resource Volume

class Volume extends CustomResource

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/volume.html.markdown.

constructor

new Volume(name: string, args: VolumeArgs, opts?: pulumi.CustomResourceOptions)

Create a Volume resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: VolumeState, opts?: pulumi.CustomResourceOptions): Volume

Get an existing Volume resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of Volume. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property attachments

public attachments: pulumi.Output<outputs.VolumeAttachment[]>;

A list of attachments, each with it’s own href attribute

property billingCycle

public billingCycle: pulumi.Output<BillingCycle>;

The billing cycle, defaults to “hourly”

property created

public created: pulumi.Output<string>;

The timestamp for when the volume was created

property description

public description: pulumi.Output<string | undefined>;

Optional description for the volume

property facility

public facility: pulumi.Output<Facility>;

The facility to create the volume in

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property locked

public locked: pulumi.Output<boolean | undefined>;

Lock or unlock the volume

property name

public name: pulumi.Output<string>;

The name of the volume

property plan

public plan: pulumi.Output<string>;

The service plan slug of the volume

property projectId

public projectId: pulumi.Output<string>;

The packet project ID to deploy the volume in

property size

public size: pulumi.Output<number>;

The size in GB to make the volume

property snapshotPolicies

public snapshotPolicies: pulumi.Output<outputs.VolumeSnapshotPolicy[] | undefined>;

Optional list of snapshot policies

property state

public state: pulumi.Output<string>;

The state of the volume

property updated

public updated: pulumi.Output<string>;

The timestamp for the last time the volume was updated

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

Resource VolumeAttachment

class VolumeAttachment extends CustomResource

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/r/volume_attachment.html.markdown.

constructor

new VolumeAttachment(name: string, args: VolumeAttachmentArgs, opts?: pulumi.CustomResourceOptions)

Create a VolumeAttachment resource with the given unique name, arguments, and options.

  • name The unique name of the resource.
  • args The arguments to use to populate this resource's properties.
  • opts A bag of options that control this resource's behavior.

method get

public static get(name: string, id: pulumi.Input<pulumi.ID>, state?: VolumeAttachmentState, opts?: pulumi.CustomResourceOptions): VolumeAttachment

Get an existing VolumeAttachment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

method getProvider

getProvider(moduleMember: string): ProviderResource | undefined

method isInstance

public static isInstance(obj: any): boolean

Returns true if the given object is an instance of VolumeAttachment. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

property deviceId

public deviceId: pulumi.Output<string>;

The ID of the device to which the volume should be attached

property id

id: Output<ID>;

id is the provider-assigned unique ID for this managed resource. It is set during deployments and may be missing (undefined) during planning phases.

property urn

urn: Output<URN>;

urn is the stable logical URN used to distinctly address a resource, both before and after deployments.

property volumeId

public volumeId: pulumi.Output<string>;

The ID of the volume to attach

Data Sources

Data Source getDevice

getDevice(args: GetDeviceArgs, opts?: pulumi.InvokeOptions): Promise<GetDeviceResult> & GetDeviceResult

Provides a Packet device datasource.

Note: All arguments including the rootPassword and userData will be stored in the raw state as plain-text. Read more about sensitive data in state.

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/d/device.html.markdown.

Data Source getOperatingSystem

getOperatingSystem(args?: GetOperatingSystemArgs, opts?: pulumi.InvokeOptions): Promise<GetOperatingSystemResult> & GetOperatingSystemResult

Use this data source to get Packet Operating System image.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

const example = packet.getOperatingSystem({
    distro: "coreos",
    name: "Container Linux",
    provisionableOn: "c1.small.x86",
    version: "alpha",
});
const server = new packet.Device("server", {
    billingCycle: "hourly",
    facilities: ["ewr1"],
    hostname: "tf.coreos2",
    operatingSystem: example.id,
    plan: "c1.small.x86",
    projectId: local_project_id,
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/d/operating_system.html.markdown.

Data Source getPrecreatedIpBlock

getPrecreatedIpBlock(args: GetPrecreatedIpBlockArgs, opts?: pulumi.InvokeOptions): Promise<GetPrecreatedIpBlockResult> & GetPrecreatedIpBlockResult

Use this data source to get CIDR expression for precreated IPv6 and IPv4 blocks in Packet. You can then use the cidrsubnet TF builtin function to derive subnets.

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/d/precreated_ip_block.html.markdown.

Data Source getSpotMarketPrice

getSpotMarketPrice(args: GetSpotMarketPriceArgs, opts?: pulumi.InvokeOptions): Promise<GetSpotMarketPriceResult> & GetSpotMarketPriceResult

Use this data source to get Packet Spot Market Price.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as packet from "@pulumi/packet";

const example = packet.getSpotMarketPrice({
    facility: "ewr1",
    plan: "c1.small.x86",
});

This content is derived from https://github.com/terraform-providers/terraform-provider-packet/blob/master/website/docs/d/spot_market_price.html.markdown.

Others

interface BgpSessionArgs

interface BgpSessionArgs

The set of arguments for constructing a BgpSession resource.

property addressFamily

addressFamily: pulumi.Input<string>;

ipv4 or ipv6

property defaultRoute

defaultRoute?: pulumi.Input<boolean>;

Boolean flag to set the default route policy. False by default.

property deviceId

deviceId: pulumi.Input<string>;

ID of device

interface BgpSessionState

interface BgpSessionState

Input properties used for looking up and filtering BgpSession resources.

property addressFamily

addressFamily?: pulumi.Input<string>;

ipv4 or ipv6

property defaultRoute

defaultRoute?: pulumi.Input<boolean>;

Boolean flag to set the default route policy. False by default.

property deviceId

deviceId?: pulumi.Input<string>;

ID of device

property status

status?: pulumi.Input<string>;

type BillingCycle

type BillingCycle = "hourly" | "monthly";

interface ConnectArgs

interface ConnectArgs

The set of arguments for constructing a Connect resource.

property facility

facility: pulumi.Input<Facility>;

Facility where to create the VLAN

property name

name: pulumi.Input<string>;

Name for the Connect resource

property portSpeed

portSpeed: pulumi.Input<number>;

Port speed in Mbps

property projectId

projectId: pulumi.Input<string>;

ID of parent project

property providerId

providerId: pulumi.Input<string>;

ID of Connect Provider. Provider IDs are * Azure ExpressRoute - “ed5de8e0-77a9-4d3b-9de0-65281d3aa831”

property providerPayload

providerPayload: pulumi.Input<string>;

Authorization key for the Connect provider

property vxlan

vxlan: pulumi.Input<number>;

VXLAN Network identifier of the linked Packet VLAN

interface ConnectState

interface ConnectState

Input properties used for looking up and filtering Connect resources.

property facility

facility?: pulumi.Input<Facility>;

Facility where to create the VLAN

property name

name?: pulumi.Input<string>;

Name for the Connect resource

property portSpeed

portSpeed?: pulumi.Input<number>;

Port speed in Mbps

property projectId

projectId?: pulumi.Input<string>;

ID of parent project

property providerId

providerId?: pulumi.Input<string>;

ID of Connect Provider. Provider IDs are * Azure ExpressRoute - “ed5de8e0-77a9-4d3b-9de0-65281d3aa831”

property providerPayload

providerPayload?: pulumi.Input<string>;

Authorization key for the Connect provider

property status

status?: pulumi.Input<string>;

Status of the Connect resource, one of PROVISIONING, PROVISIONED, DEPROVISIONING, DEPROVISIONED

property vxlan

vxlan?: pulumi.Input<number>;

VXLAN Network identifier of the linked Packet VLAN

interface DeviceArgs

interface DeviceArgs

The set of arguments for constructing a Device resource.

property alwaysPxe

alwaysPxe?: pulumi.Input<boolean>;

If true, a device with OS customIpxe will continue to boot via iPXE on reboots.

property billingCycle

billingCycle: pulumi.Input<BillingCycle>;

monthly or hourly

property description

description?: pulumi.Input<string>;

Description string for the device

property facilities

facilities: pulumi.Input<pulumi.Input<Facility>[]>;

List of facility codes with deployment preferences. Packet API will go through the list and will deploy your device to first facility with free capacity. List items must be facility codes or any (a wildcard). To find the facility code, visit Facilities API docs, set your API auth token in the top of the page and see JSON from the API response.

property hardwareReservationId

hardwareReservationId?: pulumi.Input<string>;

The full ID of the hardware reservation where you want this device deployed, or next-available if you want to pick your next available reservation automatically.

property hostname

hostname: pulumi.Input<string>;

The device name

property ipAddressTypes

ipAddressTypes?: pulumi.Input<pulumi.Input<IpAddressType>[]>;

A set containing one or more of [privateIpv4, publicIpv4, publicIpv6]. It specifies which IP address types a new device should obtain. If omitted, a created device will obtain all 3 addresses. If you only want private IPv4 address for the new device, pass [privateIpv4].

property ipxeScriptUrl

ipxeScriptUrl?: pulumi.Input<string>;

URL pointing to a hosted iPXE script. More information is in the Custom iPXE doc.

property networkType

networkType?: pulumi.Input<NetworkType>;

property operatingSystem

operatingSystem: pulumi.Input<OperatingSystem>;

The operating system slug. To find the slug, or visit Operating Systems API docs, set your API auth token in the top of the page and see JSON from the API response.

property plan

plan: pulumi.Input<Plan>;

The device plan slug. To find the plan slug, visit Device plans API docs, set your auth token in the top of the page and see JSON from the API response.

property projectId

projectId: pulumi.Input<string>;

The ID of the project in which to create the device

property projectSshKeyIds

projectSshKeyIds?: pulumi.Input<pulumi.Input<string>[]>;

Array of IDs of the project SSH keys which should be added to the device. If you omit this, SSH keys of all the members of the parent project will be added to the device. If you specify this array, only the listed project SSH keys will be added. Project SSH keys can be created with the [packet..ProjectSshKey][packet_project_ssh_key.html] resource.

property publicIpv4SubnetSize

publicIpv4SubnetSize?: pulumi.Input<number>;

Size of allocated subnet, more information is in the Custom Subnet Size doc.

property storage

storage?: pulumi.Input<string>;

JSON for custom partitioning. Only usable on reserved hardware. More information in in the Custom Partitioning and RAID doc.

property tags

tags?: pulumi.Input<pulumi.Input<string>[]>;

Tags attached to the device

property userData

userData?: pulumi.Input<string>;

A string of the desired User Data for the device.

property waitForReservationDeprovision

waitForReservationDeprovision?: pulumi.Input<boolean>;

Only used for devices in reserved hardware. If set, the deletion of this device will block until the hardware reservation is marked provisionable (about 4 minutes in August 2019).

interface DeviceState

interface DeviceState

Input properties used for looking up and filtering Device resources.

property accessPrivateIpv4

accessPrivateIpv4?: pulumi.Input<string>;

The ipv4 private IP assigned to the device

property accessPublicIpv4

accessPublicIpv4?: pulumi.Input<string>;

The ipv4 maintenance IP assigned to the device

property accessPublicIpv6

accessPublicIpv6?: pulumi.Input<string>;

The ipv6 maintenance IP assigned to the device

property alwaysPxe

alwaysPxe?: pulumi.Input<boolean>;

If true, a device with OS customIpxe will continue to boot via iPXE on reboots.

property billingCycle

billingCycle?: pulumi.Input<BillingCycle>;

monthly or hourly

property created

created?: pulumi.Input<string>;

The timestamp for when the device was created

property deployedFacility

deployedFacility?: pulumi.Input<string>;

The facility where the device is deployed.

property description

description?: pulumi.Input<string>;

Description string for the device

property facilities

facilities?: pulumi.Input<pulumi.Input<Facility>[]>;

List of facility codes with deployment preferences. Packet API will go through the list and will deploy your device to first facility with free capacity. List items must be facility codes or any (a wildcard). To find the facility code, visit Facilities API docs, set your API auth token in the top of the page and see JSON from the API response.

property hardwareReservationId

hardwareReservationId?: pulumi.Input<string>;

The full ID of the hardware reservation where you want this device deployed, or next-available if you want to pick your next available reservation automatically.

property hostname

hostname?: pulumi.Input<string>;

The device name

property ipAddressTypes

ipAddressTypes?: pulumi.Input<pulumi.Input<IpAddressType>[]>;

A set containing one or more of [privateIpv4, publicIpv4, publicIpv6]. It specifies which IP address types a new device should obtain. If omitted, a created device will obtain all 3 addresses. If you only want private IPv4 address for the new device, pass [privateIpv4].

property ipxeScriptUrl

ipxeScriptUrl?: pulumi.Input<string>;

URL pointing to a hosted iPXE script. More information is in the Custom iPXE doc.

property locked

locked?: pulumi.Input<boolean>;

Whether the device is locked

property networkType

networkType?: pulumi.Input<NetworkType>;

property networks

networks?: pulumi.Input<pulumi.Input<inputs.DeviceNetwork>[]>;

The device’s private and public IP (v4 and v6) network details. When a device is run without any special network configuration, it will have 3 networks: * Public IPv4 at packet_device.name.network.0 * IPv6 at packet_device.name.network.1 * Private IPv4 at packet_device.name.network.2 Elastic addresses then stack by type - an assigned public IPv4 will go after the management public IPv4 (to index 1), and will then shift the indices of the IPv6 and private IPv4. Assigned private IPv4 will go after the management private IPv4 (to the end of the network list). The fields of the network attributes are:

property operatingSystem

operatingSystem?: pulumi.Input<OperatingSystem>;

The operating system slug. To find the slug, or visit Operating Systems API docs, set your API auth token in the top of the page and see JSON from the API response.

property plan

plan?: pulumi.Input<Plan>;

The device plan slug. To find the plan slug, visit Device plans API docs, set your auth token in the top of the page and see JSON from the API response.

property ports

ports?: pulumi.Input<pulumi.Input<inputs.DevicePort>[]>;

Ports assigned to the device

property projectId

projectId?: pulumi.Input<string>;

The ID of the project in which to create the device

property projectSshKeyIds

projectSshKeyIds?: pulumi.Input<pulumi.Input<string>[]>;

Array of IDs of the project SSH keys which should be added to the device. If you omit this, SSH keys of all the members of the parent project will be added to the device. If you specify this array, only the listed project SSH keys will be added. Project SSH keys can be created with the [packet..ProjectSshKey][packet_project_ssh_key.html] resource.

property publicIpv4SubnetSize

publicIpv4SubnetSize?: pulumi.Input<number>;

Size of allocated subnet, more information is in the Custom Subnet Size doc.

property rootPassword

rootPassword?: pulumi.Input<string>;

Root password to the server (disabled after 24 hours)

property sshKeyIds

sshKeyIds?: pulumi.Input<pulumi.Input<string>[]>;

List of IDs of SSH keys deployed in the device, can be both user and project SSH keys

property state

state?: pulumi.Input<string>;

The status of the device

property storage

storage?: pulumi.Input<string>;

JSON for custom partitioning. Only usable on reserved hardware. More information in in the Custom Partitioning and RAID doc.

property tags

tags?: pulumi.Input<pulumi.Input<string>[]>;

Tags attached to the device

property updated

updated?: pulumi.Input<string>;

The timestamp for the last time the device was updated

property userData

userData?: pulumi.Input<string>;

A string of the desired User Data for the device.

property waitForReservationDeprovision

waitForReservationDeprovision?: pulumi.Input<boolean>;

Only used for devices in reserved hardware. If set, the deletion of this device will block until the hardware reservation is marked provisionable (about 4 minutes in August 2019).

type Facility

type Facility = "ewr1" | "sjc1" | "dfw1" | "dfw2" | "ams1" | "nrt1" | "sea1" | "lax1" | "ord1" | "atl1" | "iad1" | "sin1" | "hkg1" | "syd1" | "mrs1" | "yyz1" | "fra2";

A Facility represents any valid Packet.net facility that may be targeted with deployments.

interface GetDeviceArgs

interface GetDeviceArgs

A collection of arguments for invoking getDevice.

property description

description?: undefined | string;

property hostname

hostname: string;

The device name

property projectId

projectId: string;

The id of the project in which the devices exists

interface GetDeviceResult

interface GetDeviceResult

A collection of values returned by getDevice.

property accessPrivateIpv4

accessPrivateIpv4: string;

The ipv4 private IP assigned to the device

property accessPublicIpv4

accessPublicIpv4: string;

The ipv4 management IP assigned to the device

property accessPublicIpv6

accessPublicIpv6: string;

The ipv6 management IP assigned to the device

property alwaysPxe

alwaysPxe: boolean;

property billingCycle

billingCycle: string;

The billing cycle of the device (monthly or hourly)

property description

description?: undefined | string;

Description string for the device

property facility

facility: string;

The facility where the device is deployed.

property hardwareReservationId

hardwareReservationId: string;

The id of hardware reservation which this device occupies

property hostname

hostname: string;

property id

id: string;

ID of the port

property ipxeScriptUrl

ipxeScriptUrl: string;

property networkType

networkType: string;

L2 network type of the device, one of “layer3”, “layer2-bonded”, “layer2-individual”, “hybrid”

property networks

networks: outputs.GetDeviceNetwork[];

The device’s private and public IP (v4 and v6) network details. When a device is run without any special network configuration, it will have 3 networks: * Public IPv4 at packet_device.name.network.0 * IPv6 at packet_device.name.network.1 * Private IPv4 at packet_device.name.network.2 Elastic addresses then stack by type - an assigned public IPv4 will go after the management public IPv4 (to index 1), and will then shift the indices of the IPv6 and private IPv4. Assigned private IPv4 will go after the management private IPv4 (to the end of the network list). The fields of the network attributes are:

property operatingSystem

operatingSystem: string;

The operating system running on the device

property plan

plan: string;

The hardware config of the device

property ports

ports: outputs.GetDevicePort[];

Ports assigned to the device

property projectId

projectId: string;

property publicIpv4SubnetSize

publicIpv4SubnetSize: number;

property rootPassword

rootPassword: string;

Root password to the server (if still available)

property sshKeyIds

sshKeyIds: string[];

List of IDs of SSH keys deployed in the device, can be both user or project SSH keys

property state

state: string;

The state of the device

property storage

storage: string;

property tags

tags: string[];

Tags attached to the device

function getEnv

getEnv(vars: string[]): string | undefined

function getEnvBoolean

getEnvBoolean(vars: string[]): boolean | undefined

function getEnvNumber

getEnvNumber(vars: string[]): number | undefined

interface GetOperatingSystemArgs

interface GetOperatingSystemArgs

A collection of arguments for invoking getOperatingSystem.

property distro

distro?: undefined | string;

Name of the OS distribution.

property name

name?: undefined | string;

Name or part of the name of the distribution. Case insensitive.

property provisionableOn

provisionableOn?: undefined | string;

Plan name.

property version

version?: undefined | string;

Version of the distribution

interface GetOperatingSystemResult

interface GetOperatingSystemResult

A collection of values returned by getOperatingSystem.

property distro

distro?: undefined | string;

property id

id: string;

id is the provider-assigned unique ID for this managed resource.

property name

name?: undefined | string;

property provisionableOn

provisionableOn?: undefined | string;

property slug

slug: string;

Operating system slug (same as id)

property version

version?: undefined | string;

interface GetPrecreatedIpBlockArgs

interface GetPrecreatedIpBlockArgs

A collection of arguments for invoking getPrecreatedIpBlock.

property addressFamily

addressFamily: number;

4 or 6, depending on which block you are looking for.

property facility

facility?: undefined | string;

Facility of the searched block. (Optional) Only allowed for non-global blocks.

property global

global?: undefined | false | true;

Whether to look for global block. Default is false for backward compatibility.

property projectId

projectId: string;

ID of the project where the searched block should be.

property public

public: boolean;

Whether to look for public or private block.

interface GetPrecreatedIpBlockResult

interface GetPrecreatedIpBlockResult

A collection of values returned by getPrecreatedIpBlock.

property address

address: string;

property addressFamily

addressFamily: number;

property cidr

cidr: number;

property cidrNotation

cidrNotation: string;

CIDR notation of the looked up block.

property facility

facility?: undefined | string;

property gateway

gateway: string;

property global

global?: undefined | false | true;

property id

id: string;

id is the provider-assigned unique ID for this managed resource.

property manageable

manageable: boolean;

property management

management: boolean;

property netmask

netmask: string;

property network

network: string;

property projectId

projectId: string;

property public

public: boolean;

property quantity

quantity: number;

interface GetSpotMarketPriceArgs

interface GetSpotMarketPriceArgs

A collection of arguments for invoking getSpotMarketPrice.

property facility

facility: string;

Name of the facility.

property plan

plan: string;

Name of the plan.

interface GetSpotMarketPriceResult

interface GetSpotMarketPriceResult

A collection of values returned by getSpotMarketPrice.

property facility

facility: string;

property id

id: string;

id is the provider-assigned unique ID for this managed resource.

property plan

plan: string;

property price

price: number;

Current spot market price for given plan in given facility.

function getVersion

getVersion(): string

type IpAddressType

type IpAddressType = "private_ipv4" | "public_ipv4" | "public_ipv6";

interface IpAttachmentArgs

interface IpAttachmentArgs

The set of arguments for constructing a IpAttachment resource.

property cidrNotation

cidrNotation: pulumi.Input<string>;

CIDR notation of subnet from block reserved in the same project and facility as the device

property deviceId

deviceId: pulumi.Input<string>;

ID of device to which to assign the subnet

interface IpAttachmentState

interface IpAttachmentState

Input properties used for looking up and filtering IpAttachment resources.

property address

address?: pulumi.Input<string>;

property addressFamily

addressFamily?: pulumi.Input<number>;

Address family as integer (4 or 6)

property cidr

cidr?: pulumi.Input<number>;

length of CIDR prefix of the subnet as integer

property cidrNotation

cidrNotation?: pulumi.Input<string>;

CIDR notation of subnet from block reserved in the same project and facility as the device

property deviceId

deviceId?: pulumi.Input<string>;

ID of device to which to assign the subnet

property gateway

gateway?: pulumi.Input<string>;

IP address of gateway for the subnet

property global

global?: pulumi.Input<boolean>;

property manageable

manageable?: pulumi.Input<boolean>;

property management

management?: pulumi.Input<boolean>;

property netmask

netmask?: pulumi.Input<string>;

Subnet mask in decimal notation, e.g. “255.255.255.0”

property network

network?: pulumi.Input<string>;

Subnet network address

property public

public?: pulumi.Input<boolean>;

boolean flag whether subnet is reachable from the Internet

type IpBlockType

type IpBlockType = "global_ipv4" | "public_ipv4";

type NetworkType

type NetworkType = "layer3" | "hybrid" | "layer2-individual" | "layer2-bonded";

type OperatingSystem

type OperatingSystem = "alpine_3" | "centos_6" | "centos_7" | "coreos_alpha" | "coreos_beta" | "coreos_stable" | "custom_ipxe" | "debian_8" | "debian_9" | "freebsd_10_4" | "freebsd_11_1" | "freebsd_11_2" | "freebsd_12_testing" | "nixos_18_03" | "nixos_19_03" | "opensuse_42_3" | "rancher" | "rhel_7" | "scientific_6" | "suse_sles12_sp3" | "ubuntu_14_04" | "ubuntu_16_04" | "ubuntu_17_10" | "ubuntu_18_04" | "vmware_esxi_6_5" | "windows_2012_r2" | "windows_2016";

interface OrganizationArgs

interface OrganizationArgs

The set of arguments for constructing a Organization resource.

property description

description?: pulumi.Input<string>;

Description string.

logo?: pulumi.Input<string>;

Logo URL.

property name

name: pulumi.Input<string>;

The name of the Organization.

property twitter

twitter?: pulumi.Input<string>;

Twitter handle.

property website

website?: pulumi.Input<string>;

Website link.

interface OrganizationState

interface OrganizationState

Input properties used for looking up and filtering Organization resources.

property created

created?: pulumi.Input<string>;

property description

description?: pulumi.Input<string>;

Description string.

logo?: pulumi.Input<string>;

Logo URL.

property name

name?: pulumi.Input<string>;

The name of the Organization.

property twitter

twitter?: pulumi.Input<string>;

Twitter handle.

property updated

updated?: pulumi.Input<string>;

property website

website?: pulumi.Input<string>;

Website link.

type Plan

type Plan = "c2.large.arm" | "c2.medium.x86" | "g2.large.x86" | "m2.xlarge.x86" | "x2.xlarge.x86" | "baremetal_2a" | "baremetal_1" | "baremetal_3" | "baremetal_2" | "baremetal_s" | "baremetal_0" | "baremetal_1e";

A Plan represents any valid Packet.net Plan that may be deployed.

interface PortVlanAttachmentArgs

interface PortVlanAttachmentArgs

The set of arguments for constructing a PortVlanAttachment resource.

property deviceId

deviceId: pulumi.Input<string>;

ID of device to be assigned to the VLAN

property forceBond

forceBond?: pulumi.Input<boolean>;

Add port back to the bond when this resource is removed. Default is false.

property native

native?: pulumi.Input<boolean>;

Mark this VLAN a native VLAN on the port. This can be used only if this assignment assigns second or further VLAN to the port. To ensure that this attachment is not first on a port, you can use dependsOn pointing to another packet_port_vlan_attachment, just like in the layer2-individual example above.

property portName

portName: pulumi.Input<string>;

Name of network port to be assigned to the VLAN

property vlanVnid

vlanVnid: pulumi.Input<number>;

VXLAN Network Identifier, integer

interface PortVlanAttachmentState

interface PortVlanAttachmentState

Input properties used for looking up and filtering PortVlanAttachment resources.

property deviceId

deviceId?: pulumi.Input<string>;

ID of device to be assigned to the VLAN

property forceBond

forceBond?: pulumi.Input<boolean>;

Add port back to the bond when this resource is removed. Default is false.

property native

native?: pulumi.Input<boolean>;

Mark this VLAN a native VLAN on the port. This can be used only if this assignment assigns second or further VLAN to the port. To ensure that this attachment is not first on a port, you can use dependsOn pointing to another packet_port_vlan_attachment, just like in the layer2-individual example above.

property portId

portId?: pulumi.Input<string>;

property portName

portName?: pulumi.Input<string>;

Name of network port to be assigned to the VLAN

property vlanId

vlanId?: pulumi.Input<string>;

property vlanVnid

vlanVnid?: pulumi.Input<number>;

VXLAN Network Identifier, integer

interface ProjectArgs

interface ProjectArgs

The set of arguments for constructing a Project resource.

property backendTransfer

backendTransfer?: pulumi.Input<boolean>;

Enable or disable Backend Transfer, default is false

property bgpConfig

bgpConfig?: pulumi.Input<inputs.ProjectBgpConfig>;

Optional BGP settings. Refer to Packet guide for BGP.

property name

name: pulumi.Input<string>;

The name of the project

property organizationId

organizationId?: pulumi.Input<string>;

The UUID of organization under which you want to create the project. If you leave it out, the project will be create under your the default organization of your account.

property paymentMethodId

paymentMethodId?: pulumi.Input<string>;

The UUID of payment method for this project. The payment method and the project need to belong to the same organization (passed with organizationId, or default).

interface ProjectSshKeyArgs

interface ProjectSshKeyArgs

The set of arguments for constructing a ProjectSshKey resource.

property name

name: pulumi.Input<string>;

The name of the SSH key for identification

property projectId

projectId: pulumi.Input<string>;

The ID of parent project

property publicKey

publicKey: pulumi.Input<string>;

The public key. If this is a file, it can be read using the file interpolation function

interface ProjectSshKeyState

interface ProjectSshKeyState

Input properties used for looking up and filtering ProjectSshKey resources.

property created

created?: pulumi.Input<string>;

The timestamp for when the SSH key was created

property fingerprint

fingerprint?: pulumi.Input<string>;

The fingerprint of the SSH key

property name

name?: pulumi.Input<string>;

The name of the SSH key for identification

property projectId

projectId?: pulumi.Input<string>;

The ID of parent project

property publicKey

publicKey?: pulumi.Input<string>;

The public key. If this is a file, it can be read using the file interpolation function

property updated

updated?: pulumi.Input<string>;

The timestamp for the last time the SSH key was updated

interface ProjectState

interface ProjectState

Input properties used for looking up and filtering Project resources.

property backendTransfer

backendTransfer?: pulumi.Input<boolean>;

Enable or disable Backend Transfer, default is false

property bgpConfig

bgpConfig?: pulumi.Input<inputs.ProjectBgpConfig>;

Optional BGP settings. Refer to Packet guide for BGP.

property created

created?: pulumi.Input<string>;

The timestamp for when the project was created

property name

name?: pulumi.Input<string>;

The name of the project

property organizationId

organizationId?: pulumi.Input<string>;

The UUID of organization under which you want to create the project. If you leave it out, the project will be create under your the default organization of your account.

property paymentMethodId

paymentMethodId?: pulumi.Input<string>;

The UUID of payment method for this project. The payment method and the project need to belong to the same organization (passed with organizationId, or default).

property updated

updated?: pulumi.Input<string>;

The timestamp for the last time the project was updated

interface ProviderArgs

interface ProviderArgs

The set of arguments for constructing a Provider resource.

property authToken

authToken?: pulumi.Input<string>;

The API auth key for API operations.

interface ReservedIpBlockArgs

interface ReservedIpBlockArgs

The set of arguments for constructing a ReservedIpBlock resource.

property description

description?: pulumi.Input<string>;

Arbitrary description

property facility

facility?: pulumi.Input<Facility>;

Facility where to allocate the public IP address block, makes sense only for type==public_ipv4, must be empty for type==global_ipv4

property projectId

projectId: pulumi.Input<string>;

The packet project ID where to allocate the address block

property quantity

quantity: pulumi.Input<number>;

The number of allocated /32 addresses, a power of 2

property type

type?: pulumi.Input<IpBlockType>;

Either “globalIpv4” or “publicIpv4”, defaults to “publicIpv4” for backward compatibility

interface ReservedIpBlockState

interface ReservedIpBlockState

Input properties used for looking up and filtering ReservedIpBlock resources.

property address

address?: pulumi.Input<string>;

property addressFamily

addressFamily?: pulumi.Input<number>;

Address family as integer (4 or 6)

property cidr

cidr?: pulumi.Input<number>;

length of CIDR prefix of the block as integer

property cidrNotation

cidrNotation?: pulumi.Input<string>;

Address and mask in CIDR notation, e.g. “147.229.15.30/31”

property description

description?: pulumi.Input<string>;

Arbitrary description

property facility

facility?: pulumi.Input<Facility>;

Facility where to allocate the public IP address block, makes sense only for type==public_ipv4, must be empty for type==global_ipv4

property gateway

gateway?: pulumi.Input<string>;

property global

global?: pulumi.Input<boolean>;

boolean flag whether addresses from a block are global (i.e. can be assigned in any facility)

property manageable

manageable?: pulumi.Input<boolean>;

property management

management?: pulumi.Input<boolean>;

property netmask

netmask?: pulumi.Input<string>;

Mask in decimal notation, e.g. “255.255.255.0”

property network

network?: pulumi.Input<string>;

Network IP address portion of the block specification

property projectId

projectId?: pulumi.Input<string>;

The packet project ID where to allocate the address block

property public

public?: pulumi.Input<boolean>;

boolean flag whether addresses from a block are public

property quantity

quantity?: pulumi.Input<number>;

The number of allocated /32 addresses, a power of 2

property type

type?: pulumi.Input<IpBlockType>;

Either “globalIpv4” or “publicIpv4”, defaults to “publicIpv4” for backward compatibility

interface SpotMarketRequestArgs

interface SpotMarketRequestArgs

The set of arguments for constructing a SpotMarketRequest resource.

property devicesMax

devicesMax: pulumi.Input<number>;

Maximum number devices to be created

property devicesMin

devicesMin: pulumi.Input<number>;

Miniumum number devices to be created

property facilities

facilities: pulumi.Input<pulumi.Input<string>[]>;

Facility IDs where devices should be created

property instanceParameters

instanceParameters: pulumi.Input<inputs.SpotMarketRequestInstanceParameters>;

Device parameters. See device resource for details

property maxBidPrice

maxBidPrice: pulumi.Input<number>;

Maximum price user is willing to pay per hour per device

property projectId

projectId: pulumi.Input<string>;

Project ID

property waitForDevices

waitForDevices?: pulumi.Input<boolean>;

On resource creation - wait until all desired devices are active, on resource destruction - wait until devices are removed

interface SpotMarketRequestState

interface SpotMarketRequestState

Input properties used for looking up and filtering SpotMarketRequest resources.

property devicesMax

devicesMax?: pulumi.Input<number>;

Maximum number devices to be created

property devicesMin

devicesMin?: pulumi.Input<number>;

Miniumum number devices to be created

property facilities

facilities?: pulumi.Input<pulumi.Input<string>[]>;

Facility IDs where devices should be created

property instanceParameters

instanceParameters?: pulumi.Input<inputs.SpotMarketRequestInstanceParameters>;

Device parameters. See device resource for details

property maxBidPrice

maxBidPrice?: pulumi.Input<number>;

Maximum price user is willing to pay per hour per device

property projectId

projectId?: pulumi.Input<string>;

Project ID

property waitForDevices

waitForDevices?: pulumi.Input<boolean>;

On resource creation - wait until all desired devices are active, on resource destruction - wait until devices are removed

interface SshKeyArgs

interface SshKeyArgs

The set of arguments for constructing a SshKey resource.

property name

name: pulumi.Input<string>;

The name of the SSH key for identification

property publicKey

publicKey: pulumi.Input<string>;

The public key. If this is a file, it can be read using the file interpolation function

interface SshKeyState

interface SshKeyState

Input properties used for looking up and filtering SshKey resources.

property created

created?: pulumi.Input<string>;

The timestamp for when the SSH key was created

property fingerprint

fingerprint?: pulumi.Input<string>;

The fingerprint of the SSH key

property name

name?: pulumi.Input<string>;

The name of the SSH key for identification

property publicKey

publicKey?: pulumi.Input<string>;

The public key. If this is a file, it can be read using the file interpolation function

property updated

updated?: pulumi.Input<string>;

The timestamp for the last time the SSH key was updated

interface VlanArgs

interface VlanArgs

The set of arguments for constructing a Vlan resource.

property description

description?: pulumi.Input<string>;

Description string

property facility

facility: pulumi.Input<Facility>;

Facility where to create the VLAN

property projectId

projectId: pulumi.Input<string>;

ID of parent project

interface VlanState

interface VlanState

Input properties used for looking up and filtering Vlan resources.

property description

description?: pulumi.Input<string>;

Description string

property facility

facility?: pulumi.Input<Facility>;

Facility where to create the VLAN

property projectId

projectId?: pulumi.Input<string>;

ID of parent project

property vxlan

vxlan?: pulumi.Input<number>;

VXLAN segment ID

interface VolumeArgs

interface VolumeArgs

The set of arguments for constructing a Volume resource.

property billingCycle

billingCycle?: pulumi.Input<BillingCycle>;

The billing cycle, defaults to “hourly”

property description

description?: pulumi.Input<string>;

Optional description for the volume

property facility

facility: pulumi.Input<Facility>;

The facility to create the volume in

property locked

locked?: pulumi.Input<boolean>;

Lock or unlock the volume

property plan

plan: pulumi.Input<string>;

The service plan slug of the volume

property projectId

projectId: pulumi.Input<string>;

The packet project ID to deploy the volume in

property size

size: pulumi.Input<number>;

The size in GB to make the volume

property snapshotPolicies

snapshotPolicies?: pulumi.Input<pulumi.Input<inputs.VolumeSnapshotPolicy>[]>;

Optional list of snapshot policies

interface VolumeAttachmentArgs

interface VolumeAttachmentArgs

The set of arguments for constructing a VolumeAttachment resource.

property deviceId

deviceId: pulumi.Input<string>;

The ID of the device to which the volume should be attached

property volumeId

volumeId: pulumi.Input<string>;

The ID of the volume to attach

interface VolumeAttachmentState

interface VolumeAttachmentState

Input properties used for looking up and filtering VolumeAttachment resources.

property deviceId

deviceId?: pulumi.Input<string>;

The ID of the device to which the volume should be attached

property volumeId

volumeId?: pulumi.Input<string>;

The ID of the volume to attach

interface VolumeState

interface VolumeState

Input properties used for looking up and filtering Volume resources.

property attachments

attachments?: pulumi.Input<pulumi.Input<inputs.VolumeAttachment>[]>;

A list of attachments, each with it’s own href attribute

property billingCycle

billingCycle?: pulumi.Input<BillingCycle>;

The billing cycle, defaults to “hourly”

property created

created?: pulumi.Input<string>;

The timestamp for when the volume was created

property description

description?: pulumi.Input<string>;

Optional description for the volume

property facility

facility?: pulumi.Input<Facility>;

The facility to create the volume in

property locked

locked?: pulumi.Input<boolean>;

Lock or unlock the volume

property name

name?: pulumi.Input<string>;

The name of the volume

property plan

plan?: pulumi.Input<string>;

The service plan slug of the volume

property projectId

projectId?: pulumi.Input<string>;

The packet project ID to deploy the volume in

property size

size?: pulumi.Input<number>;

The size in GB to make the volume

property snapshotPolicies

snapshotPolicies?: pulumi.Input<pulumi.Input<inputs.VolumeSnapshotPolicy>[]>;

Optional list of snapshot policies

property state

state?: pulumi.Input<string>;

The state of the volume

property updated

updated?: pulumi.Input<string>;

The timestamp for the last time the volume was updated