vpc_attrs: VPC Attributes

Description Usage Arguments Value References See Also Examples

Description

Get and set VPC attributes

Usage

1
2
3
4
set_vpc_attr(vpc, dns, hostnames, ...)

get_vpc_attr(vpc, attribute = c("enableDnsSupport", "enableDnsHostnames"),
  ...)

Arguments

vpc

A character string specifying a VPC Allocation ID or an object of class “ec2_ip”.

dns

A logical indicating whether DNS resolution is supported for the VPC. A request can only specify only dns xor hostnames.

hostnames

A logical indicating whether instances launched in the VPC get DNS hostnames. A request can only specify only dns xor hostnames.

...

Additional arguments passed to [ec2HTTP()].

attribute

A character string specifying one of “enableDnsSupport” or “enableDnsHostnames”.

Value

For get_vpc_attr, a logical indicating the value of the attribute. For set_vpc_attr, a logical indicating whether the operation succeeded.

References

http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVpcAttribute.html http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_ModifyVpcAttribute.html

See Also

describe_vpcs(), create_vpc()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
# create VPC
v <- create_vpc("10.0.0.0/16")
get_vpc_attr(v, "enableDnsSupport")
set_vpc_attr(v, dns = FALSE)

# cleanup
delete_vpc(v)

## End(Not run)

cloudyr/aws.ec2 documentation built on Jan. 14, 2020, 4:55 a.m.