github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/networkmanager/coreNetwork.go (about)

     1  // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
     2  // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
     3  
     4  package networkmanager
     5  
     6  import (
     7  	"context"
     8  	"reflect"
     9  
    10  	"errors"
    11  	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal"
    12  	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    13  )
    14  
    15  // Provides a core network resource.
    16  //
    17  // ## Example Usage
    18  //
    19  // ### Basic
    20  //
    21  // <!--Start PulumiCodeChooser -->
    22  // ```go
    23  // package main
    24  //
    25  // import (
    26  //
    27  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
    28  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    29  //
    30  // )
    31  //
    32  //	func main() {
    33  //		pulumi.Run(func(ctx *pulumi.Context) error {
    34  //			_, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
    35  //				GlobalNetworkId: pulumi.Any(exampleAwsNetworkmanagerGlobalNetwork.Id),
    36  //			})
    37  //			if err != nil {
    38  //				return err
    39  //			}
    40  //			return nil
    41  //		})
    42  //	}
    43  //
    44  // ```
    45  // <!--End PulumiCodeChooser -->
    46  //
    47  // ### With description
    48  //
    49  // <!--Start PulumiCodeChooser -->
    50  // ```go
    51  // package main
    52  //
    53  // import (
    54  //
    55  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
    56  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    57  //
    58  // )
    59  //
    60  //	func main() {
    61  //		pulumi.Run(func(ctx *pulumi.Context) error {
    62  //			_, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
    63  //				GlobalNetworkId: pulumi.Any(exampleAwsNetworkmanagerGlobalNetwork.Id),
    64  //				Description:     pulumi.String("example"),
    65  //			})
    66  //			if err != nil {
    67  //				return err
    68  //			}
    69  //			return nil
    70  //		})
    71  //	}
    72  //
    73  // ```
    74  // <!--End PulumiCodeChooser -->
    75  //
    76  // ### With tags
    77  //
    78  // <!--Start PulumiCodeChooser -->
    79  // ```go
    80  // package main
    81  //
    82  // import (
    83  //
    84  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
    85  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    86  //
    87  // )
    88  //
    89  //	func main() {
    90  //		pulumi.Run(func(ctx *pulumi.Context) error {
    91  //			_, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
    92  //				GlobalNetworkId: pulumi.Any(exampleAwsNetworkmanagerGlobalNetwork.Id),
    93  //				Tags: pulumi.StringMap{
    94  //					"hello": pulumi.String("world"),
    95  //				},
    96  //			})
    97  //			if err != nil {
    98  //				return err
    99  //			}
   100  //			return nil
   101  //		})
   102  //	}
   103  //
   104  // ```
   105  // <!--End PulumiCodeChooser -->
   106  //
   107  // ### With VPC Attachment (Single Region)
   108  //
   109  // The example below illustrates the scenario where your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Set the `createBasePolicy` argument to `true` if your core network does not currently have any `LIVE` policies (e.g. this is the first `pulumi up` with the core network resource), since a `LIVE` policy is required before VPCs can be attached to the core network. Otherwise, if your core network already has a `LIVE` policy, you may exclude the `createBasePolicy` argument. There are 2 options to implement this:
   110  //
   111  // - Option 1: Use the `basePolicyDocument` argument that allows the most customizations to a base policy. Use this to customize the `edgeLocations` `asn`. In the example below, `us-west-2` and ASN `65500` are used in the base policy.
   112  // - Option 2: Use the `createBasePolicy` argument only. This creates a base policy in the region specified in the `provider` block.
   113  //
   114  // ### Option 1 - using basePolicyDocument
   115  //
   116  // If you require a custom ASN for the edge location, please use the `basePolicyDocument` argument to pass a specific ASN. For example:
   117  //
   118  // <!--Start PulumiCodeChooser -->
   119  // ```go
   120  // package main
   121  //
   122  // import (
   123  //
   124  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
   125  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
   126  //
   127  // )
   128  // func main() {
   129  // pulumi.Run(func(ctx *pulumi.Context) error {
   130  // exampleGlobalNetwork, err := networkmanager.NewGlobalNetwork(ctx, "example", nil)
   131  // if err != nil {
   132  // return err
   133  // }
   134  // base, err := networkmanager.GetCoreNetworkPolicyDocument(ctx, &networkmanager.GetCoreNetworkPolicyDocumentArgs{
   135  // CoreNetworkConfigurations: []networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfiguration{
   136  // {
   137  // AsnRanges: []string{
   138  // "65022-65534",
   139  // },
   140  // EdgeLocations: []networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocation{
   141  // {
   142  // Location: "us-west-2",
   143  // Asn: pulumi.StringRef("65500"),
   144  // },
   145  // },
   146  // },
   147  // },
   148  // Segments: []networkmanager.GetCoreNetworkPolicyDocumentSegment{
   149  // {
   150  // Name: "segment",
   151  // },
   152  // },
   153  // }, nil);
   154  // if err != nil {
   155  // return err
   156  // }
   157  // exampleCoreNetwork, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
   158  // GlobalNetworkId: exampleGlobalNetwork.ID(),
   159  // BasePolicyDocument: pulumi.String(base.Json),
   160  // CreateBasePolicy: pulumi.Bool(true),
   161  // })
   162  // if err != nil {
   163  // return err
   164  // }
   165  // var splat0 []interface{}
   166  // for _, val0 := range exampleAwsSubnet {
   167  // splat0 = append(splat0, val0.Arn)
   168  // }
   169  // exampleVpcAttachment, err := networkmanager.NewVpcAttachment(ctx, "example", &networkmanager.VpcAttachmentArgs{
   170  // CoreNetworkId: exampleCoreNetwork.ID(),
   171  // SubnetArns: toPulumiArray(splat0),
   172  // VpcArn: pulumi.Any(exampleAwsVpc.Arn),
   173  // })
   174  // if err != nil {
   175  // return err
   176  // }
   177  // example := networkmanager.GetCoreNetworkPolicyDocumentOutput(ctx, networkmanager.GetCoreNetworkPolicyDocumentOutputArgs{
   178  // CoreNetworkConfigurations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArray{
   179  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArgs{
   180  // AsnRanges: pulumi.StringArray{
   181  // pulumi.String("65022-65534"),
   182  // },
   183  // EdgeLocations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArray{
   184  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArgs{
   185  // Location: pulumi.String("us-west-2"),
   186  // Asn: pulumi.String("65500"),
   187  // },
   188  // },
   189  // },
   190  // },
   191  // Segments: networkmanager.GetCoreNetworkPolicyDocumentSegmentArray{
   192  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentArgs{
   193  // Name: pulumi.String("segment"),
   194  // },
   195  // },
   196  // SegmentActions: networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArray{
   197  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArgs{
   198  // Action: pulumi.String("create-route"),
   199  // Segment: pulumi.String("segment"),
   200  // DestinationCidrBlocks: pulumi.StringArray{
   201  // pulumi.String("0.0.0.0/0"),
   202  // },
   203  // Destinations: pulumi.StringArray{
   204  // exampleVpcAttachment.ID(),
   205  // },
   206  // },
   207  // },
   208  // }, nil);
   209  // _, err = networkmanager.NewCoreNetworkPolicyAttachment(ctx, "example", &networkmanager.CoreNetworkPolicyAttachmentArgs{
   210  // CoreNetworkId: exampleCoreNetwork.ID(),
   211  // PolicyDocument: example.ApplyT(func(example networkmanager.GetCoreNetworkPolicyDocumentResult) (*string, error) {
   212  // return &example.Json, nil
   213  // }).(pulumi.StringPtrOutput),
   214  // })
   215  // if err != nil {
   216  // return err
   217  // }
   218  // return nil
   219  // })
   220  // }
   221  // func toPulumiArray(arr []) pulumi.Array {
   222  // var pulumiArr pulumi.Array
   223  // for _, v := range arr {
   224  // pulumiArr = append(pulumiArr, pulumi.(v))
   225  // }
   226  // return pulumiArr
   227  // }
   228  // ```
   229  // <!--End PulumiCodeChooser -->
   230  //
   231  // ### Option 2 - createBasePolicy only
   232  //
   233  // <!--Start PulumiCodeChooser -->
   234  // ```go
   235  // package main
   236  //
   237  // import (
   238  //
   239  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
   240  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
   241  //
   242  // )
   243  // func main() {
   244  // pulumi.Run(func(ctx *pulumi.Context) error {
   245  // exampleGlobalNetwork, err := networkmanager.NewGlobalNetwork(ctx, "example", nil)
   246  // if err != nil {
   247  // return err
   248  // }
   249  // exampleCoreNetwork, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
   250  // GlobalNetworkId: exampleGlobalNetwork.ID(),
   251  // CreateBasePolicy: pulumi.Bool(true),
   252  // })
   253  // if err != nil {
   254  // return err
   255  // }
   256  // var splat0 []interface{}
   257  // for _, val0 := range exampleAwsSubnet {
   258  // splat0 = append(splat0, val0.Arn)
   259  // }
   260  // exampleVpcAttachment, err := networkmanager.NewVpcAttachment(ctx, "example", &networkmanager.VpcAttachmentArgs{
   261  // CoreNetworkId: exampleCoreNetwork.ID(),
   262  // SubnetArns: toPulumiArray(splat0),
   263  // VpcArn: pulumi.Any(exampleAwsVpc.Arn),
   264  // })
   265  // if err != nil {
   266  // return err
   267  // }
   268  // example := networkmanager.GetCoreNetworkPolicyDocumentOutput(ctx, networkmanager.GetCoreNetworkPolicyDocumentOutputArgs{
   269  // CoreNetworkConfigurations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArray{
   270  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArgs{
   271  // AsnRanges: pulumi.StringArray{
   272  // pulumi.String("65022-65534"),
   273  // },
   274  // EdgeLocations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArray{
   275  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArgs{
   276  // Location: pulumi.String("us-west-2"),
   277  // },
   278  // },
   279  // },
   280  // },
   281  // Segments: networkmanager.GetCoreNetworkPolicyDocumentSegmentArray{
   282  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentArgs{
   283  // Name: pulumi.String("segment"),
   284  // },
   285  // },
   286  // SegmentActions: networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArray{
   287  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArgs{
   288  // Action: pulumi.String("create-route"),
   289  // Segment: pulumi.String("segment"),
   290  // DestinationCidrBlocks: pulumi.StringArray{
   291  // pulumi.String("0.0.0.0/0"),
   292  // },
   293  // Destinations: pulumi.StringArray{
   294  // exampleVpcAttachment.ID(),
   295  // },
   296  // },
   297  // },
   298  // }, nil);
   299  // _, err = networkmanager.NewCoreNetworkPolicyAttachment(ctx, "example", &networkmanager.CoreNetworkPolicyAttachmentArgs{
   300  // CoreNetworkId: exampleCoreNetwork.ID(),
   301  // PolicyDocument: example.ApplyT(func(example networkmanager.GetCoreNetworkPolicyDocumentResult) (*string, error) {
   302  // return &example.Json, nil
   303  // }).(pulumi.StringPtrOutput),
   304  // })
   305  // if err != nil {
   306  // return err
   307  // }
   308  // return nil
   309  // })
   310  // }
   311  // func toPulumiArray(arr []) pulumi.Array {
   312  // var pulumiArr pulumi.Array
   313  // for _, v := range arr {
   314  // pulumiArr = append(pulumiArr, pulumi.(v))
   315  // }
   316  // return pulumiArr
   317  // }
   318  // ```
   319  // <!--End PulumiCodeChooser -->
   320  //
   321  // ### With VPC Attachment (Multi-Region)
   322  //
   323  // The example below illustrates the scenario where your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Set the `createBasePolicy` argument of the `networkmanager.CoreNetwork` resource to `true` if your core network does not currently have any `LIVE` policies (e.g. this is the first `pulumi up` with the core network resource), since a `LIVE` policy is required before VPCs can be attached to the core network. Otherwise, if your core network already has a `LIVE` policy, you may exclude the `createBasePolicy` argument. For multi-region in a core network that does not yet have a `LIVE` policy, there are 2 options:
   324  //
   325  // - Option 1: Use the `basePolicyDocument` argument that allows the most customizations to a base policy. Use this to customize the `edgeLocations` `asn`. In the example below, `us-west-2`, `us-east-1` and specific ASNs are used in the base policy.
   326  // - Option 2: Pass a list of regions to the `networkmanager.CoreNetwork` `basePolicyRegions` argument. In the example below, `us-west-2` and `us-east-1` are specified in the base policy.
   327  //
   328  // ### Option 1 - using basePolicyDocument
   329  //
   330  // <!--Start PulumiCodeChooser -->
   331  // ```go
   332  // package main
   333  //
   334  // import (
   335  //
   336  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
   337  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
   338  //
   339  // )
   340  // func main() {
   341  // pulumi.Run(func(ctx *pulumi.Context) error {
   342  // exampleGlobalNetwork, err := networkmanager.NewGlobalNetwork(ctx, "example", nil)
   343  // if err != nil {
   344  // return err
   345  // }
   346  // base, err := networkmanager.GetCoreNetworkPolicyDocument(ctx, &networkmanager.GetCoreNetworkPolicyDocumentArgs{
   347  // CoreNetworkConfigurations: []networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfiguration{
   348  // {
   349  // AsnRanges: []string{
   350  // "65022-65534",
   351  // },
   352  // EdgeLocations: []networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocation{
   353  // {
   354  // Location: "us-west-2",
   355  // Asn: pulumi.StringRef("65500"),
   356  // },
   357  // {
   358  // Location: "us-east-1",
   359  // Asn: pulumi.StringRef("65501"),
   360  // },
   361  // },
   362  // },
   363  // },
   364  // Segments: []networkmanager.GetCoreNetworkPolicyDocumentSegment{
   365  // {
   366  // Name: "segment",
   367  // },
   368  // },
   369  // }, nil);
   370  // if err != nil {
   371  // return err
   372  // }
   373  // exampleCoreNetwork, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
   374  // GlobalNetworkId: exampleGlobalNetwork.ID(),
   375  // BasePolicyDocument: pulumi.String(base.Json),
   376  // CreateBasePolicy: pulumi.Bool(true),
   377  // })
   378  // if err != nil {
   379  // return err
   380  // }
   381  // var splat0 []interface{}
   382  // for _, val0 := range exampleUsWest2AwsSubnet {
   383  // splat0 = append(splat0, val0.Arn)
   384  // }
   385  // exampleUsWest2, err := networkmanager.NewVpcAttachment(ctx, "example_us_west_2", &networkmanager.VpcAttachmentArgs{
   386  // CoreNetworkId: exampleCoreNetwork.ID(),
   387  // SubnetArns: toPulumiArray(splat0),
   388  // VpcArn: pulumi.Any(exampleUsWest2AwsVpc.Arn),
   389  // })
   390  // if err != nil {
   391  // return err
   392  // }
   393  // var splat1 []interface{}
   394  // for _, val0 := range exampleUsEast1AwsSubnet {
   395  // splat1 = append(splat1, val0.Arn)
   396  // }
   397  // exampleUsEast1, err := networkmanager.NewVpcAttachment(ctx, "example_us_east_1", &networkmanager.VpcAttachmentArgs{
   398  // CoreNetworkId: exampleCoreNetwork.ID(),
   399  // SubnetArns: toPulumiArray(splat1),
   400  // VpcArn: pulumi.Any(exampleUsEast1AwsVpc.Arn),
   401  // })
   402  // if err != nil {
   403  // return err
   404  // }
   405  // example := networkmanager.GetCoreNetworkPolicyDocumentOutput(ctx, networkmanager.GetCoreNetworkPolicyDocumentOutputArgs{
   406  // CoreNetworkConfigurations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArray{
   407  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArgs{
   408  // AsnRanges: pulumi.StringArray{
   409  // pulumi.String("65022-65534"),
   410  // },
   411  // EdgeLocations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArray{
   412  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArgs{
   413  // Location: pulumi.String("us-west-2"),
   414  // Asn: pulumi.String("65500"),
   415  // },
   416  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArgs{
   417  // Location: pulumi.String("us-east-1"),
   418  // Asn: pulumi.String("65501"),
   419  // },
   420  // },
   421  // },
   422  // },
   423  // Segments: networkmanager.GetCoreNetworkPolicyDocumentSegmentArray{
   424  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentArgs{
   425  // Name: pulumi.String("segment"),
   426  // },
   427  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentArgs{
   428  // Name: pulumi.String("segment2"),
   429  // },
   430  // },
   431  // SegmentActions: networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArray{
   432  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArgs{
   433  // Action: pulumi.String("create-route"),
   434  // Segment: pulumi.String("segment"),
   435  // DestinationCidrBlocks: pulumi.StringArray{
   436  // pulumi.String("10.0.0.0/16"),
   437  // },
   438  // Destinations: pulumi.StringArray{
   439  // exampleUsWest2.ID(),
   440  // },
   441  // },
   442  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArgs{
   443  // Action: pulumi.String("create-route"),
   444  // Segment: pulumi.String("segment"),
   445  // DestinationCidrBlocks: pulumi.StringArray{
   446  // pulumi.String("10.1.0.0/16"),
   447  // },
   448  // Destinations: pulumi.StringArray{
   449  // exampleUsEast1.ID(),
   450  // },
   451  // },
   452  // },
   453  // }, nil);
   454  // _, err = networkmanager.NewCoreNetworkPolicyAttachment(ctx, "example", &networkmanager.CoreNetworkPolicyAttachmentArgs{
   455  // CoreNetworkId: exampleCoreNetwork.ID(),
   456  // PolicyDocument: example.ApplyT(func(example networkmanager.GetCoreNetworkPolicyDocumentResult) (*string, error) {
   457  // return &example.Json, nil
   458  // }).(pulumi.StringPtrOutput),
   459  // })
   460  // if err != nil {
   461  // return err
   462  // }
   463  // return nil
   464  // })
   465  // }
   466  // func toPulumiArray(arr []) pulumi.Array {
   467  // var pulumiArr pulumi.Array
   468  // for _, v := range arr {
   469  // pulumiArr = append(pulumiArr, pulumi.(v))
   470  // }
   471  // return pulumiArr
   472  // }
   473  // ```
   474  // <!--End PulumiCodeChooser -->
   475  //
   476  // ### Option 2 - using basePolicyRegions
   477  //
   478  // <!--Start PulumiCodeChooser -->
   479  // ```go
   480  // package main
   481  //
   482  // import (
   483  //
   484  //	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/networkmanager"
   485  //	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
   486  //
   487  // )
   488  // func main() {
   489  // pulumi.Run(func(ctx *pulumi.Context) error {
   490  // exampleGlobalNetwork, err := networkmanager.NewGlobalNetwork(ctx, "example", nil)
   491  // if err != nil {
   492  // return err
   493  // }
   494  // exampleCoreNetwork, err := networkmanager.NewCoreNetwork(ctx, "example", &networkmanager.CoreNetworkArgs{
   495  // GlobalNetworkId: exampleGlobalNetwork.ID(),
   496  // BasePolicyRegions: pulumi.StringArray{
   497  // pulumi.String("us-west-2"),
   498  // pulumi.String("us-east-1"),
   499  // },
   500  // CreateBasePolicy: pulumi.Bool(true),
   501  // })
   502  // if err != nil {
   503  // return err
   504  // }
   505  // var splat0 []interface{}
   506  // for _, val0 := range exampleUsWest2AwsSubnet {
   507  // splat0 = append(splat0, val0.Arn)
   508  // }
   509  // exampleUsWest2, err := networkmanager.NewVpcAttachment(ctx, "example_us_west_2", &networkmanager.VpcAttachmentArgs{
   510  // CoreNetworkId: exampleCoreNetwork.ID(),
   511  // SubnetArns: toPulumiArray(splat0),
   512  // VpcArn: pulumi.Any(exampleUsWest2AwsVpc.Arn),
   513  // })
   514  // if err != nil {
   515  // return err
   516  // }
   517  // var splat1 []interface{}
   518  // for _, val0 := range exampleUsEast1AwsSubnet {
   519  // splat1 = append(splat1, val0.Arn)
   520  // }
   521  // exampleUsEast1, err := networkmanager.NewVpcAttachment(ctx, "example_us_east_1", &networkmanager.VpcAttachmentArgs{
   522  // CoreNetworkId: exampleCoreNetwork.ID(),
   523  // SubnetArns: toPulumiArray(splat1),
   524  // VpcArn: pulumi.Any(exampleUsEast1AwsVpc.Arn),
   525  // })
   526  // if err != nil {
   527  // return err
   528  // }
   529  // example := networkmanager.GetCoreNetworkPolicyDocumentOutput(ctx, networkmanager.GetCoreNetworkPolicyDocumentOutputArgs{
   530  // CoreNetworkConfigurations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArray{
   531  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationArgs{
   532  // AsnRanges: pulumi.StringArray{
   533  // pulumi.String("65022-65534"),
   534  // },
   535  // EdgeLocations: networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArray{
   536  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArgs{
   537  // Location: pulumi.String("us-west-2"),
   538  // },
   539  // &networkmanager.GetCoreNetworkPolicyDocumentCoreNetworkConfigurationEdgeLocationArgs{
   540  // Location: pulumi.String("us-east-1"),
   541  // },
   542  // },
   543  // },
   544  // },
   545  // Segments: networkmanager.GetCoreNetworkPolicyDocumentSegmentArray{
   546  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentArgs{
   547  // Name: pulumi.String("segment"),
   548  // },
   549  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentArgs{
   550  // Name: pulumi.String("segment2"),
   551  // },
   552  // },
   553  // SegmentActions: networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArray{
   554  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArgs{
   555  // Action: pulumi.String("create-route"),
   556  // Segment: pulumi.String("segment"),
   557  // DestinationCidrBlocks: pulumi.StringArray{
   558  // pulumi.String("10.0.0.0/16"),
   559  // },
   560  // Destinations: pulumi.StringArray{
   561  // exampleUsWest2.ID(),
   562  // },
   563  // },
   564  // &networkmanager.GetCoreNetworkPolicyDocumentSegmentActionArgs{
   565  // Action: pulumi.String("create-route"),
   566  // Segment: pulumi.String("segment"),
   567  // DestinationCidrBlocks: pulumi.StringArray{
   568  // pulumi.String("10.1.0.0/16"),
   569  // },
   570  // Destinations: pulumi.StringArray{
   571  // exampleUsEast1.ID(),
   572  // },
   573  // },
   574  // },
   575  // }, nil);
   576  // _, err = networkmanager.NewCoreNetworkPolicyAttachment(ctx, "example", &networkmanager.CoreNetworkPolicyAttachmentArgs{
   577  // CoreNetworkId: exampleCoreNetwork.ID(),
   578  // PolicyDocument: example.ApplyT(func(example networkmanager.GetCoreNetworkPolicyDocumentResult) (*string, error) {
   579  // return &example.Json, nil
   580  // }).(pulumi.StringPtrOutput),
   581  // })
   582  // if err != nil {
   583  // return err
   584  // }
   585  // return nil
   586  // })
   587  // }
   588  // func toPulumiArray(arr []) pulumi.Array {
   589  // var pulumiArr pulumi.Array
   590  // for _, v := range arr {
   591  // pulumiArr = append(pulumiArr, pulumi.(v))
   592  // }
   593  // return pulumiArr
   594  // }
   595  // ```
   596  // <!--End PulumiCodeChooser -->
   597  //
   598  // ## Import
   599  //
   600  // Using `pulumi import`, import `aws_networkmanager_core_network` using the core network ID. For example:
   601  //
   602  // ```sh
   603  // $ pulumi import aws:networkmanager/coreNetwork:CoreNetwork example core-network-0d47f6t230mz46dy4
   604  // ```
   605  type CoreNetwork struct {
   606  	pulumi.CustomResourceState
   607  
   608  	// Core Network Amazon Resource Name (ARN).
   609  	Arn pulumi.StringOutput `pulumi:"arn"`
   610  	// Sets the base policy document for the core network. Refer to the [Core network policies documentation](https://docs.aws.amazon.com/network-manager/latest/cloudwan/cloudwan-policy-change-sets.html) for more information.
   611  	BasePolicyDocument pulumi.StringPtrOutput `pulumi:"basePolicyDocument"`
   612  	// The base policy created by setting the `createBasePolicy` argument to `true` requires a region to be set in the `edge-locations`, `location` key. If `basePolicyRegion` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   613  	//
   614  	// Deprecated: Use the basePolicyRegions argument instead. This argument will be removed in the next major version of the provider.
   615  	BasePolicyRegion pulumi.StringPtrOutput `pulumi:"basePolicyRegion"`
   616  	// A list of regions to add to the base policy. The base policy created by setting the `createBasePolicy` argument to `true` requires one or more regions to be set in the `edge-locations`, `location` key. If `basePolicyRegions` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   617  	BasePolicyRegions pulumi.StringArrayOutput `pulumi:"basePolicyRegions"`
   618  	// Specifies whether to create a base policy when a core network is created or updated. A base policy is created and set to `LIVE` to allow attachments to the core network (e.g. VPC Attachments) before applying a policy document provided using the `networkmanager.CoreNetworkPolicyAttachment` resource. This base policy is needed if your core network does not have any `LIVE` policies and your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Valid values are `true` or `false`. An example of this Pulumi snippet can be found above for VPC Attachment in a single region and for VPC Attachment multi-region. An example base policy is shown below. This base policy is overridden with the policy that you specify in the `networkmanager.CoreNetworkPolicyAttachment` resource.
   619  	CreateBasePolicy pulumi.BoolPtrOutput `pulumi:"createBasePolicy"`
   620  	// Timestamp when a core network was created.
   621  	CreatedAt pulumi.StringOutput `pulumi:"createdAt"`
   622  	// Description of the Core Network.
   623  	Description pulumi.StringPtrOutput `pulumi:"description"`
   624  	// One or more blocks detailing the edges within a core network. Detailed below.
   625  	Edges CoreNetworkEdgeArrayOutput `pulumi:"edges"`
   626  	// The ID of the global network that a core network will be a part of.
   627  	GlobalNetworkId pulumi.StringOutput `pulumi:"globalNetworkId"`
   628  	// One or more blocks detailing the segments within a core network. Detailed below.
   629  	Segments CoreNetworkSegmentArrayOutput `pulumi:"segments"`
   630  	// Current state of a core network.
   631  	State pulumi.StringOutput `pulumi:"state"`
   632  	// Key-value tags for the Core Network. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   633  	Tags pulumi.StringMapOutput `pulumi:"tags"`
   634  	// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   635  	//
   636  	// Deprecated: Please use `tags` instead.
   637  	TagsAll pulumi.StringMapOutput `pulumi:"tagsAll"`
   638  }
   639  
   640  // NewCoreNetwork registers a new resource with the given unique name, arguments, and options.
   641  func NewCoreNetwork(ctx *pulumi.Context,
   642  	name string, args *CoreNetworkArgs, opts ...pulumi.ResourceOption) (*CoreNetwork, error) {
   643  	if args == nil {
   644  		return nil, errors.New("missing one or more required arguments")
   645  	}
   646  
   647  	if args.GlobalNetworkId == nil {
   648  		return nil, errors.New("invalid value for required argument 'GlobalNetworkId'")
   649  	}
   650  	opts = internal.PkgResourceDefaultOpts(opts)
   651  	var resource CoreNetwork
   652  	err := ctx.RegisterResource("aws:networkmanager/coreNetwork:CoreNetwork", name, args, &resource, opts...)
   653  	if err != nil {
   654  		return nil, err
   655  	}
   656  	return &resource, nil
   657  }
   658  
   659  // GetCoreNetwork gets an existing CoreNetwork resource's state with the given name, ID, and optional
   660  // state properties that are used to uniquely qualify the lookup (nil if not required).
   661  func GetCoreNetwork(ctx *pulumi.Context,
   662  	name string, id pulumi.IDInput, state *CoreNetworkState, opts ...pulumi.ResourceOption) (*CoreNetwork, error) {
   663  	var resource CoreNetwork
   664  	err := ctx.ReadResource("aws:networkmanager/coreNetwork:CoreNetwork", name, id, state, &resource, opts...)
   665  	if err != nil {
   666  		return nil, err
   667  	}
   668  	return &resource, nil
   669  }
   670  
   671  // Input properties used for looking up and filtering CoreNetwork resources.
   672  type coreNetworkState struct {
   673  	// Core Network Amazon Resource Name (ARN).
   674  	Arn *string `pulumi:"arn"`
   675  	// Sets the base policy document for the core network. Refer to the [Core network policies documentation](https://docs.aws.amazon.com/network-manager/latest/cloudwan/cloudwan-policy-change-sets.html) for more information.
   676  	BasePolicyDocument *string `pulumi:"basePolicyDocument"`
   677  	// The base policy created by setting the `createBasePolicy` argument to `true` requires a region to be set in the `edge-locations`, `location` key. If `basePolicyRegion` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   678  	//
   679  	// Deprecated: Use the basePolicyRegions argument instead. This argument will be removed in the next major version of the provider.
   680  	BasePolicyRegion *string `pulumi:"basePolicyRegion"`
   681  	// A list of regions to add to the base policy. The base policy created by setting the `createBasePolicy` argument to `true` requires one or more regions to be set in the `edge-locations`, `location` key. If `basePolicyRegions` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   682  	BasePolicyRegions []string `pulumi:"basePolicyRegions"`
   683  	// Specifies whether to create a base policy when a core network is created or updated. A base policy is created and set to `LIVE` to allow attachments to the core network (e.g. VPC Attachments) before applying a policy document provided using the `networkmanager.CoreNetworkPolicyAttachment` resource. This base policy is needed if your core network does not have any `LIVE` policies and your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Valid values are `true` or `false`. An example of this Pulumi snippet can be found above for VPC Attachment in a single region and for VPC Attachment multi-region. An example base policy is shown below. This base policy is overridden with the policy that you specify in the `networkmanager.CoreNetworkPolicyAttachment` resource.
   684  	CreateBasePolicy *bool `pulumi:"createBasePolicy"`
   685  	// Timestamp when a core network was created.
   686  	CreatedAt *string `pulumi:"createdAt"`
   687  	// Description of the Core Network.
   688  	Description *string `pulumi:"description"`
   689  	// One or more blocks detailing the edges within a core network. Detailed below.
   690  	Edges []CoreNetworkEdge `pulumi:"edges"`
   691  	// The ID of the global network that a core network will be a part of.
   692  	GlobalNetworkId *string `pulumi:"globalNetworkId"`
   693  	// One or more blocks detailing the segments within a core network. Detailed below.
   694  	Segments []CoreNetworkSegment `pulumi:"segments"`
   695  	// Current state of a core network.
   696  	State *string `pulumi:"state"`
   697  	// Key-value tags for the Core Network. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   698  	Tags map[string]string `pulumi:"tags"`
   699  	// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   700  	//
   701  	// Deprecated: Please use `tags` instead.
   702  	TagsAll map[string]string `pulumi:"tagsAll"`
   703  }
   704  
   705  type CoreNetworkState struct {
   706  	// Core Network Amazon Resource Name (ARN).
   707  	Arn pulumi.StringPtrInput
   708  	// Sets the base policy document for the core network. Refer to the [Core network policies documentation](https://docs.aws.amazon.com/network-manager/latest/cloudwan/cloudwan-policy-change-sets.html) for more information.
   709  	BasePolicyDocument pulumi.StringPtrInput
   710  	// The base policy created by setting the `createBasePolicy` argument to `true` requires a region to be set in the `edge-locations`, `location` key. If `basePolicyRegion` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   711  	//
   712  	// Deprecated: Use the basePolicyRegions argument instead. This argument will be removed in the next major version of the provider.
   713  	BasePolicyRegion pulumi.StringPtrInput
   714  	// A list of regions to add to the base policy. The base policy created by setting the `createBasePolicy` argument to `true` requires one or more regions to be set in the `edge-locations`, `location` key. If `basePolicyRegions` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   715  	BasePolicyRegions pulumi.StringArrayInput
   716  	// Specifies whether to create a base policy when a core network is created or updated. A base policy is created and set to `LIVE` to allow attachments to the core network (e.g. VPC Attachments) before applying a policy document provided using the `networkmanager.CoreNetworkPolicyAttachment` resource. This base policy is needed if your core network does not have any `LIVE` policies and your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Valid values are `true` or `false`. An example of this Pulumi snippet can be found above for VPC Attachment in a single region and for VPC Attachment multi-region. An example base policy is shown below. This base policy is overridden with the policy that you specify in the `networkmanager.CoreNetworkPolicyAttachment` resource.
   717  	CreateBasePolicy pulumi.BoolPtrInput
   718  	// Timestamp when a core network was created.
   719  	CreatedAt pulumi.StringPtrInput
   720  	// Description of the Core Network.
   721  	Description pulumi.StringPtrInput
   722  	// One or more blocks detailing the edges within a core network. Detailed below.
   723  	Edges CoreNetworkEdgeArrayInput
   724  	// The ID of the global network that a core network will be a part of.
   725  	GlobalNetworkId pulumi.StringPtrInput
   726  	// One or more blocks detailing the segments within a core network. Detailed below.
   727  	Segments CoreNetworkSegmentArrayInput
   728  	// Current state of a core network.
   729  	State pulumi.StringPtrInput
   730  	// Key-value tags for the Core Network. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   731  	Tags pulumi.StringMapInput
   732  	// A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   733  	//
   734  	// Deprecated: Please use `tags` instead.
   735  	TagsAll pulumi.StringMapInput
   736  }
   737  
   738  func (CoreNetworkState) ElementType() reflect.Type {
   739  	return reflect.TypeOf((*coreNetworkState)(nil)).Elem()
   740  }
   741  
   742  type coreNetworkArgs struct {
   743  	// Sets the base policy document for the core network. Refer to the [Core network policies documentation](https://docs.aws.amazon.com/network-manager/latest/cloudwan/cloudwan-policy-change-sets.html) for more information.
   744  	BasePolicyDocument *string `pulumi:"basePolicyDocument"`
   745  	// The base policy created by setting the `createBasePolicy` argument to `true` requires a region to be set in the `edge-locations`, `location` key. If `basePolicyRegion` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   746  	//
   747  	// Deprecated: Use the basePolicyRegions argument instead. This argument will be removed in the next major version of the provider.
   748  	BasePolicyRegion *string `pulumi:"basePolicyRegion"`
   749  	// A list of regions to add to the base policy. The base policy created by setting the `createBasePolicy` argument to `true` requires one or more regions to be set in the `edge-locations`, `location` key. If `basePolicyRegions` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   750  	BasePolicyRegions []string `pulumi:"basePolicyRegions"`
   751  	// Specifies whether to create a base policy when a core network is created or updated. A base policy is created and set to `LIVE` to allow attachments to the core network (e.g. VPC Attachments) before applying a policy document provided using the `networkmanager.CoreNetworkPolicyAttachment` resource. This base policy is needed if your core network does not have any `LIVE` policies and your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Valid values are `true` or `false`. An example of this Pulumi snippet can be found above for VPC Attachment in a single region and for VPC Attachment multi-region. An example base policy is shown below. This base policy is overridden with the policy that you specify in the `networkmanager.CoreNetworkPolicyAttachment` resource.
   752  	CreateBasePolicy *bool `pulumi:"createBasePolicy"`
   753  	// Description of the Core Network.
   754  	Description *string `pulumi:"description"`
   755  	// The ID of the global network that a core network will be a part of.
   756  	GlobalNetworkId string `pulumi:"globalNetworkId"`
   757  	// Key-value tags for the Core Network. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   758  	Tags map[string]string `pulumi:"tags"`
   759  }
   760  
   761  // The set of arguments for constructing a CoreNetwork resource.
   762  type CoreNetworkArgs struct {
   763  	// Sets the base policy document for the core network. Refer to the [Core network policies documentation](https://docs.aws.amazon.com/network-manager/latest/cloudwan/cloudwan-policy-change-sets.html) for more information.
   764  	BasePolicyDocument pulumi.StringPtrInput
   765  	// The base policy created by setting the `createBasePolicy` argument to `true` requires a region to be set in the `edge-locations`, `location` key. If `basePolicyRegion` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   766  	//
   767  	// Deprecated: Use the basePolicyRegions argument instead. This argument will be removed in the next major version of the provider.
   768  	BasePolicyRegion pulumi.StringPtrInput
   769  	// A list of regions to add to the base policy. The base policy created by setting the `createBasePolicy` argument to `true` requires one or more regions to be set in the `edge-locations`, `location` key. If `basePolicyRegions` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   770  	BasePolicyRegions pulumi.StringArrayInput
   771  	// Specifies whether to create a base policy when a core network is created or updated. A base policy is created and set to `LIVE` to allow attachments to the core network (e.g. VPC Attachments) before applying a policy document provided using the `networkmanager.CoreNetworkPolicyAttachment` resource. This base policy is needed if your core network does not have any `LIVE` policies and your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Valid values are `true` or `false`. An example of this Pulumi snippet can be found above for VPC Attachment in a single region and for VPC Attachment multi-region. An example base policy is shown below. This base policy is overridden with the policy that you specify in the `networkmanager.CoreNetworkPolicyAttachment` resource.
   772  	CreateBasePolicy pulumi.BoolPtrInput
   773  	// Description of the Core Network.
   774  	Description pulumi.StringPtrInput
   775  	// The ID of the global network that a core network will be a part of.
   776  	GlobalNetworkId pulumi.StringInput
   777  	// Key-value tags for the Core Network. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   778  	Tags pulumi.StringMapInput
   779  }
   780  
   781  func (CoreNetworkArgs) ElementType() reflect.Type {
   782  	return reflect.TypeOf((*coreNetworkArgs)(nil)).Elem()
   783  }
   784  
   785  type CoreNetworkInput interface {
   786  	pulumi.Input
   787  
   788  	ToCoreNetworkOutput() CoreNetworkOutput
   789  	ToCoreNetworkOutputWithContext(ctx context.Context) CoreNetworkOutput
   790  }
   791  
   792  func (*CoreNetwork) ElementType() reflect.Type {
   793  	return reflect.TypeOf((**CoreNetwork)(nil)).Elem()
   794  }
   795  
   796  func (i *CoreNetwork) ToCoreNetworkOutput() CoreNetworkOutput {
   797  	return i.ToCoreNetworkOutputWithContext(context.Background())
   798  }
   799  
   800  func (i *CoreNetwork) ToCoreNetworkOutputWithContext(ctx context.Context) CoreNetworkOutput {
   801  	return pulumi.ToOutputWithContext(ctx, i).(CoreNetworkOutput)
   802  }
   803  
   804  // CoreNetworkArrayInput is an input type that accepts CoreNetworkArray and CoreNetworkArrayOutput values.
   805  // You can construct a concrete instance of `CoreNetworkArrayInput` via:
   806  //
   807  //	CoreNetworkArray{ CoreNetworkArgs{...} }
   808  type CoreNetworkArrayInput interface {
   809  	pulumi.Input
   810  
   811  	ToCoreNetworkArrayOutput() CoreNetworkArrayOutput
   812  	ToCoreNetworkArrayOutputWithContext(context.Context) CoreNetworkArrayOutput
   813  }
   814  
   815  type CoreNetworkArray []CoreNetworkInput
   816  
   817  func (CoreNetworkArray) ElementType() reflect.Type {
   818  	return reflect.TypeOf((*[]*CoreNetwork)(nil)).Elem()
   819  }
   820  
   821  func (i CoreNetworkArray) ToCoreNetworkArrayOutput() CoreNetworkArrayOutput {
   822  	return i.ToCoreNetworkArrayOutputWithContext(context.Background())
   823  }
   824  
   825  func (i CoreNetworkArray) ToCoreNetworkArrayOutputWithContext(ctx context.Context) CoreNetworkArrayOutput {
   826  	return pulumi.ToOutputWithContext(ctx, i).(CoreNetworkArrayOutput)
   827  }
   828  
   829  // CoreNetworkMapInput is an input type that accepts CoreNetworkMap and CoreNetworkMapOutput values.
   830  // You can construct a concrete instance of `CoreNetworkMapInput` via:
   831  //
   832  //	CoreNetworkMap{ "key": CoreNetworkArgs{...} }
   833  type CoreNetworkMapInput interface {
   834  	pulumi.Input
   835  
   836  	ToCoreNetworkMapOutput() CoreNetworkMapOutput
   837  	ToCoreNetworkMapOutputWithContext(context.Context) CoreNetworkMapOutput
   838  }
   839  
   840  type CoreNetworkMap map[string]CoreNetworkInput
   841  
   842  func (CoreNetworkMap) ElementType() reflect.Type {
   843  	return reflect.TypeOf((*map[string]*CoreNetwork)(nil)).Elem()
   844  }
   845  
   846  func (i CoreNetworkMap) ToCoreNetworkMapOutput() CoreNetworkMapOutput {
   847  	return i.ToCoreNetworkMapOutputWithContext(context.Background())
   848  }
   849  
   850  func (i CoreNetworkMap) ToCoreNetworkMapOutputWithContext(ctx context.Context) CoreNetworkMapOutput {
   851  	return pulumi.ToOutputWithContext(ctx, i).(CoreNetworkMapOutput)
   852  }
   853  
   854  type CoreNetworkOutput struct{ *pulumi.OutputState }
   855  
   856  func (CoreNetworkOutput) ElementType() reflect.Type {
   857  	return reflect.TypeOf((**CoreNetwork)(nil)).Elem()
   858  }
   859  
   860  func (o CoreNetworkOutput) ToCoreNetworkOutput() CoreNetworkOutput {
   861  	return o
   862  }
   863  
   864  func (o CoreNetworkOutput) ToCoreNetworkOutputWithContext(ctx context.Context) CoreNetworkOutput {
   865  	return o
   866  }
   867  
   868  // Core Network Amazon Resource Name (ARN).
   869  func (o CoreNetworkOutput) Arn() pulumi.StringOutput {
   870  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringOutput { return v.Arn }).(pulumi.StringOutput)
   871  }
   872  
   873  // Sets the base policy document for the core network. Refer to the [Core network policies documentation](https://docs.aws.amazon.com/network-manager/latest/cloudwan/cloudwan-policy-change-sets.html) for more information.
   874  func (o CoreNetworkOutput) BasePolicyDocument() pulumi.StringPtrOutput {
   875  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringPtrOutput { return v.BasePolicyDocument }).(pulumi.StringPtrOutput)
   876  }
   877  
   878  // The base policy created by setting the `createBasePolicy` argument to `true` requires a region to be set in the `edge-locations`, `location` key. If `basePolicyRegion` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   879  //
   880  // Deprecated: Use the basePolicyRegions argument instead. This argument will be removed in the next major version of the provider.
   881  func (o CoreNetworkOutput) BasePolicyRegion() pulumi.StringPtrOutput {
   882  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringPtrOutput { return v.BasePolicyRegion }).(pulumi.StringPtrOutput)
   883  }
   884  
   885  // A list of regions to add to the base policy. The base policy created by setting the `createBasePolicy` argument to `true` requires one or more regions to be set in the `edge-locations`, `location` key. If `basePolicyRegions` is not specified, the region used in the base policy defaults to the region specified in the `provider` block.
   886  func (o CoreNetworkOutput) BasePolicyRegions() pulumi.StringArrayOutput {
   887  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringArrayOutput { return v.BasePolicyRegions }).(pulumi.StringArrayOutput)
   888  }
   889  
   890  // Specifies whether to create a base policy when a core network is created or updated. A base policy is created and set to `LIVE` to allow attachments to the core network (e.g. VPC Attachments) before applying a policy document provided using the `networkmanager.CoreNetworkPolicyAttachment` resource. This base policy is needed if your core network does not have any `LIVE` policies and your policy document has static routes pointing to VPC attachments and you want to attach your VPCs to the core network before applying the desired policy document. Valid values are `true` or `false`. An example of this Pulumi snippet can be found above for VPC Attachment in a single region and for VPC Attachment multi-region. An example base policy is shown below. This base policy is overridden with the policy that you specify in the `networkmanager.CoreNetworkPolicyAttachment` resource.
   891  func (o CoreNetworkOutput) CreateBasePolicy() pulumi.BoolPtrOutput {
   892  	return o.ApplyT(func(v *CoreNetwork) pulumi.BoolPtrOutput { return v.CreateBasePolicy }).(pulumi.BoolPtrOutput)
   893  }
   894  
   895  // Timestamp when a core network was created.
   896  func (o CoreNetworkOutput) CreatedAt() pulumi.StringOutput {
   897  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringOutput { return v.CreatedAt }).(pulumi.StringOutput)
   898  }
   899  
   900  // Description of the Core Network.
   901  func (o CoreNetworkOutput) Description() pulumi.StringPtrOutput {
   902  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringPtrOutput { return v.Description }).(pulumi.StringPtrOutput)
   903  }
   904  
   905  // One or more blocks detailing the edges within a core network. Detailed below.
   906  func (o CoreNetworkOutput) Edges() CoreNetworkEdgeArrayOutput {
   907  	return o.ApplyT(func(v *CoreNetwork) CoreNetworkEdgeArrayOutput { return v.Edges }).(CoreNetworkEdgeArrayOutput)
   908  }
   909  
   910  // The ID of the global network that a core network will be a part of.
   911  func (o CoreNetworkOutput) GlobalNetworkId() pulumi.StringOutput {
   912  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringOutput { return v.GlobalNetworkId }).(pulumi.StringOutput)
   913  }
   914  
   915  // One or more blocks detailing the segments within a core network. Detailed below.
   916  func (o CoreNetworkOutput) Segments() CoreNetworkSegmentArrayOutput {
   917  	return o.ApplyT(func(v *CoreNetwork) CoreNetworkSegmentArrayOutput { return v.Segments }).(CoreNetworkSegmentArrayOutput)
   918  }
   919  
   920  // Current state of a core network.
   921  func (o CoreNetworkOutput) State() pulumi.StringOutput {
   922  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringOutput { return v.State }).(pulumi.StringOutput)
   923  }
   924  
   925  // Key-value tags for the Core Network. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
   926  func (o CoreNetworkOutput) Tags() pulumi.StringMapOutput {
   927  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringMapOutput { return v.Tags }).(pulumi.StringMapOutput)
   928  }
   929  
   930  // A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
   931  //
   932  // Deprecated: Please use `tags` instead.
   933  func (o CoreNetworkOutput) TagsAll() pulumi.StringMapOutput {
   934  	return o.ApplyT(func(v *CoreNetwork) pulumi.StringMapOutput { return v.TagsAll }).(pulumi.StringMapOutput)
   935  }
   936  
   937  type CoreNetworkArrayOutput struct{ *pulumi.OutputState }
   938  
   939  func (CoreNetworkArrayOutput) ElementType() reflect.Type {
   940  	return reflect.TypeOf((*[]*CoreNetwork)(nil)).Elem()
   941  }
   942  
   943  func (o CoreNetworkArrayOutput) ToCoreNetworkArrayOutput() CoreNetworkArrayOutput {
   944  	return o
   945  }
   946  
   947  func (o CoreNetworkArrayOutput) ToCoreNetworkArrayOutputWithContext(ctx context.Context) CoreNetworkArrayOutput {
   948  	return o
   949  }
   950  
   951  func (o CoreNetworkArrayOutput) Index(i pulumi.IntInput) CoreNetworkOutput {
   952  	return pulumi.All(o, i).ApplyT(func(vs []interface{}) *CoreNetwork {
   953  		return vs[0].([]*CoreNetwork)[vs[1].(int)]
   954  	}).(CoreNetworkOutput)
   955  }
   956  
   957  type CoreNetworkMapOutput struct{ *pulumi.OutputState }
   958  
   959  func (CoreNetworkMapOutput) ElementType() reflect.Type {
   960  	return reflect.TypeOf((*map[string]*CoreNetwork)(nil)).Elem()
   961  }
   962  
   963  func (o CoreNetworkMapOutput) ToCoreNetworkMapOutput() CoreNetworkMapOutput {
   964  	return o
   965  }
   966  
   967  func (o CoreNetworkMapOutput) ToCoreNetworkMapOutputWithContext(ctx context.Context) CoreNetworkMapOutput {
   968  	return o
   969  }
   970  
   971  func (o CoreNetworkMapOutput) MapIndex(k pulumi.StringInput) CoreNetworkOutput {
   972  	return pulumi.All(o, k).ApplyT(func(vs []interface{}) *CoreNetwork {
   973  		return vs[0].(map[string]*CoreNetwork)[vs[1].(string)]
   974  	}).(CoreNetworkOutput)
   975  }
   976  
   977  func init() {
   978  	pulumi.RegisterInputType(reflect.TypeOf((*CoreNetworkInput)(nil)).Elem(), &CoreNetwork{})
   979  	pulumi.RegisterInputType(reflect.TypeOf((*CoreNetworkArrayInput)(nil)).Elem(), CoreNetworkArray{})
   980  	pulumi.RegisterInputType(reflect.TypeOf((*CoreNetworkMapInput)(nil)).Elem(), CoreNetworkMap{})
   981  	pulumi.RegisterOutputType(CoreNetworkOutput{})
   982  	pulumi.RegisterOutputType(CoreNetworkArrayOutput{})
   983  	pulumi.RegisterOutputType(CoreNetworkMapOutput{})
   984  }