Alibaba Cloud v3.57.1 published on Wednesday, Jun 26, 2024 by Pulumi
alicloud.sag.getSmartagFlowLogs
Explore with Pulumi AI
This data source provides the Smartag Flow Logs of the current Alibaba Cloud user.
NOTE: Available in v1.168.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.sag.getSmartagFlowLogs({
ids: ["example_id"],
});
export const smartagFlowLogId1 = ids.then(ids => ids.logs?.[0]?.id);
const nameRegex = alicloud.sag.getSmartagFlowLogs({
nameRegex: "^my-FlowLog",
});
export const smartagFlowLogId2 = nameRegex.then(nameRegex => nameRegex.logs?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.sag.get_smartag_flow_logs(ids=["example_id"])
pulumi.export("smartagFlowLogId1", ids.logs[0].id)
name_regex = alicloud.sag.get_smartag_flow_logs(name_regex="^my-FlowLog")
pulumi.export("smartagFlowLogId2", name_regex.logs[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/sag"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := sag.GetSmartagFlowLogs(ctx, &sag.GetSmartagFlowLogsArgs{
Ids: []string{
"example_id",
},
}, nil)
if err != nil {
return err
}
ctx.Export("smartagFlowLogId1", ids.Logs[0].Id)
nameRegex, err := sag.GetSmartagFlowLogs(ctx, &sag.GetSmartagFlowLogsArgs{
NameRegex: pulumi.StringRef("^my-FlowLog"),
}, nil)
if err != nil {
return err
}
ctx.Export("smartagFlowLogId2", nameRegex.Logs[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Sag.GetSmartagFlowLogs.Invoke(new()
{
Ids = new[]
{
"example_id",
},
});
var nameRegex = AliCloud.Sag.GetSmartagFlowLogs.Invoke(new()
{
NameRegex = "^my-FlowLog",
});
return new Dictionary<string, object?>
{
["smartagFlowLogId1"] = ids.Apply(getSmartagFlowLogsResult => getSmartagFlowLogsResult.Logs[0]?.Id),
["smartagFlowLogId2"] = nameRegex.Apply(getSmartagFlowLogsResult => getSmartagFlowLogsResult.Logs[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.sag.SagFunctions;
import com.pulumi.alicloud.sag.inputs.GetSmartagFlowLogsArgs;
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 = SagFunctions.getSmartagFlowLogs(GetSmartagFlowLogsArgs.builder()
.ids("example_id")
.build());
ctx.export("smartagFlowLogId1", ids.applyValue(getSmartagFlowLogsResult -> getSmartagFlowLogsResult.logs()[0].id()));
final var nameRegex = SagFunctions.getSmartagFlowLogs(GetSmartagFlowLogsArgs.builder()
.nameRegex("^my-FlowLog")
.build());
ctx.export("smartagFlowLogId2", nameRegex.applyValue(getSmartagFlowLogsResult -> getSmartagFlowLogsResult.logs()[0].id()));
}
}
variables:
ids:
fn::invoke:
Function: alicloud:sag:getSmartagFlowLogs
Arguments:
ids:
- example_id
nameRegex:
fn::invoke:
Function: alicloud:sag:getSmartagFlowLogs
Arguments:
nameRegex: ^my-FlowLog
outputs:
smartagFlowLogId1: ${ids.logs[0].id}
smartagFlowLogId2: ${nameRegex.logs[0].id}
Using getSmartagFlowLogs
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 getSmartagFlowLogs(args: GetSmartagFlowLogsArgs, opts?: InvokeOptions): Promise<GetSmartagFlowLogsResult>
function getSmartagFlowLogsOutput(args: GetSmartagFlowLogsOutputArgs, opts?: InvokeOptions): Output<GetSmartagFlowLogsResult>
def get_smartag_flow_logs(description: Optional[str] = None,
ids: Optional[Sequence[str]] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
page_number: Optional[int] = None,
page_size: Optional[int] = None,
status: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetSmartagFlowLogsResult
def get_smartag_flow_logs_output(description: Optional[pulumi.Input[str]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
page_number: Optional[pulumi.Input[int]] = None,
page_size: Optional[pulumi.Input[int]] = None,
status: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetSmartagFlowLogsResult]
func GetSmartagFlowLogs(ctx *Context, args *GetSmartagFlowLogsArgs, opts ...InvokeOption) (*GetSmartagFlowLogsResult, error)
func GetSmartagFlowLogsOutput(ctx *Context, args *GetSmartagFlowLogsOutputArgs, opts ...InvokeOption) GetSmartagFlowLogsResultOutput
> Note: This function is named GetSmartagFlowLogs
in the Go SDK.
public static class GetSmartagFlowLogs
{
public static Task<GetSmartagFlowLogsResult> InvokeAsync(GetSmartagFlowLogsArgs args, InvokeOptions? opts = null)
public static Output<GetSmartagFlowLogsResult> Invoke(GetSmartagFlowLogsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetSmartagFlowLogsResult> getSmartagFlowLogs(GetSmartagFlowLogsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:sag/getSmartagFlowLogs:getSmartagFlowLogs
arguments:
# arguments dictionary
The following arguments are supported:
- Description string
- The description of the flow log.
- Ids List<string>
- A list of Flow Log IDs.
- Name
Regex string - A regex string to filter results by Flow Log name.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Page
Number int - Page
Size int - Status string
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled.
- Description string
- The description of the flow log.
- Ids []string
- A list of Flow Log IDs.
- Name
Regex string - A regex string to filter results by Flow Log name.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Page
Number int - Page
Size int - Status string
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled.
- description String
- The description of the flow log.
- ids List<String>
- A list of Flow Log IDs.
- name
Regex String - A regex string to filter results by Flow Log name.
- output
File String - File name where to save data source results (after running
pulumi preview
). - page
Number Integer - page
Size Integer - status String
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled.
- description string
- The description of the flow log.
- ids string[]
- A list of Flow Log IDs.
- name
Regex string - A regex string to filter results by Flow Log name.
- output
File string - File name where to save data source results (after running
pulumi preview
). - page
Number number - page
Size number - status string
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled.
- description str
- The description of the flow log.
- ids Sequence[str]
- A list of Flow Log IDs.
- name_
regex str - A regex string to filter results by Flow Log name.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - page_
number int - page_
size int - status str
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled.
- description String
- The description of the flow log.
- ids List<String>
- A list of Flow Log IDs.
- name
Regex String - A regex string to filter results by Flow Log name.
- output
File String - File name where to save data source results (after running
pulumi preview
). - page
Number Number - page
Size Number - status String
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled.
getSmartagFlowLogs Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Logs
List<Pulumi.
Ali Cloud. Sag. Outputs. Get Smartag Flow Logs Log> - Names List<string>
- Description string
- Name
Regex string - Output
File string - Page
Number int - Page
Size int - Status string
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Logs
[]Get
Smartag Flow Logs Log - Names []string
- Description string
- Name
Regex string - Output
File string - Page
Number int - Page
Size int - Status string
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- logs
List<Get
Smartag Flow Logs Log> - names List<String>
- description String
- name
Regex String - output
File String - page
Number Integer - page
Size Integer - status String
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- logs
Get
Smartag Flow Logs Log[] - names string[]
- description string
- name
Regex string - output
File string - page
Number number - page
Size number - status string
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- logs
Sequence[Get
Smartag Flow Logs Log] - names Sequence[str]
- description str
- name_
regex str - output_
file str - page_
number int - page_
size int - status str
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- logs List<Property Map>
- names List<String>
- description String
- name
Regex String - output
File String - page
Number Number - page
Size Number - status String
Supporting Types
GetSmartagFlowLogsLog
- Active
Aging int - The time interval at which log data of active connections is collected. Valid values: 60 to 6000. Default value: 300. Unit: second.
- Description string
- The description of the flow log.
- Flow
Log stringId - The ID of the flow log.
- Flow
Log stringName - The name of the flow log.
- Id string
- The ID of the Flow Log.
- Inactive
Aging int - The time interval at which log data of inactive connections is connected. Valid values: 10 to 600. Default value: 15. Unit: second.
- Logstore
Name string - The name of the Log Service Logstore.
- Netflow
Server stringIp - The IP address of the NetFlow collector where the flow log is stored.
- Netflow
Server intPort - The port of the NetFlow collector. Default value: 9995.
- Netflow
Version string - The NetFlow version. Default value: V9.
- Output
Type string - The location where the flow log is stored. Valid values: sls: The flow log is stored in Log Service. netflow: The flow log is stored on a NetFlow collector. all: The flow log is stored both in Log Service and on a NetFlow collector.
- Project
Name string - The name of the Log Service project.
- Resource
Group stringId - The ID of the resource group.
- Sls
Region stringId - The ID of the region where Log Service is deployed.
- Status string
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled. - Total
Sag intNum - The number of Smart Access gateway (SAG) instances with which the flow log is associated.
- Active
Aging int - The time interval at which log data of active connections is collected. Valid values: 60 to 6000. Default value: 300. Unit: second.
- Description string
- The description of the flow log.
- Flow
Log stringId - The ID of the flow log.
- Flow
Log stringName - The name of the flow log.
- Id string
- The ID of the Flow Log.
- Inactive
Aging int - The time interval at which log data of inactive connections is connected. Valid values: 10 to 600. Default value: 15. Unit: second.
- Logstore
Name string - The name of the Log Service Logstore.
- Netflow
Server stringIp - The IP address of the NetFlow collector where the flow log is stored.
- Netflow
Server intPort - The port of the NetFlow collector. Default value: 9995.
- Netflow
Version string - The NetFlow version. Default value: V9.
- Output
Type string - The location where the flow log is stored. Valid values: sls: The flow log is stored in Log Service. netflow: The flow log is stored on a NetFlow collector. all: The flow log is stored both in Log Service and on a NetFlow collector.
- Project
Name string - The name of the Log Service project.
- Resource
Group stringId - The ID of the resource group.
- Sls
Region stringId - The ID of the region where Log Service is deployed.
- Status string
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled. - Total
Sag intNum - The number of Smart Access gateway (SAG) instances with which the flow log is associated.
- active
Aging Integer - The time interval at which log data of active connections is collected. Valid values: 60 to 6000. Default value: 300. Unit: second.
- description String
- The description of the flow log.
- flow
Log StringId - The ID of the flow log.
- flow
Log StringName - The name of the flow log.
- id String
- The ID of the Flow Log.
- inactive
Aging Integer - The time interval at which log data of inactive connections is connected. Valid values: 10 to 600. Default value: 15. Unit: second.
- logstore
Name String - The name of the Log Service Logstore.
- netflow
Server StringIp - The IP address of the NetFlow collector where the flow log is stored.
- netflow
Server IntegerPort - The port of the NetFlow collector. Default value: 9995.
- netflow
Version String - The NetFlow version. Default value: V9.
- output
Type String - The location where the flow log is stored. Valid values: sls: The flow log is stored in Log Service. netflow: The flow log is stored on a NetFlow collector. all: The flow log is stored both in Log Service and on a NetFlow collector.
- project
Name String - The name of the Log Service project.
- resource
Group StringId - The ID of the resource group.
- sls
Region StringId - The ID of the region where Log Service is deployed.
- status String
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled. - total
Sag IntegerNum - The number of Smart Access gateway (SAG) instances with which the flow log is associated.
- active
Aging number - The time interval at which log data of active connections is collected. Valid values: 60 to 6000. Default value: 300. Unit: second.
- description string
- The description of the flow log.
- flow
Log stringId - The ID of the flow log.
- flow
Log stringName - The name of the flow log.
- id string
- The ID of the Flow Log.
- inactive
Aging number - The time interval at which log data of inactive connections is connected. Valid values: 10 to 600. Default value: 15. Unit: second.
- logstore
Name string - The name of the Log Service Logstore.
- netflow
Server stringIp - The IP address of the NetFlow collector where the flow log is stored.
- netflow
Server numberPort - The port of the NetFlow collector. Default value: 9995.
- netflow
Version string - The NetFlow version. Default value: V9.
- output
Type string - The location where the flow log is stored. Valid values: sls: The flow log is stored in Log Service. netflow: The flow log is stored on a NetFlow collector. all: The flow log is stored both in Log Service and on a NetFlow collector.
- project
Name string - The name of the Log Service project.
- resource
Group stringId - The ID of the resource group.
- sls
Region stringId - The ID of the region where Log Service is deployed.
- status string
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled. - total
Sag numberNum - The number of Smart Access gateway (SAG) instances with which the flow log is associated.
- active_
aging int - The time interval at which log data of active connections is collected. Valid values: 60 to 6000. Default value: 300. Unit: second.
- description str
- The description of the flow log.
- flow_
log_ strid - The ID of the flow log.
- flow_
log_ strname - The name of the flow log.
- id str
- The ID of the Flow Log.
- inactive_
aging int - The time interval at which log data of inactive connections is connected. Valid values: 10 to 600. Default value: 15. Unit: second.
- logstore_
name str - The name of the Log Service Logstore.
- netflow_
server_ strip - The IP address of the NetFlow collector where the flow log is stored.
- netflow_
server_ intport - The port of the NetFlow collector. Default value: 9995.
- netflow_
version str - The NetFlow version. Default value: V9.
- output_
type str - The location where the flow log is stored. Valid values: sls: The flow log is stored in Log Service. netflow: The flow log is stored on a NetFlow collector. all: The flow log is stored both in Log Service and on a NetFlow collector.
- project_
name str - The name of the Log Service project.
- resource_
group_ strid - The ID of the resource group.
- sls_
region_ strid - The ID of the region where Log Service is deployed.
- status str
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled. - total_
sag_ intnum - The number of Smart Access gateway (SAG) instances with which the flow log is associated.
- active
Aging Number - The time interval at which log data of active connections is collected. Valid values: 60 to 6000. Default value: 300. Unit: second.
- description String
- The description of the flow log.
- flow
Log StringId - The ID of the flow log.
- flow
Log StringName - The name of the flow log.
- id String
- The ID of the Flow Log.
- inactive
Aging Number - The time interval at which log data of inactive connections is connected. Valid values: 10 to 600. Default value: 15. Unit: second.
- logstore
Name String - The name of the Log Service Logstore.
- netflow
Server StringIp - The IP address of the NetFlow collector where the flow log is stored.
- netflow
Server NumberPort - The port of the NetFlow collector. Default value: 9995.
- netflow
Version String - The NetFlow version. Default value: V9.
- output
Type String - The location where the flow log is stored. Valid values: sls: The flow log is stored in Log Service. netflow: The flow log is stored on a NetFlow collector. all: The flow log is stored both in Log Service and on a NetFlow collector.
- project
Name String - The name of the Log Service project.
- resource
Group StringId - The ID of the resource group.
- sls
Region StringId - The ID of the region where Log Service is deployed.
- status String
- The status of the flow log. Valid values:
Active
: The flow log is enabled.Inactive
: The flow log is disabled. - total
Sag NumberNum - The number of Smart Access gateway (SAG) instances with which the flow log is associated.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.