github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/ec2/networkAclRule.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 ec2 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 // Creates an entry (a rule) in a network ACL with the specified rule number. 16 // 17 // > **NOTE on Network ACLs and Network ACL Rules:** This provider currently 18 // provides both a standalone Network ACL Rule resource and a Network ACL resource with rules 19 // defined in-line. At this time you cannot use a Network ACL with in-line rules 20 // in conjunction with any Network ACL Rule resources. Doing so will cause 21 // a conflict of rule settings and will overwrite rules. 22 // 23 // ## Example Usage 24 // 25 // <!--Start PulumiCodeChooser --> 26 // ```go 27 // package main 28 // 29 // import ( 30 // 31 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/ec2" 32 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 33 // 34 // ) 35 // 36 // func main() { 37 // pulumi.Run(func(ctx *pulumi.Context) error { 38 // bar, err := ec2.NewNetworkAcl(ctx, "bar", &ec2.NetworkAclArgs{ 39 // VpcId: pulumi.Any(foo.Id), 40 // }) 41 // if err != nil { 42 // return err 43 // } 44 // _, err = ec2.NewNetworkAclRule(ctx, "bar", &ec2.NetworkAclRuleArgs{ 45 // NetworkAclId: bar.ID(), 46 // RuleNumber: pulumi.Int(200), 47 // Egress: pulumi.Bool(false), 48 // Protocol: pulumi.String("tcp"), 49 // RuleAction: pulumi.String("allow"), 50 // CidrBlock: pulumi.Any(foo.CidrBlock), 51 // FromPort: pulumi.Int(22), 52 // ToPort: pulumi.Int(22), 53 // }) 54 // if err != nil { 55 // return err 56 // } 57 // return nil 58 // }) 59 // } 60 // 61 // ``` 62 // <!--End PulumiCodeChooser --> 63 // 64 // > **Note:** One of either `cidrBlock` or `ipv6CidrBlock` is required. 65 // 66 // ## Import 67 // 68 // Using the procotol's decimal value: 69 // 70 // __Using `pulumi import` to import__ individual rules using `NETWORK_ACL_ID:RULE_NUMBER:PROTOCOL:EGRESS`, where `PROTOCOL` can be a decimal (such as "6") or string (such as "tcp") value. For example: 71 // 72 // Using the procotol's string value: 73 // 74 // ```sh 75 // $ pulumi import aws:ec2/networkAclRule:NetworkAclRule my_rule acl-7aaabd18:100:tcp:false 76 // ``` 77 // Using the procotol's decimal value: 78 // 79 // ```sh 80 // $ pulumi import aws:ec2/networkAclRule:NetworkAclRule my_rule acl-7aaabd18:100:6:false 81 // ``` 82 type NetworkAclRule struct { 83 pulumi.CustomResourceState 84 85 // The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24 ). 86 CidrBlock pulumi.StringPtrOutput `pulumi:"cidrBlock"` 87 // Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet). Default `false`. 88 Egress pulumi.BoolPtrOutput `pulumi:"egress"` 89 // The from port to match. 90 FromPort pulumi.IntPtrOutput `pulumi:"fromPort"` 91 // ICMP protocol: The ICMP code. Required if specifying ICMP for the protocolE.g., -1 92 // 93 // > **NOTE:** If the value of `protocol` is `-1` or `all`, the `fromPort` and `toPort` values will be ignored and the rule will apply to all ports. 94 // 95 // > **NOTE:** If the value of `icmpType` is `-1` (which results in a wildcard ICMP type), the `icmpCode` must also be set to `-1` (wildcard ICMP code). 96 // 97 // > Note: For more information on ICMP types and codes, see here: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml 98 IcmpCode pulumi.IntPtrOutput `pulumi:"icmpCode"` 99 // ICMP protocol: The ICMP type. Required if specifying ICMP for the protocolE.g., -1 100 IcmpType pulumi.IntPtrOutput `pulumi:"icmpType"` 101 // The IPv6 CIDR block to allow or deny. 102 Ipv6CidrBlock pulumi.StringPtrOutput `pulumi:"ipv6CidrBlock"` 103 // The ID of the network ACL. 104 NetworkAclId pulumi.StringOutput `pulumi:"networkAclId"` 105 // The protocol. A value of -1 means all protocols. 106 Protocol pulumi.StringOutput `pulumi:"protocol"` 107 // Indicates whether to allow or deny the traffic that matches the rule. Accepted values: `allow` | `deny` 108 RuleAction pulumi.StringOutput `pulumi:"ruleAction"` 109 // The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number. 110 RuleNumber pulumi.IntOutput `pulumi:"ruleNumber"` 111 // The to port to match. 112 ToPort pulumi.IntPtrOutput `pulumi:"toPort"` 113 } 114 115 // NewNetworkAclRule registers a new resource with the given unique name, arguments, and options. 116 func NewNetworkAclRule(ctx *pulumi.Context, 117 name string, args *NetworkAclRuleArgs, opts ...pulumi.ResourceOption) (*NetworkAclRule, error) { 118 if args == nil { 119 return nil, errors.New("missing one or more required arguments") 120 } 121 122 if args.NetworkAclId == nil { 123 return nil, errors.New("invalid value for required argument 'NetworkAclId'") 124 } 125 if args.Protocol == nil { 126 return nil, errors.New("invalid value for required argument 'Protocol'") 127 } 128 if args.RuleAction == nil { 129 return nil, errors.New("invalid value for required argument 'RuleAction'") 130 } 131 if args.RuleNumber == nil { 132 return nil, errors.New("invalid value for required argument 'RuleNumber'") 133 } 134 opts = internal.PkgResourceDefaultOpts(opts) 135 var resource NetworkAclRule 136 err := ctx.RegisterResource("aws:ec2/networkAclRule:NetworkAclRule", name, args, &resource, opts...) 137 if err != nil { 138 return nil, err 139 } 140 return &resource, nil 141 } 142 143 // GetNetworkAclRule gets an existing NetworkAclRule resource's state with the given name, ID, and optional 144 // state properties that are used to uniquely qualify the lookup (nil if not required). 145 func GetNetworkAclRule(ctx *pulumi.Context, 146 name string, id pulumi.IDInput, state *NetworkAclRuleState, opts ...pulumi.ResourceOption) (*NetworkAclRule, error) { 147 var resource NetworkAclRule 148 err := ctx.ReadResource("aws:ec2/networkAclRule:NetworkAclRule", name, id, state, &resource, opts...) 149 if err != nil { 150 return nil, err 151 } 152 return &resource, nil 153 } 154 155 // Input properties used for looking up and filtering NetworkAclRule resources. 156 type networkAclRuleState struct { 157 // The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24 ). 158 CidrBlock *string `pulumi:"cidrBlock"` 159 // Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet). Default `false`. 160 Egress *bool `pulumi:"egress"` 161 // The from port to match. 162 FromPort *int `pulumi:"fromPort"` 163 // ICMP protocol: The ICMP code. Required if specifying ICMP for the protocolE.g., -1 164 // 165 // > **NOTE:** If the value of `protocol` is `-1` or `all`, the `fromPort` and `toPort` values will be ignored and the rule will apply to all ports. 166 // 167 // > **NOTE:** If the value of `icmpType` is `-1` (which results in a wildcard ICMP type), the `icmpCode` must also be set to `-1` (wildcard ICMP code). 168 // 169 // > Note: For more information on ICMP types and codes, see here: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml 170 IcmpCode *int `pulumi:"icmpCode"` 171 // ICMP protocol: The ICMP type. Required if specifying ICMP for the protocolE.g., -1 172 IcmpType *int `pulumi:"icmpType"` 173 // The IPv6 CIDR block to allow or deny. 174 Ipv6CidrBlock *string `pulumi:"ipv6CidrBlock"` 175 // The ID of the network ACL. 176 NetworkAclId *string `pulumi:"networkAclId"` 177 // The protocol. A value of -1 means all protocols. 178 Protocol *string `pulumi:"protocol"` 179 // Indicates whether to allow or deny the traffic that matches the rule. Accepted values: `allow` | `deny` 180 RuleAction *string `pulumi:"ruleAction"` 181 // The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number. 182 RuleNumber *int `pulumi:"ruleNumber"` 183 // The to port to match. 184 ToPort *int `pulumi:"toPort"` 185 } 186 187 type NetworkAclRuleState struct { 188 // The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24 ). 189 CidrBlock pulumi.StringPtrInput 190 // Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet). Default `false`. 191 Egress pulumi.BoolPtrInput 192 // The from port to match. 193 FromPort pulumi.IntPtrInput 194 // ICMP protocol: The ICMP code. Required if specifying ICMP for the protocolE.g., -1 195 // 196 // > **NOTE:** If the value of `protocol` is `-1` or `all`, the `fromPort` and `toPort` values will be ignored and the rule will apply to all ports. 197 // 198 // > **NOTE:** If the value of `icmpType` is `-1` (which results in a wildcard ICMP type), the `icmpCode` must also be set to `-1` (wildcard ICMP code). 199 // 200 // > Note: For more information on ICMP types and codes, see here: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml 201 IcmpCode pulumi.IntPtrInput 202 // ICMP protocol: The ICMP type. Required if specifying ICMP for the protocolE.g., -1 203 IcmpType pulumi.IntPtrInput 204 // The IPv6 CIDR block to allow or deny. 205 Ipv6CidrBlock pulumi.StringPtrInput 206 // The ID of the network ACL. 207 NetworkAclId pulumi.StringPtrInput 208 // The protocol. A value of -1 means all protocols. 209 Protocol pulumi.StringPtrInput 210 // Indicates whether to allow or deny the traffic that matches the rule. Accepted values: `allow` | `deny` 211 RuleAction pulumi.StringPtrInput 212 // The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number. 213 RuleNumber pulumi.IntPtrInput 214 // The to port to match. 215 ToPort pulumi.IntPtrInput 216 } 217 218 func (NetworkAclRuleState) ElementType() reflect.Type { 219 return reflect.TypeOf((*networkAclRuleState)(nil)).Elem() 220 } 221 222 type networkAclRuleArgs struct { 223 // The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24 ). 224 CidrBlock *string `pulumi:"cidrBlock"` 225 // Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet). Default `false`. 226 Egress *bool `pulumi:"egress"` 227 // The from port to match. 228 FromPort *int `pulumi:"fromPort"` 229 // ICMP protocol: The ICMP code. Required if specifying ICMP for the protocolE.g., -1 230 // 231 // > **NOTE:** If the value of `protocol` is `-1` or `all`, the `fromPort` and `toPort` values will be ignored and the rule will apply to all ports. 232 // 233 // > **NOTE:** If the value of `icmpType` is `-1` (which results in a wildcard ICMP type), the `icmpCode` must also be set to `-1` (wildcard ICMP code). 234 // 235 // > Note: For more information on ICMP types and codes, see here: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml 236 IcmpCode *int `pulumi:"icmpCode"` 237 // ICMP protocol: The ICMP type. Required if specifying ICMP for the protocolE.g., -1 238 IcmpType *int `pulumi:"icmpType"` 239 // The IPv6 CIDR block to allow or deny. 240 Ipv6CidrBlock *string `pulumi:"ipv6CidrBlock"` 241 // The ID of the network ACL. 242 NetworkAclId string `pulumi:"networkAclId"` 243 // The protocol. A value of -1 means all protocols. 244 Protocol string `pulumi:"protocol"` 245 // Indicates whether to allow or deny the traffic that matches the rule. Accepted values: `allow` | `deny` 246 RuleAction string `pulumi:"ruleAction"` 247 // The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number. 248 RuleNumber int `pulumi:"ruleNumber"` 249 // The to port to match. 250 ToPort *int `pulumi:"toPort"` 251 } 252 253 // The set of arguments for constructing a NetworkAclRule resource. 254 type NetworkAclRuleArgs struct { 255 // The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24 ). 256 CidrBlock pulumi.StringPtrInput 257 // Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet). Default `false`. 258 Egress pulumi.BoolPtrInput 259 // The from port to match. 260 FromPort pulumi.IntPtrInput 261 // ICMP protocol: The ICMP code. Required if specifying ICMP for the protocolE.g., -1 262 // 263 // > **NOTE:** If the value of `protocol` is `-1` or `all`, the `fromPort` and `toPort` values will be ignored and the rule will apply to all ports. 264 // 265 // > **NOTE:** If the value of `icmpType` is `-1` (which results in a wildcard ICMP type), the `icmpCode` must also be set to `-1` (wildcard ICMP code). 266 // 267 // > Note: For more information on ICMP types and codes, see here: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml 268 IcmpCode pulumi.IntPtrInput 269 // ICMP protocol: The ICMP type. Required if specifying ICMP for the protocolE.g., -1 270 IcmpType pulumi.IntPtrInput 271 // The IPv6 CIDR block to allow or deny. 272 Ipv6CidrBlock pulumi.StringPtrInput 273 // The ID of the network ACL. 274 NetworkAclId pulumi.StringInput 275 // The protocol. A value of -1 means all protocols. 276 Protocol pulumi.StringInput 277 // Indicates whether to allow or deny the traffic that matches the rule. Accepted values: `allow` | `deny` 278 RuleAction pulumi.StringInput 279 // The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number. 280 RuleNumber pulumi.IntInput 281 // The to port to match. 282 ToPort pulumi.IntPtrInput 283 } 284 285 func (NetworkAclRuleArgs) ElementType() reflect.Type { 286 return reflect.TypeOf((*networkAclRuleArgs)(nil)).Elem() 287 } 288 289 type NetworkAclRuleInput interface { 290 pulumi.Input 291 292 ToNetworkAclRuleOutput() NetworkAclRuleOutput 293 ToNetworkAclRuleOutputWithContext(ctx context.Context) NetworkAclRuleOutput 294 } 295 296 func (*NetworkAclRule) ElementType() reflect.Type { 297 return reflect.TypeOf((**NetworkAclRule)(nil)).Elem() 298 } 299 300 func (i *NetworkAclRule) ToNetworkAclRuleOutput() NetworkAclRuleOutput { 301 return i.ToNetworkAclRuleOutputWithContext(context.Background()) 302 } 303 304 func (i *NetworkAclRule) ToNetworkAclRuleOutputWithContext(ctx context.Context) NetworkAclRuleOutput { 305 return pulumi.ToOutputWithContext(ctx, i).(NetworkAclRuleOutput) 306 } 307 308 // NetworkAclRuleArrayInput is an input type that accepts NetworkAclRuleArray and NetworkAclRuleArrayOutput values. 309 // You can construct a concrete instance of `NetworkAclRuleArrayInput` via: 310 // 311 // NetworkAclRuleArray{ NetworkAclRuleArgs{...} } 312 type NetworkAclRuleArrayInput interface { 313 pulumi.Input 314 315 ToNetworkAclRuleArrayOutput() NetworkAclRuleArrayOutput 316 ToNetworkAclRuleArrayOutputWithContext(context.Context) NetworkAclRuleArrayOutput 317 } 318 319 type NetworkAclRuleArray []NetworkAclRuleInput 320 321 func (NetworkAclRuleArray) ElementType() reflect.Type { 322 return reflect.TypeOf((*[]*NetworkAclRule)(nil)).Elem() 323 } 324 325 func (i NetworkAclRuleArray) ToNetworkAclRuleArrayOutput() NetworkAclRuleArrayOutput { 326 return i.ToNetworkAclRuleArrayOutputWithContext(context.Background()) 327 } 328 329 func (i NetworkAclRuleArray) ToNetworkAclRuleArrayOutputWithContext(ctx context.Context) NetworkAclRuleArrayOutput { 330 return pulumi.ToOutputWithContext(ctx, i).(NetworkAclRuleArrayOutput) 331 } 332 333 // NetworkAclRuleMapInput is an input type that accepts NetworkAclRuleMap and NetworkAclRuleMapOutput values. 334 // You can construct a concrete instance of `NetworkAclRuleMapInput` via: 335 // 336 // NetworkAclRuleMap{ "key": NetworkAclRuleArgs{...} } 337 type NetworkAclRuleMapInput interface { 338 pulumi.Input 339 340 ToNetworkAclRuleMapOutput() NetworkAclRuleMapOutput 341 ToNetworkAclRuleMapOutputWithContext(context.Context) NetworkAclRuleMapOutput 342 } 343 344 type NetworkAclRuleMap map[string]NetworkAclRuleInput 345 346 func (NetworkAclRuleMap) ElementType() reflect.Type { 347 return reflect.TypeOf((*map[string]*NetworkAclRule)(nil)).Elem() 348 } 349 350 func (i NetworkAclRuleMap) ToNetworkAclRuleMapOutput() NetworkAclRuleMapOutput { 351 return i.ToNetworkAclRuleMapOutputWithContext(context.Background()) 352 } 353 354 func (i NetworkAclRuleMap) ToNetworkAclRuleMapOutputWithContext(ctx context.Context) NetworkAclRuleMapOutput { 355 return pulumi.ToOutputWithContext(ctx, i).(NetworkAclRuleMapOutput) 356 } 357 358 type NetworkAclRuleOutput struct{ *pulumi.OutputState } 359 360 func (NetworkAclRuleOutput) ElementType() reflect.Type { 361 return reflect.TypeOf((**NetworkAclRule)(nil)).Elem() 362 } 363 364 func (o NetworkAclRuleOutput) ToNetworkAclRuleOutput() NetworkAclRuleOutput { 365 return o 366 } 367 368 func (o NetworkAclRuleOutput) ToNetworkAclRuleOutputWithContext(ctx context.Context) NetworkAclRuleOutput { 369 return o 370 } 371 372 // The network range to allow or deny, in CIDR notation (for example 172.16.0.0/24 ). 373 func (o NetworkAclRuleOutput) CidrBlock() pulumi.StringPtrOutput { 374 return o.ApplyT(func(v *NetworkAclRule) pulumi.StringPtrOutput { return v.CidrBlock }).(pulumi.StringPtrOutput) 375 } 376 377 // Indicates whether this is an egress rule (rule is applied to traffic leaving the subnet). Default `false`. 378 func (o NetworkAclRuleOutput) Egress() pulumi.BoolPtrOutput { 379 return o.ApplyT(func(v *NetworkAclRule) pulumi.BoolPtrOutput { return v.Egress }).(pulumi.BoolPtrOutput) 380 } 381 382 // The from port to match. 383 func (o NetworkAclRuleOutput) FromPort() pulumi.IntPtrOutput { 384 return o.ApplyT(func(v *NetworkAclRule) pulumi.IntPtrOutput { return v.FromPort }).(pulumi.IntPtrOutput) 385 } 386 387 // ICMP protocol: The ICMP code. Required if specifying ICMP for the protocolE.g., -1 388 // 389 // > **NOTE:** If the value of `protocol` is `-1` or `all`, the `fromPort` and `toPort` values will be ignored and the rule will apply to all ports. 390 // 391 // > **NOTE:** If the value of `icmpType` is `-1` (which results in a wildcard ICMP type), the `icmpCode` must also be set to `-1` (wildcard ICMP code). 392 // 393 // > Note: For more information on ICMP types and codes, see here: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml 394 func (o NetworkAclRuleOutput) IcmpCode() pulumi.IntPtrOutput { 395 return o.ApplyT(func(v *NetworkAclRule) pulumi.IntPtrOutput { return v.IcmpCode }).(pulumi.IntPtrOutput) 396 } 397 398 // ICMP protocol: The ICMP type. Required if specifying ICMP for the protocolE.g., -1 399 func (o NetworkAclRuleOutput) IcmpType() pulumi.IntPtrOutput { 400 return o.ApplyT(func(v *NetworkAclRule) pulumi.IntPtrOutput { return v.IcmpType }).(pulumi.IntPtrOutput) 401 } 402 403 // The IPv6 CIDR block to allow or deny. 404 func (o NetworkAclRuleOutput) Ipv6CidrBlock() pulumi.StringPtrOutput { 405 return o.ApplyT(func(v *NetworkAclRule) pulumi.StringPtrOutput { return v.Ipv6CidrBlock }).(pulumi.StringPtrOutput) 406 } 407 408 // The ID of the network ACL. 409 func (o NetworkAclRuleOutput) NetworkAclId() pulumi.StringOutput { 410 return o.ApplyT(func(v *NetworkAclRule) pulumi.StringOutput { return v.NetworkAclId }).(pulumi.StringOutput) 411 } 412 413 // The protocol. A value of -1 means all protocols. 414 func (o NetworkAclRuleOutput) Protocol() pulumi.StringOutput { 415 return o.ApplyT(func(v *NetworkAclRule) pulumi.StringOutput { return v.Protocol }).(pulumi.StringOutput) 416 } 417 418 // Indicates whether to allow or deny the traffic that matches the rule. Accepted values: `allow` | `deny` 419 func (o NetworkAclRuleOutput) RuleAction() pulumi.StringOutput { 420 return o.ApplyT(func(v *NetworkAclRule) pulumi.StringOutput { return v.RuleAction }).(pulumi.StringOutput) 421 } 422 423 // The rule number for the entry (for example, 100). ACL entries are processed in ascending order by rule number. 424 func (o NetworkAclRuleOutput) RuleNumber() pulumi.IntOutput { 425 return o.ApplyT(func(v *NetworkAclRule) pulumi.IntOutput { return v.RuleNumber }).(pulumi.IntOutput) 426 } 427 428 // The to port to match. 429 func (o NetworkAclRuleOutput) ToPort() pulumi.IntPtrOutput { 430 return o.ApplyT(func(v *NetworkAclRule) pulumi.IntPtrOutput { return v.ToPort }).(pulumi.IntPtrOutput) 431 } 432 433 type NetworkAclRuleArrayOutput struct{ *pulumi.OutputState } 434 435 func (NetworkAclRuleArrayOutput) ElementType() reflect.Type { 436 return reflect.TypeOf((*[]*NetworkAclRule)(nil)).Elem() 437 } 438 439 func (o NetworkAclRuleArrayOutput) ToNetworkAclRuleArrayOutput() NetworkAclRuleArrayOutput { 440 return o 441 } 442 443 func (o NetworkAclRuleArrayOutput) ToNetworkAclRuleArrayOutputWithContext(ctx context.Context) NetworkAclRuleArrayOutput { 444 return o 445 } 446 447 func (o NetworkAclRuleArrayOutput) Index(i pulumi.IntInput) NetworkAclRuleOutput { 448 return pulumi.All(o, i).ApplyT(func(vs []interface{}) *NetworkAclRule { 449 return vs[0].([]*NetworkAclRule)[vs[1].(int)] 450 }).(NetworkAclRuleOutput) 451 } 452 453 type NetworkAclRuleMapOutput struct{ *pulumi.OutputState } 454 455 func (NetworkAclRuleMapOutput) ElementType() reflect.Type { 456 return reflect.TypeOf((*map[string]*NetworkAclRule)(nil)).Elem() 457 } 458 459 func (o NetworkAclRuleMapOutput) ToNetworkAclRuleMapOutput() NetworkAclRuleMapOutput { 460 return o 461 } 462 463 func (o NetworkAclRuleMapOutput) ToNetworkAclRuleMapOutputWithContext(ctx context.Context) NetworkAclRuleMapOutput { 464 return o 465 } 466 467 func (o NetworkAclRuleMapOutput) MapIndex(k pulumi.StringInput) NetworkAclRuleOutput { 468 return pulumi.All(o, k).ApplyT(func(vs []interface{}) *NetworkAclRule { 469 return vs[0].(map[string]*NetworkAclRule)[vs[1].(string)] 470 }).(NetworkAclRuleOutput) 471 } 472 473 func init() { 474 pulumi.RegisterInputType(reflect.TypeOf((*NetworkAclRuleInput)(nil)).Elem(), &NetworkAclRule{}) 475 pulumi.RegisterInputType(reflect.TypeOf((*NetworkAclRuleArrayInput)(nil)).Elem(), NetworkAclRuleArray{}) 476 pulumi.RegisterInputType(reflect.TypeOf((*NetworkAclRuleMapInput)(nil)).Elem(), NetworkAclRuleMap{}) 477 pulumi.RegisterOutputType(NetworkAclRuleOutput{}) 478 pulumi.RegisterOutputType(NetworkAclRuleArrayOutput{}) 479 pulumi.RegisterOutputType(NetworkAclRuleMapOutput{}) 480 }