import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Manages SDN Subnets in Proxmox VE. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as proxmoxve from "@muhlba91/pulumi-proxmoxve"; * * const finalizer = new proxmoxve.sdn.Applier("finalizer", {}); * // SDN Zone (Simple) - Basic zone for simple vnets * const exampleZone1 = new proxmoxve.sdn.zone.Simple("example_zone_1", { * resourceId: "zone1", * nodes: ["pve"], * mtu: 1500, * dns: "1.1.1.1", * dnsZone: "example.com", * ipam: "pve", * reverseDns: "1.1.1.1", * }, { * dependsOn: [finalizer], * }); * // SDN Zone (Simple) - Second zone for demonstration * const exampleZone2 = new proxmoxve.sdn.zone.Simple("example_zone_2", { * resourceId: "zone2", * nodes: ["pve"], * mtu: 1500, * }, { * dependsOn: [finalizer], * }); * // SDN VNet - Basic vnet * const exampleVnet1 = new proxmoxve.sdn.Vnet("example_vnet_1", { * resourceId: "vnet1", * zone: exampleZone1.resourceId, * }, { * dependsOn: [finalizer], * }); * // SDN VNet - VNet with alias and port isolation * const exampleVnet2 = new proxmoxve.sdn.Vnet("example_vnet_2", { * resourceId: "vnet2", * zone: exampleZone2.resourceId, * alias: "Example VNet 2", * isolatePorts: true, * vlanAware: false, * }, { * dependsOn: [finalizer], * }); * // Basic Subnet * const basicSubnet = new proxmoxve.sdn.Subnet("basic_subnet", { * cidr: "192.168.1.0/24", * vnet: exampleVnet1.resourceId, * gateway: "192.168.1.1", * }, { * dependsOn: [finalizer], * }); * // Subnet with DHCP Configuration * const dhcpSubnet = new proxmoxve.sdn.Subnet("dhcp_subnet", { * cidr: "192.168.2.0/24", * vnet: exampleVnet2.resourceId, * gateway: "192.168.2.1", * dhcpDnsServer: "192.168.2.53", * dnsZonePrefix: "internal.example.com", * snat: true, * dhcpRange: { * startAddress: "192.168.2.10", * endAddress: "192.168.2.100", * }, * }, { * dependsOn: [finalizer], * }); * // SDN Applier for all resources * const subnetApplier = new proxmoxve.sdn.Applier("subnet_applier", {}, { * dependsOn: [ * exampleZone1, * exampleZone2, * exampleVnet1, * exampleVnet2, * basicSubnet, * dhcpSubnet, * ], * }); * ``` * * ## Import * * !/usr/bin/env sh * SDN subnet can be imported using its unique identifier in the format: / * The is the canonical ID from Proxmox, e.g., "zone1-192.168.1.0-24" * * ```sh * $ pulumi import proxmoxve:sdn/subnet:Subnet basic_subnet vnet1/zone1-192.168.1.0-24 * $ pulumi import proxmoxve:sdn/subnet:Subnet dhcp_subnet vnet2/zone2-192.168.2.0-24 * ``` */ export declare class Subnet extends pulumi.CustomResource { /** * Get an existing Subnet 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, state?: SubnetState, opts?: pulumi.CustomResourceOptions): Subnet; /** * Returns true if the given object is an instance of Subnet. 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 Subnet; /** * A CIDR network address, for example 10.0.0.0/8 */ readonly cidr: pulumi.Output; /** * The DNS server used for DHCP. */ readonly dhcpDnsServer: pulumi.Output; /** * DHCP range (start and end IPs). */ readonly dhcpRange: pulumi.Output; /** * Prefix used for DNS zone delegation. */ readonly dnsZonePrefix: pulumi.Output; /** * The gateway address for the subnet. */ readonly gateway: pulumi.Output; /** * Whether SNAT is enabled for the subnet. */ readonly snat: pulumi.Output; /** * The VNet to which this subnet belongs. */ readonly vnet: pulumi.Output; /** * Create a Subnet 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: SubnetArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Subnet resources. */ export interface SubnetState { /** * A CIDR network address, for example 10.0.0.0/8 */ cidr?: pulumi.Input; /** * The DNS server used for DHCP. */ dhcpDnsServer?: pulumi.Input; /** * DHCP range (start and end IPs). */ dhcpRange?: pulumi.Input; /** * Prefix used for DNS zone delegation. */ dnsZonePrefix?: pulumi.Input; /** * The gateway address for the subnet. */ gateway?: pulumi.Input; /** * Whether SNAT is enabled for the subnet. */ snat?: pulumi.Input; /** * The VNet to which this subnet belongs. */ vnet?: pulumi.Input; } /** * The set of arguments for constructing a Subnet resource. */ export interface SubnetArgs { /** * A CIDR network address, for example 10.0.0.0/8 */ cidr: pulumi.Input; /** * The DNS server used for DHCP. */ dhcpDnsServer?: pulumi.Input; /** * DHCP range (start and end IPs). */ dhcpRange?: pulumi.Input; /** * Prefix used for DNS zone delegation. */ dnsZonePrefix?: pulumi.Input; /** * The gateway address for the subnet. */ gateway?: pulumi.Input; /** * Whether SNAT is enabled for the subnet. */ snat?: pulumi.Input; /** * The VNet to which this subnet belongs. */ vnet: pulumi.Input; } //# sourceMappingURL=subnet.d.ts.map