Exoscale v0.59.2 published on Monday, Jul 22, 2024 by Pulumiverse
exoscale.getElasticIp
Explore with Pulumi AI
Fetch Exoscale Elastic IPs (EIP) data.
Corresponding resource: exoscale_elastic_ip.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as exoscale from "@pulumi/exoscale";
const myElasticIp = exoscale.getElasticIp({
zone: "ch-gva-2",
ipAddress: "1.2.3.4",
});
export const myElasticIpId = myElasticIp.then(myElasticIp => myElasticIp.id);
import pulumi
import pulumi_exoscale as exoscale
my_elastic_ip = exoscale.get_elastic_ip(zone="ch-gva-2",
ip_address="1.2.3.4")
pulumi.export("myElasticIpId", my_elastic_ip.id)
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-exoscale/sdk/go/exoscale"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
myElasticIp, err := exoscale.LookupElasticIp(ctx, &exoscale.LookupElasticIpArgs{
Zone: "ch-gva-2",
IpAddress: pulumi.StringRef("1.2.3.4"),
}, nil)
if err != nil {
return err
}
ctx.Export("myElasticIpId", myElasticIp.Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Exoscale = Pulumi.Exoscale;
return await Deployment.RunAsync(() =>
{
var myElasticIp = Exoscale.GetElasticIp.Invoke(new()
{
Zone = "ch-gva-2",
IpAddress = "1.2.3.4",
});
return new Dictionary<string, object?>
{
["myElasticIpId"] = myElasticIp.Apply(getElasticIpResult => getElasticIpResult.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.exoscale.ExoscaleFunctions;
import com.pulumi.exoscale.inputs.GetElasticIpArgs;
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) {
final var myElasticIp = ExoscaleFunctions.getElasticIp(GetElasticIpArgs.builder()
.zone("ch-gva-2")
.ipAddress("1.2.3.4")
.build());
ctx.export("myElasticIpId", myElasticIp.applyValue(getElasticIpResult -> getElasticIpResult.id()));
}
}
variables:
myElasticIp:
fn::invoke:
Function: exoscale:getElasticIp
Arguments:
zone: ch-gva-2
ipAddress: 1.2.3.4
outputs:
myElasticIpId: ${myElasticIp.id}
Please refer to the examples directory for complete configuration examples.
Using getElasticIp
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getElasticIp(args: GetElasticIpArgs, opts?: InvokeOptions): Promise<GetElasticIpResult>
function getElasticIpOutput(args: GetElasticIpOutputArgs, opts?: InvokeOptions): Output<GetElasticIpResult>
def get_elastic_ip(id: Optional[str] = None,
ip_address: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
zone: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetElasticIpResult
def get_elastic_ip_output(id: Optional[pulumi.Input[str]] = None,
ip_address: Optional[pulumi.Input[str]] = None,
labels: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
zone: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetElasticIpResult]
func LookupElasticIp(ctx *Context, args *LookupElasticIpArgs, opts ...InvokeOption) (*LookupElasticIpResult, error)
func LookupElasticIpOutput(ctx *Context, args *LookupElasticIpOutputArgs, opts ...InvokeOption) LookupElasticIpResultOutput
> Note: This function is named LookupElasticIp
in the Go SDK.
public static class GetElasticIp
{
public static Task<GetElasticIpResult> InvokeAsync(GetElasticIpArgs args, InvokeOptions? opts = null)
public static Output<GetElasticIpResult> Invoke(GetElasticIpInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetElasticIpResult> getElasticIp(GetElasticIpArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: exoscale:index/getElasticIp:getElasticIp
arguments:
# arguments dictionary
The following arguments are supported:
- zone str
- The Exocale Zone name.
- id str
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - ip_
address str - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - labels Mapping[str, str]
- The EIP labels to match (conflicts with
ip_address
andid
).
getElasticIp Result
The following output properties are available:
- Address
Family string - The Elastic IP (EIP) address family (
inet4
orinet6
). - Cidr string
- The Elastic IP (EIP) CIDR.
- Description string
- The Elastic IP (EIP) description.
- Healthchecks
List<Pulumiverse.
Exoscale. Outputs. Get Elastic Ip Healthcheck> - The managed EIP healthcheck configuration.
- Reverse
Dns string - Domain name for reverse DNS record.
- Zone string
- The Exocale Zone name.
- Id string
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - Ip
Address string - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - Labels Dictionary<string, string>
- The EIP labels to match (conflicts with
ip_address
andid
).
- Address
Family string - The Elastic IP (EIP) address family (
inet4
orinet6
). - Cidr string
- The Elastic IP (EIP) CIDR.
- Description string
- The Elastic IP (EIP) description.
- Healthchecks
[]Get
Elastic Ip Healthcheck - The managed EIP healthcheck configuration.
- Reverse
Dns string - Domain name for reverse DNS record.
- Zone string
- The Exocale Zone name.
- Id string
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - Ip
Address string - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - Labels map[string]string
- The EIP labels to match (conflicts with
ip_address
andid
).
- address
Family String - The Elastic IP (EIP) address family (
inet4
orinet6
). - cidr String
- The Elastic IP (EIP) CIDR.
- description String
- The Elastic IP (EIP) description.
- healthchecks
List<Get
Elastic Ip Healthcheck> - The managed EIP healthcheck configuration.
- reverse
Dns String - Domain name for reverse DNS record.
- zone String
- The Exocale Zone name.
- id String
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - ip
Address String - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - labels Map<String,String>
- The EIP labels to match (conflicts with
ip_address
andid
).
- address
Family string - The Elastic IP (EIP) address family (
inet4
orinet6
). - cidr string
- The Elastic IP (EIP) CIDR.
- description string
- The Elastic IP (EIP) description.
- healthchecks
Get
Elastic Ip Healthcheck[] - The managed EIP healthcheck configuration.
- reverse
Dns string - Domain name for reverse DNS record.
- zone string
- The Exocale Zone name.
- id string
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - ip
Address string - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - labels {[key: string]: string}
- The EIP labels to match (conflicts with
ip_address
andid
).
- address_
family str - The Elastic IP (EIP) address family (
inet4
orinet6
). - cidr str
- The Elastic IP (EIP) CIDR.
- description str
- The Elastic IP (EIP) description.
- healthchecks
Sequence[Get
Elastic Ip Healthcheck] - The managed EIP healthcheck configuration.
- reverse_
dns str - Domain name for reverse DNS record.
- zone str
- The Exocale Zone name.
- id str
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - ip_
address str - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - labels Mapping[str, str]
- The EIP labels to match (conflicts with
ip_address
andid
).
- address
Family String - The Elastic IP (EIP) address family (
inet4
orinet6
). - cidr String
- The Elastic IP (EIP) CIDR.
- description String
- The Elastic IP (EIP) description.
- healthchecks List<Property Map>
- The managed EIP healthcheck configuration.
- reverse
Dns String - Domain name for reverse DNS record.
- zone String
- The Exocale Zone name.
- id String
- The Elastic IP (EIP) ID to match (conflicts with
ip_address
andlabels
). - ip
Address String - The EIP IPv4 or IPv6 address to match (conflicts with
id
andlabels
). - labels Map<String>
- The EIP labels to match (conflicts with
ip_address
andid
).
Supporting Types
GetElasticIpHealthcheck
- Interval int
- The healthcheck interval in seconds.
- Mode string
- The healthcheck mode.
- Port int
- The healthcheck target port.
- Strikes
Fail int - The number of failed healthcheck attempts before considering the target unhealthy.
- Strikes
Ok int - The number of successful healthcheck attempts before considering the target healthy.
- Timeout int
- The time in seconds before considering a healthcheck probing failed.
- Tls
Skip boolVerify - Disable TLS certificate verification for healthcheck in
https
mode. - Tls
Sni string - The healthcheck server name to present with SNI in
https
mode. - Uri string
- The healthcheck URI.
- Interval int
- The healthcheck interval in seconds.
- Mode string
- The healthcheck mode.
- Port int
- The healthcheck target port.
- Strikes
Fail int - The number of failed healthcheck attempts before considering the target unhealthy.
- Strikes
Ok int - The number of successful healthcheck attempts before considering the target healthy.
- Timeout int
- The time in seconds before considering a healthcheck probing failed.
- Tls
Skip boolVerify - Disable TLS certificate verification for healthcheck in
https
mode. - Tls
Sni string - The healthcheck server name to present with SNI in
https
mode. - Uri string
- The healthcheck URI.
- interval Integer
- The healthcheck interval in seconds.
- mode String
- The healthcheck mode.
- port Integer
- The healthcheck target port.
- strikes
Fail Integer - The number of failed healthcheck attempts before considering the target unhealthy.
- strikes
Ok Integer - The number of successful healthcheck attempts before considering the target healthy.
- timeout Integer
- The time in seconds before considering a healthcheck probing failed.
- tls
Skip BooleanVerify - Disable TLS certificate verification for healthcheck in
https
mode. - tls
Sni String - The healthcheck server name to present with SNI in
https
mode. - uri String
- The healthcheck URI.
- interval number
- The healthcheck interval in seconds.
- mode string
- The healthcheck mode.
- port number
- The healthcheck target port.
- strikes
Fail number - The number of failed healthcheck attempts before considering the target unhealthy.
- strikes
Ok number - The number of successful healthcheck attempts before considering the target healthy.
- timeout number
- The time in seconds before considering a healthcheck probing failed.
- tls
Skip booleanVerify - Disable TLS certificate verification for healthcheck in
https
mode. - tls
Sni string - The healthcheck server name to present with SNI in
https
mode. - uri string
- The healthcheck URI.
- interval int
- The healthcheck interval in seconds.
- mode str
- The healthcheck mode.
- port int
- The healthcheck target port.
- strikes_
fail int - The number of failed healthcheck attempts before considering the target unhealthy.
- strikes_
ok int - The number of successful healthcheck attempts before considering the target healthy.
- timeout int
- The time in seconds before considering a healthcheck probing failed.
- tls_
skip_ boolverify - Disable TLS certificate verification for healthcheck in
https
mode. - tls_
sni str - The healthcheck server name to present with SNI in
https
mode. - uri str
- The healthcheck URI.
- interval Number
- The healthcheck interval in seconds.
- mode String
- The healthcheck mode.
- port Number
- The healthcheck target port.
- strikes
Fail Number - The number of failed healthcheck attempts before considering the target unhealthy.
- strikes
Ok Number - The number of successful healthcheck attempts before considering the target healthy.
- timeout Number
- The time in seconds before considering a healthcheck probing failed.
- tls
Skip BooleanVerify - Disable TLS certificate verification for healthcheck in
https
mode. - tls
Sni String - The healthcheck server name to present with SNI in
https
mode. - uri String
- The healthcheck URI.
Package Details
- Repository
- exoscale pulumiverse/pulumi-exoscale
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
exoscale
Terraform Provider.