Resource: aws_network_acl_association

Provides an network ACL association resource which allows you to associate your network ACL with any subnet(s).

Example Usage

resource "aws_network_acl_association" "main" {
  network_acl_id = aws_network_acl.main.id
  subnet_id      = aws_subnet.main.id
}

Argument Reference

This resource supports the following arguments:

Attribute Reference

This resource exports the following attributes in addition to the arguments above:

Import

In Terraform v1.5.0 and later, use an import block to import Network ACL associations using the id. For example:

import {
  to = aws_network_acl_association.main
  id = "aclassoc-02baf37f20966b3e6"
}

Using terraform import, import Network ACL associations using the id. For example:

% terraform import aws_network_acl_association.main aclassoc-02baf37f20966b3e6