ManagedPrefixListEntryArgs

data class ManagedPrefixListEntryArgs(val cidr: Output<String>? = null, val description: Output<String>? = null, val prefixListId: Output<String>? = null) : ConvertibleToJava<ManagedPrefixListEntryArgs>

Provides a managed prefix list entry resource.

NOTE on Managed Prefix Lists and Managed Prefix List Entries: The provider currently provides both a standalone Managed Prefix List Entry resource (a single entry), and a Managed Prefix List resource with entries defined in-line. At this time you cannot use a Managed Prefix List with in-line rules in conjunction with any Managed Prefix List Entry resources. Doing so will cause a conflict of entries and will overwrite entries. NOTE on Managed Prefix Lists with many entries: To improved execution times on larger updates, if you plan to create a prefix list with more than 100 entries, it is recommended that you use the inline entry block as part of the Managed Prefix List resource resource instead.

Example Usage

Basic usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.ec2.ManagedPrefixList;
import com.pulumi.aws.ec2.ManagedPrefixListArgs;
import com.pulumi.aws.ec2.ManagedPrefixListEntry;
import com.pulumi.aws.ec2.ManagedPrefixListEntryArgs;
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 ManagedPrefixList("example", ManagedPrefixListArgs.builder()
.addressFamily("IPv4")
.maxEntries(5)
.tags(Map.of("Env", "live"))
.build());
var entry1 = new ManagedPrefixListEntry("entry1", ManagedPrefixListEntryArgs.builder()
.cidr(aws_vpc.example().cidr_block())
.description("Primary")
.prefixListId(example.id())
.build());
}
}

Import

Prefix List Entries can be imported using the prefix_list_id and cidr separated by a ,, e.g.,

$ pulumi import aws:ec2/managedPrefixListEntry:ManagedPrefixListEntry default pl-0570a1d2d725c16be,10.0.3.0/24

Constructors

Link copied to clipboard
constructor(cidr: Output<String>? = null, description: Output<String>? = null, prefixListId: Output<String>? = null)

Properties

Link copied to clipboard
val cidr: Output<String>? = null

CIDR block of this entry.

Link copied to clipboard
val description: Output<String>? = null

Description of this entry. Due to API limitations, updating only the description of an entry requires recreating the entry.

Link copied to clipboard
val prefixListId: Output<String>? = null

CIDR block of this entry.

Functions

Link copied to clipboard
open override fun toJava(): ManagedPrefixListEntryArgs