<gh_stars>0// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.Aviatrix
{
    /// <summary>
    /// The **aviatrix_azure_peer** resource allows the creation and management of the Aviatrix-created peerings between Azure VNets.
    /// 
    /// ## Example Usage
    /// 
    /// ```csharp
    /// using System.Collections.Generic;
    /// using Pulumi;
    /// using Aviatrix = Pulumi.Aviatrix;
    /// 
    /// return await Deployment.RunAsync(() =&gt; 
    /// {
    ///     // Create an Aviatrix Azure Peering
    ///     var testAzurepeer = new Aviatrix.AviatrixAzurePeer("testAzurepeer", new()
    ///     {
    ///         AccountName1 = "test1-account",
    ///         AccountName2 = "test2-account",
    ///         VnetNameResourceGroup1 = "Foo_VNet1:Bar_RG1:GUID1",
    ///         VnetNameResourceGroup2 = "Foo_VNet2:Bar_RG2:GUID2",
    ///         VnetReg1 = "Central US",
    ///         VnetReg2 = "East US",
    ///     });
    /// 
    /// });
    /// ```
    /// 
    /// ## Import
    /// 
    /// **azure_peer** can be imported using the `vnet_name_resource_group1` and `vnet_name_resource_group2`, e.g.
    /// 
    /// ```sh
    ///  $ pulumi import aviatrix:index/aviatrixAzurePeer:AviatrixAzurePeer test vnet_name_resource_group1~vnet_name_resource_group2
    /// ```
    /// </summary>
    [AviatrixResourceType("aviatrix:index/aviatrixAzurePeer:AviatrixAzurePeer")]
    public partial class AviatrixAzurePeer : global::Pulumi.CustomResource
    {
        /// <summary>
        /// Name of the Azure cloud account in the Aviatrix controller for VNet 1.
        /// </summary>
        [Output("accountName1")]
        public Output<string> AccountName1 { get; private set; } = null!;

        /// <summary>
        /// Name of the Azure cloud account in the Aviatrix controller for VNet 2.
        /// </summary>
        [Output("accountName2")]
        public Output<string> AccountName2 { get; private set; } = null!;

        /// <summary>
        /// List of VNet CIDR of vnet_name_resource_group1.
        /// </summary>
        [Output("vnetCidr1s")]
        public Output<ImmutableArray<string>> VnetCidr1s { get; private set; } = null!;

        /// <summary>
        /// List of VNet CIDR of vnet_name_resource_group2.
        /// </summary>
        [Output("vnetCidr2s")]
        public Output<ImmutableArray<string>> VnetCidr2s { get; private set; } = null!;

        /// <summary>
        /// Azure VNet 1's name. Example: "VNet_Name1:Resource_Group_Name1:GUID1".
        /// </summary>
        [Output("vnetNameResourceGroup1")]
        public Output<string> VnetNameResourceGroup1 { get; private set; } = null!;

        /// <summary>
        /// Azure VNet 2's name. Example: "VNet_Name2:Resource_Group_Name2:GUID2".
        /// </summary>
        [Output("vnetNameResourceGroup2")]
        public Output<string> VnetNameResourceGroup2 { get; private set; } = null!;

        /// <summary>
        /// Region of Azure VNet 1. Example: "East US 2".
        /// </summary>
        [Output("vnetReg1")]
        public Output<string> VnetReg1 { get; private set; } = null!;

        /// <summary>
        /// Region of Azure VNet 2. Example: "East US 2".
        /// </summary>
        [Output("vnetReg2")]
        public Output<string> VnetReg2 { get; private set; } = null!;


        /// <summary>
        /// Create a AviatrixAzurePeer resource with the given unique name, arguments, and options.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resource</param>
        /// <param name="args">The arguments used to populate this resource's properties</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public AviatrixAzurePeer(string name, AviatrixAzurePeerArgs args, CustomResourceOptions? options = null)
            : base("aviatrix:index/aviatrixAzurePeer:AviatrixAzurePeer", name, args ?? new AviatrixAzurePeerArgs(), MakeResourceOptions(options, ""))
        {
        }

        private AviatrixAzurePeer(string name, Input<string> id, AviatrixAzurePeerState? state = null, CustomResourceOptions? options = null)
            : base("aviatrix:index/aviatrixAzurePeer:AviatrixAzurePeer", name, state, MakeResourceOptions(options, id))
        {
        }

        private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
        {
            var defaultOptions = new CustomResourceOptions
            {
                Version = Utilities.Version,
                PluginDownloadURL = "github://api.github.com/astipkovits",
            };
            var merged = CustomResourceOptions.Merge(defaultOptions, options);
            // Override the ID if one was specified for consistency with other language SDKs.
            merged.Id = id ?? merged.Id;
            return merged;
        }
        /// <summary>
        /// Get an existing AviatrixAzurePeer resource's state with the given name, ID, and optional extra
        /// properties used to qualify the lookup.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resulting resource.</param>
        /// <param name="id">The unique provider ID of the resource to lookup.</param>
        /// <param name="state">Any extra arguments used during the lookup.</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public static AviatrixAzurePeer Get(string name, Input<string> id, AviatrixAzurePeerState? state = null, CustomResourceOptions? options = null)
        {
            return new AviatrixAzurePeer(name, id, state, options);
        }
    }

    public sealed class AviatrixAzurePeerArgs : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// Name of the Azure cloud account in the Aviatrix controller for VNet 1.
        /// </summary>
        [Input("accountName1", required: true)]
        public Input<string> AccountName1 { get; set; } = null!;

        /// <summary>
        /// Name of the Azure cloud account in the Aviatrix controller for VNet 2.
        /// </summary>
        [Input("accountName2", required: true)]
        public Input<string> AccountName2 { get; set; } = null!;

        /// <summary>
        /// Azure VNet 1's name. Example: "VNet_Name1:Resource_Group_Name1:GUID1".
        /// </summary>
        [Input("vnetNameResourceGroup1", required: true)]
        public Input<string> VnetNameResourceGroup1 { get; set; } = null!;

        /// <summary>
        /// Azure VNet 2's name. Example: "VNet_Name2:Resource_Group_Name2:GUID2".
        /// </summary>
        [Input("vnetNameResourceGroup2", required: true)]
        public Input<string> VnetNameResourceGroup2 { get; set; } = null!;

        /// <summary>
        /// Region of Azure VNet 1. Example: "East US 2".
        /// </summary>
        [Input("vnetReg1", required: true)]
        public Input<string> VnetReg1 { get; set; } = null!;

        /// <summary>
        /// Region of Azure VNet 2. Example: "East US 2".
        /// </summary>
        [Input("vnetReg2", required: true)]
        public Input<string> VnetReg2 { get; set; } = null!;

        public AviatrixAzurePeerArgs()
        {
        }
        public static new AviatrixAzurePeerArgs Empty => new AviatrixAzurePeerArgs();
    }

    public sealed class AviatrixAzurePeerState : global::Pulumi.ResourceArgs
    {
        /// <summary>
        /// Name of the Azure cloud account in the Aviatrix controller for VNet 1.
        /// </summary>
        [Input("accountName1")]
        public Input<string>? AccountName1 { get; set; }

        /// <summary>
        /// Name of the Azure cloud account in the Aviatrix controller for VNet 2.
        /// </summary>
        [Input("accountName2")]
        public Input<string>? AccountName2 { get; set; }

        [Input("vnetCidr1s")]
        private InputList<string>? _vnetCidr1s;

        /// <summary>
        /// List of VNet CIDR of vnet_name_resource_group1.
        /// </summary>
        public InputList<string> VnetCidr1s
        {
            get => _vnetCidr1s ?? (_vnetCidr1s = new InputList<string>());
            set => _vnetCidr1s = value;
        }

        [Input("vnetCidr2s")]
        private InputList<string>? _vnetCidr2s;

        /// <summary>
        /// List of VNet CIDR of vnet_name_resource_group2.
        /// </summary>
        public InputList<string> VnetCidr2s
        {
            get => _vnetCidr2s ?? (_vnetCidr2s = new InputList<string>());
            set => _vnetCidr2s = value;
        }

        /// <summary>
        /// Azure VNet 1's name. Example: "VNet_Name1:Resource_Group_Name1:GUID1".
        /// </summary>
        [Input("vnetNameResourceGroup1")]
        public Input<string>? VnetNameResourceGroup1 { get; set; }

        /// <summary>
        /// Azure VNet 2's name. Example: "VNet_Name2:Resource_Group_Name2:GUID2".
        /// </summary>
        [Input("vnetNameResourceGroup2")]
        public Input<string>? VnetNameResourceGroup2 { get; set; }

        /// <summary>
        /// Region of Azure VNet 1. Example: "East US 2".
        /// </summary>
        [Input("vnetReg1")]
        public Input<string>? VnetReg1 { get; set; }

        /// <summary>
        /// Region of Azure VNet 2. Example: "East US 2".
        /// </summary>
        [Input("vnetReg2")]
        public Input<string>? VnetReg2 { get; set; }

        public AviatrixAzurePeerState()
        {
        }
        public static new AviatrixAzurePeerState Empty => new AviatrixAzurePeerState();
    }
}
