1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. ecs
  5. Eip
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.ecs.Eip

Explore with Pulumi AI

Deprecated: This resource has been deprecated in favour of the EipAddress resource

Provides an elastic IP resource.

DEPRECATED: This resource has been deprecated from version 1.126.0. Please use new resource alicloud_eip_address.

NOTE: The resource only supports to create PostPaid PayByTraffic or PrePaid PayByBandwidth elastic IP for international account. Otherwise, you will happened error COMMODITY.INVALID_COMPONENT. Your account is international if you can use it to login in International Web Console.

NOTE: From version 1.10.1, this resource supports creating “PrePaid” EIP. In addition, it supports setting EIP name and description.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

// Create a new EIP.
const example = new alicloud.ecs.Eip("example", {
    bandwidth: "10",
    internetChargeType: "PayByBandwidth",
});
Copy
import pulumi
import pulumi_alicloud as alicloud

# Create a new EIP.
example = alicloud.ecs.Eip("example",
    bandwidth="10",
    internet_charge_type="PayByBandwidth")
Copy
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		// Create a new EIP.
		_, err := ecs.NewEip(ctx, "example", &ecs.EipArgs{
			Bandwidth:          pulumi.String("10"),
			InternetChargeType: pulumi.String("PayByBandwidth"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;

return await Deployment.RunAsync(() => 
{
    // Create a new EIP.
    var example = new AliCloud.Ecs.Eip("example", new()
    {
        Bandwidth = "10",
        InternetChargeType = "PayByBandwidth",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.ecs.Eip;
import com.pulumi.alicloud.ecs.EipArgs;
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) {
        // Create a new EIP.
        var example = new Eip("example", EipArgs.builder()
            .bandwidth("10")
            .internetChargeType("PayByBandwidth")
            .build());

    }
}
Copy
resources:
  # Create a new EIP.
  example:
    type: alicloud:ecs:Eip
    properties:
      bandwidth: '10'
      internetChargeType: PayByBandwidth
Copy

Module Support

You can use the existing eip module to create several EIP instances and associate them with other resources one-click, like ECS instances, SLB, Nat Gateway and so on.

Create Eip Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new Eip(name: string, args?: EipArgs, opts?: CustomResourceOptions);
@overload
def Eip(resource_name: str,
        args: Optional[EipArgs] = None,
        opts: Optional[ResourceOptions] = None)

@overload
def Eip(resource_name: str,
        opts: Optional[ResourceOptions] = None,
        activity_id: Optional[str] = None,
        address_name: Optional[str] = None,
        allocation_id: Optional[str] = None,
        auto_pay: Optional[bool] = None,
        bandwidth: Optional[str] = None,
        deletion_protection: Optional[bool] = None,
        description: Optional[str] = None,
        high_definition_monitor_log_status: Optional[str] = None,
        instance_charge_type: Optional[str] = None,
        internet_charge_type: Optional[str] = None,
        ip_address: Optional[str] = None,
        isp: Optional[str] = None,
        log_project: Optional[str] = None,
        log_store: Optional[str] = None,
        mode: Optional[str] = None,
        name: Optional[str] = None,
        netmode: Optional[str] = None,
        payment_type: Optional[str] = None,
        period: Optional[int] = None,
        pricing_cycle: Optional[str] = None,
        public_ip_address_pool_id: Optional[str] = None,
        resource_group_id: Optional[str] = None,
        security_protection_types: Optional[Sequence[str]] = None,
        tags: Optional[Mapping[str, str]] = None,
        zone: Optional[str] = None)
func NewEip(ctx *Context, name string, args *EipArgs, opts ...ResourceOption) (*Eip, error)
public Eip(string name, EipArgs? args = null, CustomResourceOptions? opts = null)
public Eip(String name, EipArgs args)
public Eip(String name, EipArgs args, CustomResourceOptions options)
type: alicloud:ecs:Eip
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args EipArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args EipArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args EipArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args EipArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. EipArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Eip Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The Eip resource accepts the following input properties:

ActivityId string
AddressName string
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
AllocationId Changes to this property will trigger replacement. string
AutoPay bool
Bandwidth string
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
DeletionProtection bool
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
Description string
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
HighDefinitionMonitorLogStatus Changes to this property will trigger replacement. string
InstanceChargeType Changes to this property will trigger replacement. string
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

InternetChargeType Changes to this property will trigger replacement. string
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
IpAddress Changes to this property will trigger replacement. string
The elastic ip address
Isp Changes to this property will trigger replacement. string
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
LogProject string
LogStore string
Mode string
Name string
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

Netmode Changes to this property will trigger replacement. string
PaymentType Changes to this property will trigger replacement. string
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
Period int
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
PricingCycle string
PublicIpAddressPoolId Changes to this property will trigger replacement. string
ResourceGroupId string
The Id of resource group which the eip belongs.
SecurityProtectionTypes Changes to this property will trigger replacement. List<string>
Tags Dictionary<string, string>
A mapping of tags to assign to the resource.
Zone Changes to this property will trigger replacement. string
ActivityId string
AddressName string
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
AllocationId Changes to this property will trigger replacement. string
AutoPay bool
Bandwidth string
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
DeletionProtection bool
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
Description string
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
HighDefinitionMonitorLogStatus Changes to this property will trigger replacement. string
InstanceChargeType Changes to this property will trigger replacement. string
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

InternetChargeType Changes to this property will trigger replacement. string
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
IpAddress Changes to this property will trigger replacement. string
The elastic ip address
Isp Changes to this property will trigger replacement. string
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
LogProject string
LogStore string
Mode string
Name string
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

Netmode Changes to this property will trigger replacement. string
PaymentType Changes to this property will trigger replacement. string
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
Period int
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
PricingCycle string
PublicIpAddressPoolId Changes to this property will trigger replacement. string
ResourceGroupId string
The Id of resource group which the eip belongs.
SecurityProtectionTypes Changes to this property will trigger replacement. []string
Tags map[string]string
A mapping of tags to assign to the resource.
Zone Changes to this property will trigger replacement. string
activityId String
addressName String
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocationId Changes to this property will trigger replacement. String
autoPay Boolean
bandwidth String
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
deletionProtection Boolean
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description String
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
highDefinitionMonitorLogStatus Changes to this property will trigger replacement. String
instanceChargeType Changes to this property will trigger replacement. String
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internetChargeType Changes to this property will trigger replacement. String
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ipAddress Changes to this property will trigger replacement. String
The elastic ip address
isp Changes to this property will trigger replacement. String
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
logProject String
logStore String
mode String
name String
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. String
paymentType Changes to this property will trigger replacement. String
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period Integer
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricingCycle String
publicIpAddressPoolId Changes to this property will trigger replacement. String
resourceGroupId String
The Id of resource group which the eip belongs.
securityProtectionTypes Changes to this property will trigger replacement. List<String>
tags Map<String,String>
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. String
activityId string
addressName string
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocationId Changes to this property will trigger replacement. string
autoPay boolean
bandwidth string
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
deletionProtection boolean
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description string
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
highDefinitionMonitorLogStatus Changes to this property will trigger replacement. string
instanceChargeType Changes to this property will trigger replacement. string
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internetChargeType Changes to this property will trigger replacement. string
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ipAddress Changes to this property will trigger replacement. string
The elastic ip address
isp Changes to this property will trigger replacement. string
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
logProject string
logStore string
mode string
name string
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. string
paymentType Changes to this property will trigger replacement. string
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period number
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricingCycle string
publicIpAddressPoolId Changes to this property will trigger replacement. string
resourceGroupId string
The Id of resource group which the eip belongs.
securityProtectionTypes Changes to this property will trigger replacement. string[]
tags {[key: string]: string}
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. string
activity_id str
address_name str
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocation_id Changes to this property will trigger replacement. str
auto_pay bool
bandwidth str
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
deletion_protection bool
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description str
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
high_definition_monitor_log_status Changes to this property will trigger replacement. str
instance_charge_type Changes to this property will trigger replacement. str
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internet_charge_type Changes to this property will trigger replacement. str
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ip_address Changes to this property will trigger replacement. str
The elastic ip address
isp Changes to this property will trigger replacement. str
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
log_project str
log_store str
mode str
name str
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. str
payment_type Changes to this property will trigger replacement. str
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period int
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricing_cycle str
public_ip_address_pool_id Changes to this property will trigger replacement. str
resource_group_id str
The Id of resource group which the eip belongs.
security_protection_types Changes to this property will trigger replacement. Sequence[str]
tags Mapping[str, str]
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. str
activityId String
addressName String
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocationId Changes to this property will trigger replacement. String
autoPay Boolean
bandwidth String
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
deletionProtection Boolean
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description String
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
highDefinitionMonitorLogStatus Changes to this property will trigger replacement. String
instanceChargeType Changes to this property will trigger replacement. String
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internetChargeType Changes to this property will trigger replacement. String
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ipAddress Changes to this property will trigger replacement. String
The elastic ip address
isp Changes to this property will trigger replacement. String
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
logProject String
logStore String
mode String
name String
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. String
paymentType Changes to this property will trigger replacement. String
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period Number
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricingCycle String
publicIpAddressPoolId Changes to this property will trigger replacement. String
resourceGroupId String
The Id of resource group which the eip belongs.
securityProtectionTypes Changes to this property will trigger replacement. List<String>
tags Map<String>
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. String

Outputs

All input properties are implicitly available as output properties. Additionally, the Eip resource produces the following output properties:

CreateTime string
Id string
The provider-assigned unique ID for this managed resource.
Status string
The EIP current status.
CreateTime string
Id string
The provider-assigned unique ID for this managed resource.
Status string
The EIP current status.
createTime String
id String
The provider-assigned unique ID for this managed resource.
status String
The EIP current status.
createTime string
id string
The provider-assigned unique ID for this managed resource.
status string
The EIP current status.
create_time str
id str
The provider-assigned unique ID for this managed resource.
status str
The EIP current status.
createTime String
id String
The provider-assigned unique ID for this managed resource.
status String
The EIP current status.

Look up Existing Eip Resource

Get an existing Eip resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: EipState, opts?: CustomResourceOptions): Eip
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        activity_id: Optional[str] = None,
        address_name: Optional[str] = None,
        allocation_id: Optional[str] = None,
        auto_pay: Optional[bool] = None,
        bandwidth: Optional[str] = None,
        create_time: Optional[str] = None,
        deletion_protection: Optional[bool] = None,
        description: Optional[str] = None,
        high_definition_monitor_log_status: Optional[str] = None,
        instance_charge_type: Optional[str] = None,
        internet_charge_type: Optional[str] = None,
        ip_address: Optional[str] = None,
        isp: Optional[str] = None,
        log_project: Optional[str] = None,
        log_store: Optional[str] = None,
        mode: Optional[str] = None,
        name: Optional[str] = None,
        netmode: Optional[str] = None,
        payment_type: Optional[str] = None,
        period: Optional[int] = None,
        pricing_cycle: Optional[str] = None,
        public_ip_address_pool_id: Optional[str] = None,
        resource_group_id: Optional[str] = None,
        security_protection_types: Optional[Sequence[str]] = None,
        status: Optional[str] = None,
        tags: Optional[Mapping[str, str]] = None,
        zone: Optional[str] = None) -> Eip
func GetEip(ctx *Context, name string, id IDInput, state *EipState, opts ...ResourceOption) (*Eip, error)
public static Eip Get(string name, Input<string> id, EipState? state, CustomResourceOptions? opts = null)
public static Eip get(String name, Output<String> id, EipState state, CustomResourceOptions options)
resources:  _:    type: alicloud:ecs:Eip    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
ActivityId string
AddressName string
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
AllocationId Changes to this property will trigger replacement. string
AutoPay bool
Bandwidth string
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
CreateTime string
DeletionProtection bool
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
Description string
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
HighDefinitionMonitorLogStatus Changes to this property will trigger replacement. string
InstanceChargeType Changes to this property will trigger replacement. string
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

InternetChargeType Changes to this property will trigger replacement. string
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
IpAddress Changes to this property will trigger replacement. string
The elastic ip address
Isp Changes to this property will trigger replacement. string
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
LogProject string
LogStore string
Mode string
Name string
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

Netmode Changes to this property will trigger replacement. string
PaymentType Changes to this property will trigger replacement. string
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
Period int
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
PricingCycle string
PublicIpAddressPoolId Changes to this property will trigger replacement. string
ResourceGroupId string
The Id of resource group which the eip belongs.
SecurityProtectionTypes Changes to this property will trigger replacement. List<string>
Status string
The EIP current status.
Tags Dictionary<string, string>
A mapping of tags to assign to the resource.
Zone Changes to this property will trigger replacement. string
ActivityId string
AddressName string
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
AllocationId Changes to this property will trigger replacement. string
AutoPay bool
Bandwidth string
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
CreateTime string
DeletionProtection bool
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
Description string
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
HighDefinitionMonitorLogStatus Changes to this property will trigger replacement. string
InstanceChargeType Changes to this property will trigger replacement. string
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

InternetChargeType Changes to this property will trigger replacement. string
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
IpAddress Changes to this property will trigger replacement. string
The elastic ip address
Isp Changes to this property will trigger replacement. string
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
LogProject string
LogStore string
Mode string
Name string
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

Netmode Changes to this property will trigger replacement. string
PaymentType Changes to this property will trigger replacement. string
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
Period int
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
PricingCycle string
PublicIpAddressPoolId Changes to this property will trigger replacement. string
ResourceGroupId string
The Id of resource group which the eip belongs.
SecurityProtectionTypes Changes to this property will trigger replacement. []string
Status string
The EIP current status.
Tags map[string]string
A mapping of tags to assign to the resource.
Zone Changes to this property will trigger replacement. string
activityId String
addressName String
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocationId Changes to this property will trigger replacement. String
autoPay Boolean
bandwidth String
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
createTime String
deletionProtection Boolean
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description String
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
highDefinitionMonitorLogStatus Changes to this property will trigger replacement. String
instanceChargeType Changes to this property will trigger replacement. String
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internetChargeType Changes to this property will trigger replacement. String
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ipAddress Changes to this property will trigger replacement. String
The elastic ip address
isp Changes to this property will trigger replacement. String
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
logProject String
logStore String
mode String
name String
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. String
paymentType Changes to this property will trigger replacement. String
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period Integer
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricingCycle String
publicIpAddressPoolId Changes to this property will trigger replacement. String
resourceGroupId String
The Id of resource group which the eip belongs.
securityProtectionTypes Changes to this property will trigger replacement. List<String>
status String
The EIP current status.
tags Map<String,String>
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. String
activityId string
addressName string
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocationId Changes to this property will trigger replacement. string
autoPay boolean
bandwidth string
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
createTime string
deletionProtection boolean
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description string
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
highDefinitionMonitorLogStatus Changes to this property will trigger replacement. string
instanceChargeType Changes to this property will trigger replacement. string
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internetChargeType Changes to this property will trigger replacement. string
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ipAddress Changes to this property will trigger replacement. string
The elastic ip address
isp Changes to this property will trigger replacement. string
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
logProject string
logStore string
mode string
name string
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. string
paymentType Changes to this property will trigger replacement. string
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period number
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricingCycle string
publicIpAddressPoolId Changes to this property will trigger replacement. string
resourceGroupId string
The Id of resource group which the eip belongs.
securityProtectionTypes Changes to this property will trigger replacement. string[]
status string
The EIP current status.
tags {[key: string]: string}
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. string
activity_id str
address_name str
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocation_id Changes to this property will trigger replacement. str
auto_pay bool
bandwidth str
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
create_time str
deletion_protection bool
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description str
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
high_definition_monitor_log_status Changes to this property will trigger replacement. str
instance_charge_type Changes to this property will trigger replacement. str
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internet_charge_type Changes to this property will trigger replacement. str
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ip_address Changes to this property will trigger replacement. str
The elastic ip address
isp Changes to this property will trigger replacement. str
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
log_project str
log_store str
mode str
name str
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. str
payment_type Changes to this property will trigger replacement. str
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period int
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricing_cycle str
public_ip_address_pool_id Changes to this property will trigger replacement. str
resource_group_id str
The Id of resource group which the eip belongs.
security_protection_types Changes to this property will trigger replacement. Sequence[str]
status str
The EIP current status.
tags Mapping[str, str]
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. str
activityId String
addressName String
The name of the EIP instance. This name can have a string of 2 to 128 characters, must contain only alphanumeric characters or hyphens, such as "-",".","_", and must not begin or end with a hyphen, and must not begin with http:// or https://.
allocationId Changes to this property will trigger replacement. String
autoPay Boolean
bandwidth String
Maximum bandwidth to the elastic public network, measured in Mbps (Mega bit per second). If this value is not specified, then automatically sets it to 5 Mbps.
createTime String
deletionProtection Boolean
Whether enable the deletion protection or not. Default value: false.

  • true: Enable deletion protection.
  • false: Disable deletion protection.
description String
Description of the EIP instance, This description can have a string of 2 to 256 characters, It cannot begin with http:// or https://. Default value is null.
highDefinitionMonitorLogStatus Changes to this property will trigger replacement. String
instanceChargeType Changes to this property will trigger replacement. String
(It has been deprecated from version 1.126.0 and using new attribute payment_type instead) Elastic IP instance charge type. Valid values are "PrePaid" and "PostPaid". Default to "PostPaid".

Deprecated: Field 'instance_charge_type' has been deprecated since provider version 1.126.0. New field 'payment_type' instead.

internetChargeType Changes to this property will trigger replacement. String
Internet charge type of the EIP, Valid values are PayByBandwidth, PayByTraffic. Default to PayByBandwidth. NOTE: From version 1.7.1 to 1.125.0, it defaults to PayByTraffic. It is only "PayByBandwidth" when instance_charge_type is PrePaid.
ipAddress Changes to this property will trigger replacement. String
The elastic ip address
isp Changes to this property will trigger replacement. String
The line type of the Elastic IP instance. Default to BGP. Other type of the isp need to open a whitelist.
logProject String
logStore String
mode String
name String
It has been deprecated from version 1.126.0 and using new attribute address_name instead.

Deprecated: Field 'name' has been deprecated since provider version 1.126.0. New field 'address_name' instead.

netmode Changes to this property will trigger replacement. String
paymentType Changes to this property will trigger replacement. String
The billing method of the EIP. Valid values: Subscription and PayAsYouGo. Default value is PayAsYouGo.
period Number
The duration that you will buy the resource, in month. It is valid when instance_charge_type is PrePaid. Valid values: [1-9, 12, 24, 36]. At present, the provider does not support modify "period" and you can do that via web console. NOTE: The attribute period is only used to create Subscription instance or modify the PayAsYouGo instance to Subscription. Once effect, it will not be modified that means running pulumi up will not effect the resource.
pricingCycle String
publicIpAddressPoolId Changes to this property will trigger replacement. String
resourceGroupId String
The Id of resource group which the eip belongs.
securityProtectionTypes Changes to this property will trigger replacement. List<String>
status String
The EIP current status.
tags Map<String>
A mapping of tags to assign to the resource.
zone Changes to this property will trigger replacement. String

Import

Elastic IP address can be imported using the id, e.g.

$ pulumi import alicloud:ecs/eip:Eip example eip-abc12345678
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.