paws.compute (version 0.1.0)

ec2_associate_dhcp_options: Associates a set of DHCP options (that you've previously created) with the specified VPC, or associates no DHCP options with the VPC

Description

Associates a set of DHCP options (that you've previously created) with the specified VPC, or associates no DHCP options with the VPC.

Usage

ec2_associate_dhcp_options(DhcpOptionsId, VpcId, DryRun)

Arguments

DhcpOptionsId

[required] The ID of the DHCP options set, or default to associate no DHCP options with the VPC.

VpcId

[required] The ID of the VPC.

DryRun

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Request syntax

svc$associate_dhcp_options(
  DhcpOptionsId = "string",
  VpcId = "string",
  DryRun = TRUE|FALSE
)

Details

After you associate the options with the VPC, any existing instances and all new instances that you launch in that VPC use the options. You don't need to restart or relaunch the instances. They automatically pick up the changes within a few hours, depending on how frequently the instance renews its DHCP lease. You can explicitly renew the lease using the operating system on the instance.

For more information, see DHCP Options Sets in the Amazon Virtual Private Cloud User Guide.

Examples

Run this code
# NOT RUN {
# This example associates the specified DHCP options set with the
# specified VPC.
# }
# NOT RUN {
svc$associate_dhcp_options(
  DhcpOptionsId = "dopt-d9070ebb",
  VpcId = "vpc-a01106c2"
)
# }
# NOT RUN {
# This example associates the default DHCP options set with the specified
# VPC.
# }
# NOT RUN {
svc$associate_dhcp_options(
  DhcpOptionsId = "default",
  VpcId = "vpc-a01106c2"
)
# }
# NOT RUN {
# }

Run the code above in your browser using DataCamp Workspace