All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.alicloud.ecs.inputs.EipAssociationState Maven / Gradle / Ivy
Go to download
A Pulumi package for creating and managing AliCloud resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.alicloud.ecs.inputs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Boolean;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
public final class EipAssociationState extends com.pulumi.resources.ResourceArgs {
public static final EipAssociationState Empty = new EipAssociationState();
/**
* The ID of the EIP instance.
*
*/
@Import(name="allocationId")
private @Nullable Output allocationId;
/**
* @return The ID of the EIP instance.
*
*/
public Optional> allocationId() {
return Optional.ofNullable(this.allocationId);
}
/**
* Specifies whether to disassociate the EIP from a NAT gateway if a DNAT or SNAT entry is added to the NAT gateway. Valid values:
*
*/
@Import(name="force")
private @Nullable Output force;
/**
* @return Specifies whether to disassociate the EIP from a NAT gateway if a DNAT or SNAT entry is added to the NAT gateway. Valid values:
*
*/
public Optional> force() {
return Optional.ofNullable(this.force);
}
/**
* The ID of the instance with which you want to associate the EIP. You can enter the ID of a NAT gateway, CLB instance, ECS instance, secondary ENI, HAVIP, or IP address.
*
*/
@Import(name="instanceId")
private @Nullable Output instanceId;
/**
* @return The ID of the instance with which you want to associate the EIP. You can enter the ID of a NAT gateway, CLB instance, ECS instance, secondary ENI, HAVIP, or IP address.
*
*/
public Optional> instanceId() {
return Optional.ofNullable(this.instanceId);
}
/**
* The type of the instance with which you want to associate the EIP. Valid values:
* - `Nat`: NAT gateway
* - `SlbInstance`: CLB instance
* - `EcsInstance` (default): ECS instance
* - `NetworkInterface`: secondary ENI
* - `HaVip`: HAVIP
* - `IpAddress`: IP address
*
* > **NOTE:** The default value is `EcsInstance`. If the instance with which you want to associate the EIP is not an ECS instance, this parameter is required.
*
*/
@Import(name="instanceType")
private @Nullable Output instanceType;
/**
* @return The type of the instance with which you want to associate the EIP. Valid values:
* - `Nat`: NAT gateway
* - `SlbInstance`: CLB instance
* - `EcsInstance` (default): ECS instance
* - `NetworkInterface`: secondary ENI
* - `HaVip`: HAVIP
* - `IpAddress`: IP address
*
* > **NOTE:** The default value is `EcsInstance`. If the instance with which you want to associate the EIP is not an ECS instance, this parameter is required.
*
*/
public Optional> instanceType() {
return Optional.ofNullable(this.instanceType);
}
/**
* The association mode. Valid values:
* - `NAT` (default): NAT mode
* - `MULTI_BINDED`: multi-EIP-to-ENI mode
* - `BINDED`: cut-network interface controller mode
*
* > **NOTE:** This parameter is required only when `instance_type` is set to `NetworkInterface`.
*
*/
@Import(name="mode")
private @Nullable Output mode;
/**
* @return The association mode. Valid values:
* - `NAT` (default): NAT mode
* - `MULTI_BINDED`: multi-EIP-to-ENI mode
* - `BINDED`: cut-network interface controller mode
*
* > **NOTE:** This parameter is required only when `instance_type` is set to `NetworkInterface`.
*
*/
public Optional> mode() {
return Optional.ofNullable(this.mode);
}
/**
* The IP address in the CIDR block of the vSwitch.
*
* If you leave this parameter empty, the system allocates a private IP address based on the VPC ID and vSwitch ID.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
*/
@Import(name="privateIpAddress")
private @Nullable Output privateIpAddress;
/**
* @return The IP address in the CIDR block of the vSwitch.
*
* If you leave this parameter empty, the system allocates a private IP address based on the VPC ID and vSwitch ID.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
*/
public Optional> privateIpAddress() {
return Optional.ofNullable(this.privateIpAddress);
}
/**
* The ID of the VPC in which an IPv4 gateway is created. The VPC and the EIP must be in the same region.
*
* When you associate an EIP with an IP address, the system can enable the IP address to access the Internet based on VPC route configurations.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
*/
@Import(name="vpcId")
private @Nullable Output vpcId;
/**
* @return The ID of the VPC in which an IPv4 gateway is created. The VPC and the EIP must be in the same region.
*
* When you associate an EIP with an IP address, the system can enable the IP address to access the Internet based on VPC route configurations.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
*/
public Optional> vpcId() {
return Optional.ofNullable(this.vpcId);
}
private EipAssociationState() {}
private EipAssociationState(EipAssociationState $) {
this.allocationId = $.allocationId;
this.force = $.force;
this.instanceId = $.instanceId;
this.instanceType = $.instanceType;
this.mode = $.mode;
this.privateIpAddress = $.privateIpAddress;
this.vpcId = $.vpcId;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(EipAssociationState defaults) {
return new Builder(defaults);
}
public static final class Builder {
private EipAssociationState $;
public Builder() {
$ = new EipAssociationState();
}
public Builder(EipAssociationState defaults) {
$ = new EipAssociationState(Objects.requireNonNull(defaults));
}
/**
* @param allocationId The ID of the EIP instance.
*
* @return builder
*
*/
public Builder allocationId(@Nullable Output allocationId) {
$.allocationId = allocationId;
return this;
}
/**
* @param allocationId The ID of the EIP instance.
*
* @return builder
*
*/
public Builder allocationId(String allocationId) {
return allocationId(Output.of(allocationId));
}
/**
* @param force Specifies whether to disassociate the EIP from a NAT gateway if a DNAT or SNAT entry is added to the NAT gateway. Valid values:
*
* @return builder
*
*/
public Builder force(@Nullable Output force) {
$.force = force;
return this;
}
/**
* @param force Specifies whether to disassociate the EIP from a NAT gateway if a DNAT or SNAT entry is added to the NAT gateway. Valid values:
*
* @return builder
*
*/
public Builder force(Boolean force) {
return force(Output.of(force));
}
/**
* @param instanceId The ID of the instance with which you want to associate the EIP. You can enter the ID of a NAT gateway, CLB instance, ECS instance, secondary ENI, HAVIP, or IP address.
*
* @return builder
*
*/
public Builder instanceId(@Nullable Output instanceId) {
$.instanceId = instanceId;
return this;
}
/**
* @param instanceId The ID of the instance with which you want to associate the EIP. You can enter the ID of a NAT gateway, CLB instance, ECS instance, secondary ENI, HAVIP, or IP address.
*
* @return builder
*
*/
public Builder instanceId(String instanceId) {
return instanceId(Output.of(instanceId));
}
/**
* @param instanceType The type of the instance with which you want to associate the EIP. Valid values:
* - `Nat`: NAT gateway
* - `SlbInstance`: CLB instance
* - `EcsInstance` (default): ECS instance
* - `NetworkInterface`: secondary ENI
* - `HaVip`: HAVIP
* - `IpAddress`: IP address
*
* > **NOTE:** The default value is `EcsInstance`. If the instance with which you want to associate the EIP is not an ECS instance, this parameter is required.
*
* @return builder
*
*/
public Builder instanceType(@Nullable Output instanceType) {
$.instanceType = instanceType;
return this;
}
/**
* @param instanceType The type of the instance with which you want to associate the EIP. Valid values:
* - `Nat`: NAT gateway
* - `SlbInstance`: CLB instance
* - `EcsInstance` (default): ECS instance
* - `NetworkInterface`: secondary ENI
* - `HaVip`: HAVIP
* - `IpAddress`: IP address
*
* > **NOTE:** The default value is `EcsInstance`. If the instance with which you want to associate the EIP is not an ECS instance, this parameter is required.
*
* @return builder
*
*/
public Builder instanceType(String instanceType) {
return instanceType(Output.of(instanceType));
}
/**
* @param mode The association mode. Valid values:
* - `NAT` (default): NAT mode
* - `MULTI_BINDED`: multi-EIP-to-ENI mode
* - `BINDED`: cut-network interface controller mode
*
* > **NOTE:** This parameter is required only when `instance_type` is set to `NetworkInterface`.
*
* @return builder
*
*/
public Builder mode(@Nullable Output mode) {
$.mode = mode;
return this;
}
/**
* @param mode The association mode. Valid values:
* - `NAT` (default): NAT mode
* - `MULTI_BINDED`: multi-EIP-to-ENI mode
* - `BINDED`: cut-network interface controller mode
*
* > **NOTE:** This parameter is required only when `instance_type` is set to `NetworkInterface`.
*
* @return builder
*
*/
public Builder mode(String mode) {
return mode(Output.of(mode));
}
/**
* @param privateIpAddress The IP address in the CIDR block of the vSwitch.
*
* If you leave this parameter empty, the system allocates a private IP address based on the VPC ID and vSwitch ID.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
* @return builder
*
*/
public Builder privateIpAddress(@Nullable Output privateIpAddress) {
$.privateIpAddress = privateIpAddress;
return this;
}
/**
* @param privateIpAddress The IP address in the CIDR block of the vSwitch.
*
* If you leave this parameter empty, the system allocates a private IP address based on the VPC ID and vSwitch ID.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
* @return builder
*
*/
public Builder privateIpAddress(String privateIpAddress) {
return privateIpAddress(Output.of(privateIpAddress));
}
/**
* @param vpcId The ID of the VPC in which an IPv4 gateway is created. The VPC and the EIP must be in the same region.
*
* When you associate an EIP with an IP address, the system can enable the IP address to access the Internet based on VPC route configurations.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
* @return builder
*
*/
public Builder vpcId(@Nullable Output vpcId) {
$.vpcId = vpcId;
return this;
}
/**
* @param vpcId The ID of the VPC in which an IPv4 gateway is created. The VPC and the EIP must be in the same region.
*
* When you associate an EIP with an IP address, the system can enable the IP address to access the Internet based on VPC route configurations.
*
* > **NOTE:** This parameter is required if `instance_type` is set to `IpAddress`, which indicates that the EIP is to be associated with an IP address.
*
* @return builder
*
*/
public Builder vpcId(String vpcId) {
return vpcId(Output.of(vpcId));
}
public EipAssociationState build() {
return $;
}
}
}