get Hosted Zone
Use this data source to get the ID of an elastic beanstalk hosted zone.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const current = aws.elasticbeanstalk.getHostedZone({});
Content copied to clipboard
import pulumi
import pulumi_aws as aws
current = aws.elasticbeanstalk.get_hosted_zone()
Content copied to clipboard
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var current = Aws.ElasticBeanstalk.GetHostedZone.Invoke();
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/elasticbeanstalk"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := elasticbeanstalk.GetHostedZone(ctx, &elasticbeanstalk.GetHostedZoneArgs{}, nil)
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.elasticbeanstalk.ElasticbeanstalkFunctions;
import com.pulumi.aws.elasticbeanstalk.inputs.GetHostedZoneArgs;
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 current = ElasticbeanstalkFunctions.getHostedZone(GetHostedZoneArgs.builder()
.build());
}
}
Content copied to clipboard
variables:
current:
fn::invoke:
function: aws:elasticbeanstalk:getHostedZone
arguments: {}
Content copied to clipboard
Return
A collection of values returned by getHostedZone.
Parameters
argument
A collection of arguments for invoking getHostedZone.
Return
A collection of values returned by getHostedZone.
Parameters
region
Region you'd like the zone for. By default, fetches the current region.
See also
suspend fun getHostedZone(argument: suspend GetHostedZonePlainArgsBuilder.() -> Unit): GetHostedZoneResult
Return
A collection of values returned by getHostedZone.
Parameters
argument
Builder for com.pulumi.aws.elasticbeanstalk.kotlin.inputs.GetHostedZonePlainArgs.