UNPKG

@natzka-oss/pulumi-netbox

Version:

A Pulumi package for creating and managing Netbox cloud resources.

131 lines (130 loc) 5.84 kB
import * as pulumi from "@pulumi/pulumi"; /** * From the [official documentation](https://docs.netbox.dev/en/stable/models/dcim/frontport/): * * > Front ports are pass-through ports which represent physical cable connections that comprise part of a longer path. For example, the ports on the front face of a UTP patch panel would be modeled in NetBox as front ports. Each port is assigned a physical type, and must be mapped to a specific rear port on the same device. A single rear port may be mapped to multiple front ports, using numeric positions to annotate the specific alignment of each. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as netbox from "@natzka-oss/pulumi-netbox"; * * // Note that some terraform code is not included in the example for brevity * const test = new netbox.dcim.Device("test", { * name: "%[1]s", * deviceTypeId: testNetboxDeviceType.id, * roleId: testNetboxDeviceRole.id, * siteId: testNetboxSite.id, * }); * const testDeviceRearPort = new netbox.dcim.DeviceRearPort("test", { * deviceId: test.id, * name: "rear port 1", * type: "8p8c", * positions: 2, * markConnected: true, * }); * const testDeviceFrontPort = new netbox.dcim.DeviceFrontPort("test", { * deviceId: test.id, * name: "front port 1", * type: "8p8c", * rearPortId: testDeviceRearPort.id, * rearPortPosition: 2, * }); * ``` */ export declare class DeviceFrontPort extends pulumi.CustomResource { /** * Get an existing DeviceFrontPort resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input<pulumi.ID>, state?: DeviceFrontPortState, opts?: pulumi.CustomResourceOptions): DeviceFrontPort; /** * Returns true if the given object is an instance of DeviceFrontPort. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is DeviceFrontPort; readonly colorHex: pulumi.Output<string | undefined>; readonly customFields: pulumi.Output<{ [key: string]: string; } | undefined>; readonly description: pulumi.Output<string | undefined>; readonly deviceId: pulumi.Output<number>; readonly label: pulumi.Output<string | undefined>; /** * Defaults to `false`. */ readonly markConnected: pulumi.Output<boolean | undefined>; readonly moduleId: pulumi.Output<number | undefined>; readonly name: pulumi.Output<string>; readonly rearPortId: pulumi.Output<number>; readonly rearPortPosition: pulumi.Output<number>; readonly tags: pulumi.Output<string[] | undefined>; /** * One of [8p8c, 8p6c, 8p4c, 8p2c, 6p6c, 6p4c, 6p2c, 4p4c, 4p2c, gg45, tera-4p, tera-2p, tera-1p, 110-punch, bnc, f, n, mrj21, fc, lc, lc-pc, lc-upc, lc-apc, lsh, lsh-pc, lsh-upc, lsh-apc, mpo, mtrj, sc, sc-pc, sc-upc, sc-apc, st, cs, sn, sma-905, sma-906, urm-p2, urm-p4, urm-p8, splice, other]. */ readonly type: pulumi.Output<string>; /** * Create a DeviceFrontPort resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: DeviceFrontPortArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering DeviceFrontPort resources. */ export interface DeviceFrontPortState { colorHex?: pulumi.Input<string>; customFields?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; description?: pulumi.Input<string>; deviceId?: pulumi.Input<number>; label?: pulumi.Input<string>; /** * Defaults to `false`. */ markConnected?: pulumi.Input<boolean>; moduleId?: pulumi.Input<number>; name?: pulumi.Input<string>; rearPortId?: pulumi.Input<number>; rearPortPosition?: pulumi.Input<number>; tags?: pulumi.Input<pulumi.Input<string>[]>; /** * One of [8p8c, 8p6c, 8p4c, 8p2c, 6p6c, 6p4c, 6p2c, 4p4c, 4p2c, gg45, tera-4p, tera-2p, tera-1p, 110-punch, bnc, f, n, mrj21, fc, lc, lc-pc, lc-upc, lc-apc, lsh, lsh-pc, lsh-upc, lsh-apc, mpo, mtrj, sc, sc-pc, sc-upc, sc-apc, st, cs, sn, sma-905, sma-906, urm-p2, urm-p4, urm-p8, splice, other]. */ type?: pulumi.Input<string>; } /** * The set of arguments for constructing a DeviceFrontPort resource. */ export interface DeviceFrontPortArgs { colorHex?: pulumi.Input<string>; customFields?: pulumi.Input<{ [key: string]: pulumi.Input<string>; }>; description?: pulumi.Input<string>; deviceId: pulumi.Input<number>; label?: pulumi.Input<string>; /** * Defaults to `false`. */ markConnected?: pulumi.Input<boolean>; moduleId?: pulumi.Input<number>; name?: pulumi.Input<string>; rearPortId: pulumi.Input<number>; rearPortPosition: pulumi.Input<number>; tags?: pulumi.Input<pulumi.Input<string>[]>; /** * One of [8p8c, 8p6c, 8p4c, 8p2c, 6p6c, 6p4c, 6p2c, 4p4c, 4p2c, gg45, tera-4p, tera-2p, tera-1p, 110-punch, bnc, f, n, mrj21, fc, lc, lc-pc, lc-upc, lc-apc, lsh, lsh-pc, lsh-upc, lsh-apc, mpo, mtrj, sc, sc-pc, sc-upc, sc-apc, st, cs, sn, sma-905, sma-906, urm-p2, urm-p4, urm-p8, splice, other]. */ type: pulumi.Input<string>; }