Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi
alicloud.dns.getCustomLines
Explore with Pulumi AI
This data source provides the Alidns Custom Lines of the current Alibaba Cloud user.
NOTE: Available in v1.151.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.dns.getCustomLines({
enableDetails: true,
domainName: "your_domain_name",
});
export const alidnsCustomLineId1 = ids.then(ids => ids.lines?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.dns.get_custom_lines(enable_details=True,
domain_name="your_domain_name")
pulumi.export("alidnsCustomLineId1", ids.lines[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/dns"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := dns.GetCustomLines(ctx, &dns.GetCustomLinesArgs{
EnableDetails: pulumi.BoolRef(true),
DomainName: "your_domain_name",
}, nil)
if err != nil {
return err
}
ctx.Export("alidnsCustomLineId1", ids.Lines[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Dns.GetCustomLines.Invoke(new()
{
EnableDetails = true,
DomainName = "your_domain_name",
});
return new Dictionary<string, object?>
{
["alidnsCustomLineId1"] = ids.Apply(getCustomLinesResult => getCustomLinesResult.Lines[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.dns.DnsFunctions;
import com.pulumi.alicloud.dns.inputs.GetCustomLinesArgs;
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 ids = DnsFunctions.getCustomLines(GetCustomLinesArgs.builder()
.enableDetails(true)
.domainName("your_domain_name")
.build());
ctx.export("alidnsCustomLineId1", ids.applyValue(getCustomLinesResult -> getCustomLinesResult.lines()[0].id()));
}
}
variables:
ids:
fn::invoke:
Function: alicloud:dns:getCustomLines
Arguments:
enableDetails: true
domainName: your_domain_name
outputs:
alidnsCustomLineId1: ${ids.lines[0].id}
Using getCustomLines
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 getCustomLines(args: GetCustomLinesArgs, opts?: InvokeOptions): Promise<GetCustomLinesResult>
function getCustomLinesOutput(args: GetCustomLinesOutputArgs, opts?: InvokeOptions): Output<GetCustomLinesResult>
def get_custom_lines(domain_name: Optional[str] = None,
enable_details: Optional[bool] = None,
ids: Optional[Sequence[str]] = None,
lang: Optional[str] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetCustomLinesResult
def get_custom_lines_output(domain_name: Optional[pulumi.Input[str]] = None,
enable_details: Optional[pulumi.Input[bool]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
lang: Optional[pulumi.Input[str]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetCustomLinesResult]
func GetCustomLines(ctx *Context, args *GetCustomLinesArgs, opts ...InvokeOption) (*GetCustomLinesResult, error)
func GetCustomLinesOutput(ctx *Context, args *GetCustomLinesOutputArgs, opts ...InvokeOption) GetCustomLinesResultOutput
> Note: This function is named GetCustomLines
in the Go SDK.
public static class GetCustomLines
{
public static Task<GetCustomLinesResult> InvokeAsync(GetCustomLinesArgs args, InvokeOptions? opts = null)
public static Output<GetCustomLinesResult> Invoke(GetCustomLinesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCustomLinesResult> getCustomLines(GetCustomLinesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:dns/getCustomLines:getCustomLines
arguments:
# arguments dictionary
The following arguments are supported:
- Domain
Name string - The Domain name.
- Enable
Details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - Ids List<string>
- A list of Custom Line IDs.
- Lang string
- The lang.
- Name
Regex string - A regex string to filter results by Custom Line name.
- Output
File string - File name where to save data source results (after running
pulumi preview
).
- Domain
Name string - The Domain name.
- Enable
Details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - Ids []string
- A list of Custom Line IDs.
- Lang string
- The lang.
- Name
Regex string - A regex string to filter results by Custom Line name.
- Output
File string - File name where to save data source results (after running
pulumi preview
).
- domain
Name String - The Domain name.
- enable
Details Boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids List<String>
- A list of Custom Line IDs.
- lang String
- The lang.
- name
Regex String - A regex string to filter results by Custom Line name.
- output
File String - File name where to save data source results (after running
pulumi preview
).
- domain
Name string - The Domain name.
- enable
Details boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids string[]
- A list of Custom Line IDs.
- lang string
- The lang.
- name
Regex string - A regex string to filter results by Custom Line name.
- output
File string - File name where to save data source results (after running
pulumi preview
).
- domain_
name str - The Domain name.
- enable_
details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - ids Sequence[str]
- A list of Custom Line IDs.
- lang str
- The lang.
- name_
regex str - A regex string to filter results by Custom Line name.
- output_
file str - File name where to save data source results (after running
pulumi preview
).
- domain
Name String - The Domain name.
- enable
Details Boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids List<String>
- A list of Custom Line IDs.
- lang String
- The lang.
- name
Regex String - A regex string to filter results by Custom Line name.
- output
File String - File name where to save data source results (after running
pulumi preview
).
getCustomLines Result
The following output properties are available:
- Domain
Name string - Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Lines
List<Pulumi.
Ali Cloud. Dns. Outputs. Get Custom Lines Line> - Names List<string>
- Enable
Details bool - Lang string
- Name
Regex string - Output
File string
- Domain
Name string - Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Lines
[]Get
Custom Lines Line - Names []string
- Enable
Details bool - Lang string
- Name
Regex string - Output
File string
- domain
Name String - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- lines
List<Get
Custom Lines Line> - names List<String>
- enable
Details Boolean - lang String
- name
Regex String - output
File String
- domain
Name string - id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- lines
Get
Custom Lines Line[] - names string[]
- enable
Details boolean - lang string
- name
Regex string - output
File string
- domain_
name str - id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- lines
Sequence[Get
Custom Lines Line] - names Sequence[str]
- enable_
details bool - lang str
- name_
regex str - output_
file str
- domain
Name String - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- lines List<Property Map>
- names List<String>
- enable
Details Boolean - lang String
- name
Regex String - output
File String
Supporting Types
GetCustomLinesLine
- Code string
- The Custom line Code.
- Custom
Line stringId - The first ID of the resource.
- Custom
Line stringName - Line name.
- Domain
Name string - The Domain name.
- Id string
- The ID of the Custom Line.
- Ip
Segment List<Pulumi.Lists Ali Cloud. Dns. Inputs. Get Custom Lines Line Ip Segment List> - The IP segment list.
- Code string
- The Custom line Code.
- Custom
Line stringId - The first ID of the resource.
- Custom
Line stringName - Line name.
- Domain
Name string - The Domain name.
- Id string
- The ID of the Custom Line.
- Ip
Segment []GetLists Custom Lines Line Ip Segment List - The IP segment list.
- code String
- The Custom line Code.
- custom
Line StringId - The first ID of the resource.
- custom
Line StringName - Line name.
- domain
Name String - The Domain name.
- id String
- The ID of the Custom Line.
- ip
Segment List<GetLists Custom Lines Line Ip Segment List> - The IP segment list.
- code string
- The Custom line Code.
- custom
Line stringId - The first ID of the resource.
- custom
Line stringName - Line name.
- domain
Name string - The Domain name.
- id string
- The ID of the Custom Line.
- ip
Segment GetLists Custom Lines Line Ip Segment List[] - The IP segment list.
- code str
- The Custom line Code.
- custom_
line_ strid - The first ID of the resource.
- custom_
line_ strname - Line name.
- domain_
name str - The Domain name.
- id str
- The ID of the Custom Line.
- ip_
segment_ Sequence[Getlists Custom Lines Line Ip Segment List] - The IP segment list.
- code String
- The Custom line Code.
- custom
Line StringId - The first ID of the resource.
- custom
Line StringName - Line name.
- domain
Name String - The Domain name.
- id String
- The ID of the Custom Line.
- ip
Segment List<Property Map>Lists - The IP segment list.
GetCustomLinesLineIpSegmentList
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.