@natzka-oss/pulumi-netbox
Version:
A Pulumi package for creating and managing Netbox cloud resources.
170 lines (169 loc) • 5.69 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
/**
* From the [official documentation](https://docs.netbox.dev/en/stable/models/dcim/powerfeed/):
*
* > A power feed represents the distribution of power from a power panel to a particular device, typically a power distribution unit (PDU). The power port (inlet) on a device can be connected via a cable to a power feed. A power feed may optionally be assigned to a rack to allow more easily tracking the distribution of power among racks.
*
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as netbox from "@natzka-oss/pulumi-netbox";
*
* const test = new netbox.dcim.Site("test", {
* name: "Site 1",
* status: "active",
* });
* const testLocation = new netbox.dcim.Location("test", {
* name: "Location 1",
* siteId: test.id,
* });
* const testPowerPanel = new netbox.dcim.PowerPanel("test", {
* name: "Power Panel 1",
* siteId: test.id,
* locationId: testLocation.id,
* });
* const testPowerFeed = new netbox.dcim.PowerFeed("test", {
* powerPanelId: testPowerPanel.id,
* name: "Power Feed 1",
* status: "active",
* type: "primary",
* supply: "ac",
* phase: "single-phase",
* voltage: 250,
* amperage: 100,
* maxPercentUtilization: 80,
* });
* ```
*/
export declare class PowerFeed extends pulumi.CustomResource {
/**
* Get an existing PowerFeed 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?: PowerFeedState, opts?: pulumi.CustomResourceOptions): PowerFeed;
/**
* Returns true if the given object is an instance of PowerFeed. 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 PowerFeed;
readonly amperage: pulumi.Output<number>;
readonly comments: pulumi.Output<string | undefined>;
readonly customFields: pulumi.Output<{
[key: string]: string;
} | undefined>;
readonly description: pulumi.Output<string | undefined>;
/**
* Defaults to `false`.
*/
readonly markConnected: pulumi.Output<boolean | undefined>;
readonly maxPercentUtilization: pulumi.Output<number>;
readonly name: pulumi.Output<string>;
/**
* One of [single-phase, three-phase].
*/
readonly phase: pulumi.Output<string>;
readonly powerPanelId: pulumi.Output<number>;
readonly rackId: pulumi.Output<number | undefined>;
/**
* One of [offline, active, planned, failed].
*/
readonly status: pulumi.Output<string>;
/**
* One of [ac, dc].
*/
readonly supply: pulumi.Output<string>;
readonly tags: pulumi.Output<string[] | undefined>;
/**
* One of [primary, redundant].
*/
readonly type: pulumi.Output<string>;
readonly voltage: pulumi.Output<number>;
/**
* Create a PowerFeed 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: PowerFeedArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering PowerFeed resources.
*/
export interface PowerFeedState {
amperage?: pulumi.Input<number>;
comments?: pulumi.Input<string>;
customFields?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
description?: pulumi.Input<string>;
/**
* Defaults to `false`.
*/
markConnected?: pulumi.Input<boolean>;
maxPercentUtilization?: pulumi.Input<number>;
name?: pulumi.Input<string>;
/**
* One of [single-phase, three-phase].
*/
phase?: pulumi.Input<string>;
powerPanelId?: pulumi.Input<number>;
rackId?: pulumi.Input<number>;
/**
* One of [offline, active, planned, failed].
*/
status?: pulumi.Input<string>;
/**
* One of [ac, dc].
*/
supply?: pulumi.Input<string>;
tags?: pulumi.Input<pulumi.Input<string>[]>;
/**
* One of [primary, redundant].
*/
type?: pulumi.Input<string>;
voltage?: pulumi.Input<number>;
}
/**
* The set of arguments for constructing a PowerFeed resource.
*/
export interface PowerFeedArgs {
amperage: pulumi.Input<number>;
comments?: pulumi.Input<string>;
customFields?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
description?: pulumi.Input<string>;
/**
* Defaults to `false`.
*/
markConnected?: pulumi.Input<boolean>;
maxPercentUtilization: pulumi.Input<number>;
name?: pulumi.Input<string>;
/**
* One of [single-phase, three-phase].
*/
phase: pulumi.Input<string>;
powerPanelId: pulumi.Input<number>;
rackId?: pulumi.Input<number>;
/**
* One of [offline, active, planned, failed].
*/
status: pulumi.Input<string>;
/**
* One of [ac, dc].
*/
supply: pulumi.Input<string>;
tags?: pulumi.Input<pulumi.Input<string>[]>;
/**
* One of [primary, redundant].
*/
type: pulumi.Input<string>;
voltage: pulumi.Input<number>;
}