1. Packages
  2. Packages
  3. Megaport Provider
  4. API Docs
  5. McrIpsecAddon
Viewing docs for megaport 1.7.0
published on Thursday, Apr 30, 2026 by megaport
Viewing docs for megaport 1.7.0
published on Thursday, Apr 30, 2026 by megaport

    Manages an IPSec tunnel add-on for a Megaport Cloud Router (MCR). This resource allows you to attach, update, and remove IPSec tunnel packs on an existing MCR.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as megaport from "@pulumi/megaport";
    
    const example = new megaport.McrIpsecAddon("example", {
        mcrId: exampleMegaportMcr.productUid,
        tunnelCount: 10,
    });
    
    import pulumi
    import pulumi_megaport as megaport
    
    example = megaport.McrIpsecAddon("example",
        mcr_id=example_megaport_mcr["productUid"],
        tunnel_count=10)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/megaport/megaport"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := megaport.NewMcrIpsecAddon(ctx, "example", &megaport.McrIpsecAddonArgs{
    			McrId:       pulumi.Any(exampleMegaportMcr.ProductUid),
    			TunnelCount: pulumi.Float64(10),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Megaport = Pulumi.Megaport;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Megaport.McrIpsecAddon("example", new()
        {
            McrId = exampleMegaportMcr.ProductUid,
            TunnelCount = 10,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.megaport.McrIpsecAddon;
    import com.pulumi.megaport.McrIpsecAddonArgs;
    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) {
            var example = new McrIpsecAddon("example", McrIpsecAddonArgs.builder()
                .mcrId(exampleMegaportMcr.productUid())
                .tunnelCount(10.0)
                .build());
    
        }
    }
    
    resources:
      example:
        type: megaport:McrIpsecAddon
        properties:
          mcrId: ${exampleMegaportMcr.productUid}
          tunnelCount: 10
    

    Create McrIpsecAddon Resource

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

    Constructor syntax

    new McrIpsecAddon(name: string, args: McrIpsecAddonArgs, opts?: CustomResourceOptions);
    @overload
    def McrIpsecAddon(resource_name: str,
                      args: McrIpsecAddonArgs,
                      opts: Optional[ResourceOptions] = None)
    
    @overload
    def McrIpsecAddon(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      mcr_id: Optional[str] = None,
                      tunnel_count: Optional[float] = None)
    func NewMcrIpsecAddon(ctx *Context, name string, args McrIpsecAddonArgs, opts ...ResourceOption) (*McrIpsecAddon, error)
    public McrIpsecAddon(string name, McrIpsecAddonArgs args, CustomResourceOptions? opts = null)
    public McrIpsecAddon(String name, McrIpsecAddonArgs args)
    public McrIpsecAddon(String name, McrIpsecAddonArgs args, CustomResourceOptions options)
    
    type: megaport:McrIpsecAddon
    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 McrIpsecAddonArgs
    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 McrIpsecAddonArgs
    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 McrIpsecAddonArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args McrIpsecAddonArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args McrIpsecAddonArgs
    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 mcrIpsecAddonResource = new Megaport.McrIpsecAddon("mcrIpsecAddonResource", new()
    {
        McrId = "string",
        TunnelCount = 0,
    });
    
    example, err := megaport.NewMcrIpsecAddon(ctx, "mcrIpsecAddonResource", &megaport.McrIpsecAddonArgs{
    	McrId:       pulumi.String("string"),
    	TunnelCount: pulumi.Float64(0),
    })
    
    var mcrIpsecAddonResource = new McrIpsecAddon("mcrIpsecAddonResource", McrIpsecAddonArgs.builder()
        .mcrId("string")
        .tunnelCount(0.0)
        .build());
    
    mcr_ipsec_addon_resource = megaport.McrIpsecAddon("mcrIpsecAddonResource",
        mcr_id="string",
        tunnel_count=float(0))
    
    const mcrIpsecAddonResource = new megaport.McrIpsecAddon("mcrIpsecAddonResource", {
        mcrId: "string",
        tunnelCount: 0,
    });
    
    type: megaport:McrIpsecAddon
    properties:
        mcrId: string
        tunnelCount: 0
    

    McrIpsecAddon 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 McrIpsecAddon resource accepts the following input properties:

    McrId string
    The UID of the MCR to attach the IPSec add-on to.
    TunnelCount double
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    McrId string
    The UID of the MCR to attach the IPSec add-on to.
    TunnelCount float64
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    mcrId String
    The UID of the MCR to attach the IPSec add-on to.
    tunnelCount Double
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    mcrId string
    The UID of the MCR to attach the IPSec add-on to.
    tunnelCount number
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    mcr_id str
    The UID of the MCR to attach the IPSec add-on to.
    tunnel_count float
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    mcrId String
    The UID of the MCR to attach the IPSec add-on to.
    tunnelCount Number
    The number of IPSec tunnels. Valid values are 10, 20, or 30.

    Outputs

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

    AddOnUid string
    The UID of the IPSec add-on, assigned by the API.
    Id string
    The provider-assigned unique ID for this managed resource.
    AddOnUid string
    The UID of the IPSec add-on, assigned by the API.
    Id string
    The provider-assigned unique ID for this managed resource.
    addOnUid String
    The UID of the IPSec add-on, assigned by the API.
    id String
    The provider-assigned unique ID for this managed resource.
    addOnUid string
    The UID of the IPSec add-on, assigned by the API.
    id string
    The provider-assigned unique ID for this managed resource.
    add_on_uid str
    The UID of the IPSec add-on, assigned by the API.
    id str
    The provider-assigned unique ID for this managed resource.
    addOnUid String
    The UID of the IPSec add-on, assigned by the API.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing McrIpsecAddon Resource

    Get an existing McrIpsecAddon 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?: McrIpsecAddonState, opts?: CustomResourceOptions): McrIpsecAddon
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            add_on_uid: Optional[str] = None,
            mcr_id: Optional[str] = None,
            tunnel_count: Optional[float] = None) -> McrIpsecAddon
    func GetMcrIpsecAddon(ctx *Context, name string, id IDInput, state *McrIpsecAddonState, opts ...ResourceOption) (*McrIpsecAddon, error)
    public static McrIpsecAddon Get(string name, Input<string> id, McrIpsecAddonState? state, CustomResourceOptions? opts = null)
    public static McrIpsecAddon get(String name, Output<String> id, McrIpsecAddonState state, CustomResourceOptions options)
    resources:  _:    type: megaport:McrIpsecAddon    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:
    AddOnUid string
    The UID of the IPSec add-on, assigned by the API.
    McrId string
    The UID of the MCR to attach the IPSec add-on to.
    TunnelCount double
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    AddOnUid string
    The UID of the IPSec add-on, assigned by the API.
    McrId string
    The UID of the MCR to attach the IPSec add-on to.
    TunnelCount float64
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    addOnUid String
    The UID of the IPSec add-on, assigned by the API.
    mcrId String
    The UID of the MCR to attach the IPSec add-on to.
    tunnelCount Double
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    addOnUid string
    The UID of the IPSec add-on, assigned by the API.
    mcrId string
    The UID of the MCR to attach the IPSec add-on to.
    tunnelCount number
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    add_on_uid str
    The UID of the IPSec add-on, assigned by the API.
    mcr_id str
    The UID of the MCR to attach the IPSec add-on to.
    tunnel_count float
    The number of IPSec tunnels. Valid values are 10, 20, or 30.
    addOnUid String
    The UID of the IPSec add-on, assigned by the API.
    mcrId String
    The UID of the MCR to attach the IPSec add-on to.
    tunnelCount Number
    The number of IPSec tunnels. Valid values are 10, 20, or 30.

    Package Details

    Repository
    megaport megaport/terraform-provider-megaport
    License
    Notes
    This Pulumi package is based on the megaport Terraform Provider.
    Viewing docs for megaport 1.7.0
    published on Thursday, Apr 30, 2026 by megaport
      Try Pulumi Cloud free. Your team will thank you.