Skip to content

Latest commit

 

History

History
89 lines (48 loc) · 2.35 KB

AllocateCidrBlockArguments.md

File metadata and controls

89 lines (48 loc) · 2.35 KB

@tinystacks/iac-utils / Exports / AllocateCidrBlockArguments

Interface: AllocateCidrBlockArguments

Arguments for generating a CIDR block.

Table of contents

Properties

Properties

exclusions

Optional exclusions: string[]

CIDR blocks that should be excluded from the results.

Remarks

If the CIDR block generated matches any of the values provided here, the method will re-generate and re-check against this list until it runs out of options. Note that for a given prefix and network mask, only 256 unique CIDR blocks can be generated.

Defined in

cidr/allocate-cidr-block.ts:69


networkMask

Optional networkMask: number

An integer between 8 and 32

Remarks

This value will determine how many IP addresses are available within your CIDR block.

Default Value

16

Defined in

cidr/allocate-cidr-block.ts:61


prefix

Optional prefix: string

An IPv4 prefix for the CIDR block to use as a base.

Remarks

Depending on the network mask, one of the octets will likely be replaced. This should typically be from the Private Address Space defined in RFC 1918 http://www.faqs.org/rfcs/rfc1918.html

Default Value

10.0.0.0

Defined in

cidr/allocate-cidr-block.ts:52


seed

seed: string

A string to be used as a seed for the CIDR generation.

Remarks

If all other inputs are the same, two different seeds have a 1 in 256 chance of being duplicates. If you are generating multiple CIDR blocks and need them to be unique, generate them in sequence providing previously generated blocks in the exclusions argument.

Defined in

cidr/allocate-cidr-block.ts:42