1. Packages
  2. Hpegl Provider
  3. API Docs
  4. VmaasDhcpServer
hpegl 0.4.18 published on Friday, Apr 18, 2025 by hpe

hpegl.VmaasDhcpServer

Explore with Pulumi AI

hpegl logo
hpegl 0.4.18 published on Friday, Apr 18, 2025 by hpe

    Compatible version >= 5.2.13

    Server resource facilitates creating, updating and deleting Dhcp Server. hpegl.VmaasDhcpServer resource supports NSX-T DHCP Server creation. For more information, see Private cloud networking using VMware NSX-T.

    For creating an NSX-T DHCP Server, see the following examples.

    Example Usage

    Creating NSX-T DHCP Server With All Possible Attributes

    import * as pulumi from "@pulumi/pulumi";
    import * as hpegl from "@pulumi/hpegl";
    
    // (C) Copyright 2022 Hewlett Packard Enterprise Development LP
    const tfDhcpServer = new hpegl.VmaasDhcpServer("tfDhcpServer", {
        leaseTime: 86400,
        serverAddress: "100.96.0.1/24",
        configs: [{
            edgeCluster: data.hpegl_vmaas_edge_cluster.tf_edge_cluster.provider_id,
        }],
    });
    
    import pulumi
    import pulumi_hpegl as hpegl
    
    # (C) Copyright 2022 Hewlett Packard Enterprise Development LP
    tf_dhcp_server = hpegl.VmaasDhcpServer("tfDhcpServer",
        lease_time=86400,
        server_address="100.96.0.1/24",
        configs=[{
            "edge_cluster": data["hpegl_vmaas_edge_cluster"]["tf_edge_cluster"]["provider_id"],
        }])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/hpegl/hpegl"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// (C) Copyright 2022 Hewlett Packard Enterprise Development LP
    		_, err := hpegl.NewVmaasDhcpServer(ctx, "tfDhcpServer", &hpegl.VmaasDhcpServerArgs{
    			LeaseTime:     pulumi.Float64(86400),
    			ServerAddress: pulumi.String("100.96.0.1/24"),
    			Configs: hpegl.VmaasDhcpServerConfigArray{
    				&hpegl.VmaasDhcpServerConfigArgs{
    					EdgeCluster: pulumi.Any(data.Hpegl_vmaas_edge_cluster.Tf_edge_cluster.Provider_id),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Hpegl = Pulumi.Hpegl;
    
    return await Deployment.RunAsync(() => 
    {
        // (C) Copyright 2022 Hewlett Packard Enterprise Development LP
        var tfDhcpServer = new Hpegl.VmaasDhcpServer("tfDhcpServer", new()
        {
            LeaseTime = 86400,
            ServerAddress = "100.96.0.1/24",
            Configs = new[]
            {
                new Hpegl.Inputs.VmaasDhcpServerConfigArgs
                {
                    EdgeCluster = data.Hpegl_vmaas_edge_cluster.Tf_edge_cluster.Provider_id,
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.hpegl.VmaasDhcpServer;
    import com.pulumi.hpegl.VmaasDhcpServerArgs;
    import com.pulumi.hpegl.inputs.VmaasDhcpServerConfigArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            // (C) Copyright 2022 Hewlett Packard Enterprise Development LP
            var tfDhcpServer = new VmaasDhcpServer("tfDhcpServer", VmaasDhcpServerArgs.builder()
                .leaseTime(86400)
                .serverAddress("100.96.0.1/24")
                .configs(VmaasDhcpServerConfigArgs.builder()
                    .edgeCluster(data.hpegl_vmaas_edge_cluster().tf_edge_cluster().provider_id())
                    .build())
                .build());
    
        }
    }
    
    resources:
      # (C) Copyright 2022 Hewlett Packard Enterprise Development LP
      tfDhcpServer:
        type: hpegl:VmaasDhcpServer
        properties:
          leaseTime: 86400
          serverAddress: 100.96.0.1/24
          configs:
            - edgeCluster: ${data.hpegl_vmaas_edge_cluster.tf_edge_cluster.provider_id}
    

    Create VmaasDhcpServer Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new VmaasDhcpServer(name: string, args?: VmaasDhcpServerArgs, opts?: CustomResourceOptions);
    @overload
    def VmaasDhcpServer(resource_name: str,
                        args: Optional[VmaasDhcpServerArgs] = None,
                        opts: Optional[ResourceOptions] = None)
    
    @overload
    def VmaasDhcpServer(resource_name: str,
                        opts: Optional[ResourceOptions] = None,
                        configs: Optional[Sequence[VmaasDhcpServerConfigArgs]] = None,
                        lease_time: Optional[float] = None,
                        name: Optional[str] = None,
                        server_address: Optional[str] = None,
                        vmaas_dhcp_server_id: Optional[str] = None)
    func NewVmaasDhcpServer(ctx *Context, name string, args *VmaasDhcpServerArgs, opts ...ResourceOption) (*VmaasDhcpServer, error)
    public VmaasDhcpServer(string name, VmaasDhcpServerArgs? args = null, CustomResourceOptions? opts = null)
    public VmaasDhcpServer(String name, VmaasDhcpServerArgs args)
    public VmaasDhcpServer(String name, VmaasDhcpServerArgs args, CustomResourceOptions options)
    
    type: hpegl:VmaasDhcpServer
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args VmaasDhcpServerArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args VmaasDhcpServerArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args VmaasDhcpServerArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args VmaasDhcpServerArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args VmaasDhcpServerArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var vmaasDhcpServerResource = new Hpegl.VmaasDhcpServer("vmaasDhcpServerResource", new()
    {
        Configs = new[]
        {
            new Hpegl.Inputs.VmaasDhcpServerConfigArgs
            {
                EdgeCluster = "string",
            },
        },
        LeaseTime = 0,
        Name = "string",
        ServerAddress = "string",
        VmaasDhcpServerId = "string",
    });
    
    example, err := hpegl.NewVmaasDhcpServer(ctx, "vmaasDhcpServerResource", &hpegl.VmaasDhcpServerArgs{
    	Configs: hpegl.VmaasDhcpServerConfigArray{
    		&hpegl.VmaasDhcpServerConfigArgs{
    			EdgeCluster: pulumi.String("string"),
    		},
    	},
    	LeaseTime:         pulumi.Float64(0),
    	Name:              pulumi.String("string"),
    	ServerAddress:     pulumi.String("string"),
    	VmaasDhcpServerId: pulumi.String("string"),
    })
    
    var vmaasDhcpServerResource = new VmaasDhcpServer("vmaasDhcpServerResource", VmaasDhcpServerArgs.builder()
        .configs(VmaasDhcpServerConfigArgs.builder()
            .edgeCluster("string")
            .build())
        .leaseTime(0)
        .name("string")
        .serverAddress("string")
        .vmaasDhcpServerId("string")
        .build());
    
    vmaas_dhcp_server_resource = hpegl.VmaasDhcpServer("vmaasDhcpServerResource",
        configs=[{
            "edge_cluster": "string",
        }],
        lease_time=0,
        name="string",
        server_address="string",
        vmaas_dhcp_server_id="string")
    
    const vmaasDhcpServerResource = new hpegl.VmaasDhcpServer("vmaasDhcpServerResource", {
        configs: [{
            edgeCluster: "string",
        }],
        leaseTime: 0,
        name: "string",
        serverAddress: "string",
        vmaasDhcpServerId: "string",
    });
    
    type: hpegl:VmaasDhcpServer
    properties:
        configs:
            - edgeCluster: string
        leaseTime: 0
        name: string
        serverAddress: string
        vmaasDhcpServerId: string
    

    VmaasDhcpServer Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The VmaasDhcpServer resource accepts the following input properties:

    Configs List<VmaasDhcpServerConfig>
    DHCP Server Configuration
    LeaseTime double
    Lease time for the DHCP server
    Name string
    Provide the DHCP server name
    ServerAddress string
    Server address for the DHCP server
    VmaasDhcpServerId string
    The ID of this resource.
    Configs []VmaasDhcpServerConfigArgs
    DHCP Server Configuration
    LeaseTime float64
    Lease time for the DHCP server
    Name string
    Provide the DHCP server name
    ServerAddress string
    Server address for the DHCP server
    VmaasDhcpServerId string
    The ID of this resource.
    configs List<VmaasDhcpServerConfig>
    DHCP Server Configuration
    leaseTime Double
    Lease time for the DHCP server
    name String
    Provide the DHCP server name
    serverAddress String
    Server address for the DHCP server
    vmaasDhcpServerId String
    The ID of this resource.
    configs VmaasDhcpServerConfig[]
    DHCP Server Configuration
    leaseTime number
    Lease time for the DHCP server
    name string
    Provide the DHCP server name
    serverAddress string
    Server address for the DHCP server
    vmaasDhcpServerId string
    The ID of this resource.
    configs Sequence[VmaasDhcpServerConfigArgs]
    DHCP Server Configuration
    lease_time float
    Lease time for the DHCP server
    name str
    Provide the DHCP server name
    server_address str
    Server address for the DHCP server
    vmaas_dhcp_server_id str
    The ID of this resource.
    configs List<Property Map>
    DHCP Server Configuration
    leaseTime Number
    Lease time for the DHCP server
    name String
    Provide the DHCP server name
    serverAddress String
    Server address for the DHCP server
    vmaasDhcpServerId String
    The ID of this resource.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the VmaasDhcpServer resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    NetworkServerId double
    NSX-T Integration ID
    ProviderId string
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    Id string
    The provider-assigned unique ID for this managed resource.
    NetworkServerId float64
    NSX-T Integration ID
    ProviderId string
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    id String
    The provider-assigned unique ID for this managed resource.
    networkServerId Double
    NSX-T Integration ID
    providerId String
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    id string
    The provider-assigned unique ID for this managed resource.
    networkServerId number
    NSX-T Integration ID
    providerId string
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    id str
    The provider-assigned unique ID for this managed resource.
    network_server_id float
    NSX-T Integration ID
    provider_id str
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    id String
    The provider-assigned unique ID for this managed resource.
    networkServerId Number
    NSX-T Integration ID
    providerId String
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network

    Look up Existing VmaasDhcpServer Resource

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

    public static get(name: string, id: Input<ID>, state?: VmaasDhcpServerState, opts?: CustomResourceOptions): VmaasDhcpServer
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            configs: Optional[Sequence[VmaasDhcpServerConfigArgs]] = None,
            lease_time: Optional[float] = None,
            name: Optional[str] = None,
            network_server_id: Optional[float] = None,
            provider_id: Optional[str] = None,
            server_address: Optional[str] = None,
            vmaas_dhcp_server_id: Optional[str] = None) -> VmaasDhcpServer
    func GetVmaasDhcpServer(ctx *Context, name string, id IDInput, state *VmaasDhcpServerState, opts ...ResourceOption) (*VmaasDhcpServer, error)
    public static VmaasDhcpServer Get(string name, Input<string> id, VmaasDhcpServerState? state, CustomResourceOptions? opts = null)
    public static VmaasDhcpServer get(String name, Output<String> id, VmaasDhcpServerState state, CustomResourceOptions options)
    resources:  _:    type: hpegl:VmaasDhcpServer    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Configs List<VmaasDhcpServerConfig>
    DHCP Server Configuration
    LeaseTime double
    Lease time for the DHCP server
    Name string
    Provide the DHCP server name
    NetworkServerId double
    NSX-T Integration ID
    ProviderId string
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    ServerAddress string
    Server address for the DHCP server
    VmaasDhcpServerId string
    The ID of this resource.
    Configs []VmaasDhcpServerConfigArgs
    DHCP Server Configuration
    LeaseTime float64
    Lease time for the DHCP server
    Name string
    Provide the DHCP server name
    NetworkServerId float64
    NSX-T Integration ID
    ProviderId string
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    ServerAddress string
    Server address for the DHCP server
    VmaasDhcpServerId string
    The ID of this resource.
    configs List<VmaasDhcpServerConfig>
    DHCP Server Configuration
    leaseTime Double
    Lease time for the DHCP server
    name String
    Provide the DHCP server name
    networkServerId Double
    NSX-T Integration ID
    providerId String
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    serverAddress String
    Server address for the DHCP server
    vmaasDhcpServerId String
    The ID of this resource.
    configs VmaasDhcpServerConfig[]
    DHCP Server Configuration
    leaseTime number
    Lease time for the DHCP server
    name string
    Provide the DHCP server name
    networkServerId number
    NSX-T Integration ID
    providerId string
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    serverAddress string
    Server address for the DHCP server
    vmaasDhcpServerId string
    The ID of this resource.
    configs Sequence[VmaasDhcpServerConfigArgs]
    DHCP Server Configuration
    lease_time float
    Lease time for the DHCP server
    name str
    Provide the DHCP server name
    network_server_id float
    NSX-T Integration ID
    provider_id str
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    server_address str
    Server address for the DHCP server
    vmaas_dhcp_server_id str
    The ID of this resource.
    configs List<Property Map>
    DHCP Server Configuration
    leaseTime Number
    Lease time for the DHCP server
    name String
    Provide the DHCP server name
    networkServerId Number
    NSX-T Integration ID
    providerId String
    ProviderId of the DHCP Server. Use the provider_id while creating DHCP NSX-T Segment Network
    serverAddress String
    Server address for the DHCP server
    vmaasDhcpServerId String
    The ID of this resource.

    Supporting Types

    VmaasDhcpServerConfig, VmaasDhcpServerConfigArgs

    EdgeCluster string
    Provider ID of the Edge Cluster. Use hpeglvmaasedgecluster datasource to obtain the providerid here.
    EdgeCluster string
    Provider ID of the Edge Cluster. Use hpeglvmaasedgecluster datasource to obtain the providerid here.
    edgeCluster String
    Provider ID of the Edge Cluster. Use hpeglvmaasedgecluster datasource to obtain the providerid here.
    edgeCluster string
    Provider ID of the Edge Cluster. Use hpeglvmaasedgecluster datasource to obtain the providerid here.
    edge_cluster str
    Provider ID of the Edge Cluster. Use hpeglvmaasedgecluster datasource to obtain the providerid here.
    edgeCluster String
    Provider ID of the Edge Cluster. Use hpeglvmaasedgecluster datasource to obtain the providerid here.

    Package Details

    Repository
    hpegl hpe/terraform-provider-hpegl
    License
    Notes
    This Pulumi package is based on the hpegl Terraform Provider.
    hpegl logo
    hpegl 0.4.18 published on Friday, Apr 18, 2025 by hpe