1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. getMysqlProjectSecurityGroup
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.getMysqlProjectSecurityGroup

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Use this data source to query detailed information of mysql project_security_group

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const projectSecurityGroup = tencentcloud.getMysqlProjectSecurityGroup({
        projectId: 1250480,
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    project_security_group = tencentcloud.get_mysql_project_security_group(project_id=1250480)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.GetMysqlProjectSecurityGroup(ctx, &tencentcloud.GetMysqlProjectSecurityGroupArgs{
    			ProjectId: pulumi.Float64Ref(1250480),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var projectSecurityGroup = Tencentcloud.GetMysqlProjectSecurityGroup.Invoke(new()
        {
            ProjectId = 1250480,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.TencentcloudFunctions;
    import com.pulumi.tencentcloud.inputs.GetMysqlProjectSecurityGroupArgs;
    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 projectSecurityGroup = TencentcloudFunctions.getMysqlProjectSecurityGroup(GetMysqlProjectSecurityGroupArgs.builder()
                .projectId(1250480)
                .build());
    
        }
    }
    
    variables:
      projectSecurityGroup:
        fn::invoke:
          function: tencentcloud:getMysqlProjectSecurityGroup
          arguments:
            projectId: 1.25048e+06
    

    Using getMysqlProjectSecurityGroup

    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 getMysqlProjectSecurityGroup(args: GetMysqlProjectSecurityGroupArgs, opts?: InvokeOptions): Promise<GetMysqlProjectSecurityGroupResult>
    function getMysqlProjectSecurityGroupOutput(args: GetMysqlProjectSecurityGroupOutputArgs, opts?: InvokeOptions): Output<GetMysqlProjectSecurityGroupResult>
    def get_mysql_project_security_group(id: Optional[str] = None,
                                         project_id: Optional[float] = None,
                                         result_output_file: Optional[str] = None,
                                         opts: Optional[InvokeOptions] = None) -> GetMysqlProjectSecurityGroupResult
    def get_mysql_project_security_group_output(id: Optional[pulumi.Input[str]] = None,
                                         project_id: Optional[pulumi.Input[float]] = None,
                                         result_output_file: Optional[pulumi.Input[str]] = None,
                                         opts: Optional[InvokeOptions] = None) -> Output[GetMysqlProjectSecurityGroupResult]
    func GetMysqlProjectSecurityGroup(ctx *Context, args *GetMysqlProjectSecurityGroupArgs, opts ...InvokeOption) (*GetMysqlProjectSecurityGroupResult, error)
    func GetMysqlProjectSecurityGroupOutput(ctx *Context, args *GetMysqlProjectSecurityGroupOutputArgs, opts ...InvokeOption) GetMysqlProjectSecurityGroupResultOutput

    > Note: This function is named GetMysqlProjectSecurityGroup in the Go SDK.

    public static class GetMysqlProjectSecurityGroup 
    {
        public static Task<GetMysqlProjectSecurityGroupResult> InvokeAsync(GetMysqlProjectSecurityGroupArgs args, InvokeOptions? opts = null)
        public static Output<GetMysqlProjectSecurityGroupResult> Invoke(GetMysqlProjectSecurityGroupInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetMysqlProjectSecurityGroupResult> getMysqlProjectSecurityGroup(GetMysqlProjectSecurityGroupArgs args, InvokeOptions options)
    public static Output<GetMysqlProjectSecurityGroupResult> getMysqlProjectSecurityGroup(GetMysqlProjectSecurityGroupArgs args, InvokeOptions options)
    
    fn::invoke:
      function: tencentcloud:index/getMysqlProjectSecurityGroup:getMysqlProjectSecurityGroup
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    ProjectId double
    project id.
    ResultOutputFile string
    Used to save results.
    Id string
    ProjectId float64
    project id.
    ResultOutputFile string
    Used to save results.
    id String
    projectId Double
    project id.
    resultOutputFile String
    Used to save results.
    id string
    projectId number
    project id.
    resultOutputFile string
    Used to save results.
    id str
    project_id float
    project id.
    result_output_file str
    Used to save results.
    id String
    projectId Number
    project id.
    resultOutputFile String
    Used to save results.

    getMysqlProjectSecurityGroup Result

    The following output properties are available:

    Groups List<GetMysqlProjectSecurityGroupGroup>
    Security group details.
    Id string
    ProjectId double
    project id.
    ResultOutputFile string
    Groups []GetMysqlProjectSecurityGroupGroup
    Security group details.
    Id string
    ProjectId float64
    project id.
    ResultOutputFile string
    groups List<GetMysqlProjectSecurityGroupGroup>
    Security group details.
    id String
    projectId Double
    project id.
    resultOutputFile String
    groups GetMysqlProjectSecurityGroupGroup[]
    Security group details.
    id string
    projectId number
    project id.
    resultOutputFile string
    groups List<Property Map>
    Security group details.
    id String
    projectId Number
    project id.
    resultOutputFile String

    Supporting Types

    GetMysqlProjectSecurityGroupGroup

    CreateTime string
    Creation time, time format: yyyy-mm-dd hh:mm:sss.
    Inbounds List<GetMysqlProjectSecurityGroupGroupInbound>
    inbound rules.
    Outbounds List<GetMysqlProjectSecurityGroupGroupOutbound>
    outbound rules.
    ProjectId double
    project id.
    SecurityGroupId string
    Security group ID.
    SecurityGroupName string
    Security group name.
    SecurityGroupRemark string
    Security group remark.
    CreateTime string
    Creation time, time format: yyyy-mm-dd hh:mm:sss.
    Inbounds []GetMysqlProjectSecurityGroupGroupInbound
    inbound rules.
    Outbounds []GetMysqlProjectSecurityGroupGroupOutbound
    outbound rules.
    ProjectId float64
    project id.
    SecurityGroupId string
    Security group ID.
    SecurityGroupName string
    Security group name.
    SecurityGroupRemark string
    Security group remark.
    createTime String
    Creation time, time format: yyyy-mm-dd hh:mm:sss.
    inbounds List<GetMysqlProjectSecurityGroupGroupInbound>
    inbound rules.
    outbounds List<GetMysqlProjectSecurityGroupGroupOutbound>
    outbound rules.
    projectId Double
    project id.
    securityGroupId String
    Security group ID.
    securityGroupName String
    Security group name.
    securityGroupRemark String
    Security group remark.
    createTime string
    Creation time, time format: yyyy-mm-dd hh:mm:sss.
    inbounds GetMysqlProjectSecurityGroupGroupInbound[]
    inbound rules.
    outbounds GetMysqlProjectSecurityGroupGroupOutbound[]
    outbound rules.
    projectId number
    project id.
    securityGroupId string
    Security group ID.
    securityGroupName string
    Security group name.
    securityGroupRemark string
    Security group remark.
    create_time str
    Creation time, time format: yyyy-mm-dd hh:mm:sss.
    inbounds Sequence[GetMysqlProjectSecurityGroupGroupInbound]
    inbound rules.
    outbounds Sequence[GetMysqlProjectSecurityGroupGroupOutbound]
    outbound rules.
    project_id float
    project id.
    security_group_id str
    Security group ID.
    security_group_name str
    Security group name.
    security_group_remark str
    Security group remark.
    createTime String
    Creation time, time format: yyyy-mm-dd hh:mm:sss.
    inbounds List<Property Map>
    inbound rules.
    outbounds List<Property Map>
    outbound rules.
    projectId Number
    project id.
    securityGroupId String
    Security group ID.
    securityGroupName String
    Security group name.
    securityGroupRemark String
    Security group remark.

    GetMysqlProjectSecurityGroupGroupInbound

    Action string
    Policy, ACCEPT or DROP.
    CidrIp string
    Destination IP or IP segment, such as 172.16.0.0/12.
    Desc string
    Rule description.
    Dir string
    The direction defined by the rule, the inbound rule is OUTPUT.
    IpProtocol string
    Network protocol, support UDP, TCP, etc.
    PortRange string
    port or port range.
    Action string
    Policy, ACCEPT or DROP.
    CidrIp string
    Destination IP or IP segment, such as 172.16.0.0/12.
    Desc string
    Rule description.
    Dir string
    The direction defined by the rule, the inbound rule is OUTPUT.
    IpProtocol string
    Network protocol, support UDP, TCP, etc.
    PortRange string
    port or port range.
    action String
    Policy, ACCEPT or DROP.
    cidrIp String
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc String
    Rule description.
    dir String
    The direction defined by the rule, the inbound rule is OUTPUT.
    ipProtocol String
    Network protocol, support UDP, TCP, etc.
    portRange String
    port or port range.
    action string
    Policy, ACCEPT or DROP.
    cidrIp string
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc string
    Rule description.
    dir string
    The direction defined by the rule, the inbound rule is OUTPUT.
    ipProtocol string
    Network protocol, support UDP, TCP, etc.
    portRange string
    port or port range.
    action str
    Policy, ACCEPT or DROP.
    cidr_ip str
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc str
    Rule description.
    dir str
    The direction defined by the rule, the inbound rule is OUTPUT.
    ip_protocol str
    Network protocol, support UDP, TCP, etc.
    port_range str
    port or port range.
    action String
    Policy, ACCEPT or DROP.
    cidrIp String
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc String
    Rule description.
    dir String
    The direction defined by the rule, the inbound rule is OUTPUT.
    ipProtocol String
    Network protocol, support UDP, TCP, etc.
    portRange String
    port or port range.

    GetMysqlProjectSecurityGroupGroupOutbound

    Action string
    Policy, ACCEPT or DROP.
    CidrIp string
    Destination IP or IP segment, such as 172.16.0.0/12.
    Desc string
    Rule description.
    Dir string
    The direction defined by the rule, the inbound rule is OUTPUT.
    IpProtocol string
    Network protocol, support UDP, TCP, etc.
    PortRange string
    port or port range.
    Action string
    Policy, ACCEPT or DROP.
    CidrIp string
    Destination IP or IP segment, such as 172.16.0.0/12.
    Desc string
    Rule description.
    Dir string
    The direction defined by the rule, the inbound rule is OUTPUT.
    IpProtocol string
    Network protocol, support UDP, TCP, etc.
    PortRange string
    port or port range.
    action String
    Policy, ACCEPT or DROP.
    cidrIp String
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc String
    Rule description.
    dir String
    The direction defined by the rule, the inbound rule is OUTPUT.
    ipProtocol String
    Network protocol, support UDP, TCP, etc.
    portRange String
    port or port range.
    action string
    Policy, ACCEPT or DROP.
    cidrIp string
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc string
    Rule description.
    dir string
    The direction defined by the rule, the inbound rule is OUTPUT.
    ipProtocol string
    Network protocol, support UDP, TCP, etc.
    portRange string
    port or port range.
    action str
    Policy, ACCEPT or DROP.
    cidr_ip str
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc str
    Rule description.
    dir str
    The direction defined by the rule, the inbound rule is OUTPUT.
    ip_protocol str
    Network protocol, support UDP, TCP, etc.
    port_range str
    port or port range.
    action String
    Policy, ACCEPT or DROP.
    cidrIp String
    Destination IP or IP segment, such as 172.16.0.0/12.
    desc String
    Rule description.
    dir String
    The direction defined by the rule, the inbound rule is OUTPUT.
    ipProtocol String
    Network protocol, support UDP, TCP, etc.
    portRange String
    port or port range.

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    tencentcloud logo
    tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack