Snowflake v0.59.0 published on Friday, Sep 20, 2024 by Pulumi
snowflake.getSystemGetPrivateLinkConfig
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
import * as snowflake from "@pulumi/snowflake";
const snowflakePrivateLink = snowflake.getSystemGetPrivateLinkConfig({});
const snowflakePrivateLinkSecurityGroup = new aws.index.SecurityGroup("snowflake_private_link", {
vpcId: vpcId,
ingress: [
{
fromPort: 80,
toPort: 80,
cidrBlocks: vpcCidr,
protocol: "tcp",
},
{
fromPort: 443,
toPort: 443,
cidrBlocks: vpcCidr,
protocol: "tcp",
},
],
});
const snowflakePrivateLinkVpcEndpoint = new aws.index.VpcEndpoint("snowflake_private_link", {
vpcId: vpcId,
serviceName: snowflakePrivateLink.awsVpceId,
vpcEndpointType: "Interface",
securityGroupIds: [snowflakePrivateLinkSecurityGroup.id],
subnetIds: subnetIds,
privateDnsEnabled: false,
});
const snowflakePrivateLinkRoute53Zone = new aws.index.Route53Zone("snowflake_private_link", {
name: "privatelink.snowflakecomputing.com",
vpc: [{
vpcId: vpcId,
}],
});
const snowflakePrivateLinkUrl = new aws.index.Route53Record("snowflake_private_link_url", {
zoneId: snowflakePrivateLinkRoute53Zone.zoneId,
name: snowflakePrivateLink.accountUrl,
type: "CNAME",
ttl: "300",
records: [snowflakePrivateLinkVpcEndpoint.dnsEntry[0].dns_name],
});
const snowflakePrivateLinkOcspUrl = new aws.index.Route53Record("snowflake_private_link_ocsp_url", {
zoneId: snowflakePrivateLinkRoute53Zone.zoneId,
name: snowflakePrivateLink.ocspUrl,
type: "CNAME",
ttl: "300",
records: [snowflakePrivateLinkVpcEndpoint.dnsEntry[0].dns_name],
});
import pulumi
import pulumi_aws as aws
import pulumi_snowflake as snowflake
snowflake_private_link = snowflake.get_system_get_private_link_config()
snowflake_private_link_security_group = aws.index.SecurityGroup("snowflake_private_link",
vpc_id=vpc_id,
ingress=[
{
fromPort: 80,
toPort: 80,
cidrBlocks: vpc_cidr,
protocol: tcp,
},
{
fromPort: 443,
toPort: 443,
cidrBlocks: vpc_cidr,
protocol: tcp,
},
])
snowflake_private_link_vpc_endpoint = aws.index.VpcEndpoint("snowflake_private_link",
vpc_id=vpc_id,
service_name=snowflake_private_link.aws_vpce_id,
vpc_endpoint_type=Interface,
security_group_ids=[snowflake_private_link_security_group.id],
subnet_ids=subnet_ids,
private_dns_enabled=False)
snowflake_private_link_route53_zone = aws.index.Route53Zone("snowflake_private_link",
name=privatelink.snowflakecomputing.com,
vpc=[{
vpcId: vpc_id,
}])
snowflake_private_link_url = aws.index.Route53Record("snowflake_private_link_url",
zone_id=snowflake_private_link_route53_zone.zone_id,
name=snowflake_private_link.account_url,
type=CNAME,
ttl=300,
records=[snowflake_private_link_vpc_endpoint.dns_entry[0].dns_name])
snowflake_private_link_ocsp_url = aws.index.Route53Record("snowflake_private_link_ocsp_url",
zone_id=snowflake_private_link_route53_zone.zone_id,
name=snowflake_private_link.ocsp_url,
type=CNAME,
ttl=300,
records=[snowflake_private_link_vpc_endpoint.dns_entry[0].dns_name])
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v4/go/aws"
"github.com/pulumi/pulumi-snowflake/sdk/go/snowflake"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
snowflakePrivateLink, err := snowflake.GetSystemGetPrivateLinkConfig(ctx, nil, nil)
if err != nil {
return err
}
snowflakePrivateLinkSecurityGroup, err := aws.NewSecurityGroup(ctx, "snowflake_private_link", &aws.SecurityGroupArgs{
VpcId: vpcId,
Ingress: []interface{}{
map[string]interface{}{
"fromPort": 80,
"toPort": 80,
"cidrBlocks": vpcCidr,
"protocol": "tcp",
},
map[string]interface{}{
"fromPort": 443,
"toPort": 443,
"cidrBlocks": vpcCidr,
"protocol": "tcp",
},
},
})
if err != nil {
return err
}
snowflakePrivateLinkVpcEndpoint, err := aws.NewVpcEndpoint(ctx, "snowflake_private_link", &aws.VpcEndpointArgs{
VpcId: vpcId,
ServiceName: snowflakePrivateLink.AwsVpceId,
VpcEndpointType: "Interface",
SecurityGroupIds: []interface{}{
snowflakePrivateLinkSecurityGroup.Id,
},
SubnetIds: subnetIds,
PrivateDnsEnabled: false,
})
if err != nil {
return err
}
snowflakePrivateLinkRoute53Zone, err := aws.NewRoute53Zone(ctx, "snowflake_private_link", &aws.Route53ZoneArgs{
Name: "privatelink.snowflakecomputing.com",
Vpc: []map[string]interface{}{
map[string]interface{}{
"vpcId": vpcId,
},
},
})
if err != nil {
return err
}
_, err = aws.NewRoute53Record(ctx, "snowflake_private_link_url", &aws.Route53RecordArgs{
ZoneId: snowflakePrivateLinkRoute53Zone.ZoneId,
Name: snowflakePrivateLink.AccountUrl,
Type: "CNAME",
Ttl: "300",
Records: []interface{}{
snowflakePrivateLinkVpcEndpoint.DnsEntry[0].Dns_name,
},
})
if err != nil {
return err
}
_, err = aws.NewRoute53Record(ctx, "snowflake_private_link_ocsp_url", &aws.Route53RecordArgs{
ZoneId: snowflakePrivateLinkRoute53Zone.ZoneId,
Name: snowflakePrivateLink.OcspUrl,
Type: "CNAME",
Ttl: "300",
Records: []interface{}{
snowflakePrivateLinkVpcEndpoint.DnsEntry[0].Dns_name,
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
using Snowflake = Pulumi.Snowflake;
return await Deployment.RunAsync(() =>
{
var snowflakePrivateLink = Snowflake.GetSystemGetPrivateLinkConfig.Invoke();
var snowflakePrivateLinkSecurityGroup = new Aws.Index.SecurityGroup("snowflake_private_link", new()
{
VpcId = vpcId,
Ingress = new[]
{
{
{ "fromPort", 80 },
{ "toPort", 80 },
{ "cidrBlocks", vpcCidr },
{ "protocol", "tcp" },
},
{
{ "fromPort", 443 },
{ "toPort", 443 },
{ "cidrBlocks", vpcCidr },
{ "protocol", "tcp" },
},
},
});
var snowflakePrivateLinkVpcEndpoint = new Aws.Index.VpcEndpoint("snowflake_private_link", new()
{
VpcId = vpcId,
ServiceName = snowflakePrivateLink.Apply(getSystemGetPrivateLinkConfigResult => getSystemGetPrivateLinkConfigResult.AwsVpceId),
VpcEndpointType = "Interface",
SecurityGroupIds = new[]
{
snowflakePrivateLinkSecurityGroup.Id,
},
SubnetIds = subnetIds,
PrivateDnsEnabled = false,
});
var snowflakePrivateLinkRoute53Zone = new Aws.Index.Route53Zone("snowflake_private_link", new()
{
Name = "privatelink.snowflakecomputing.com",
Vpc = new[]
{
{
{ "vpcId", vpcId },
},
},
});
var snowflakePrivateLinkUrl = new Aws.Index.Route53Record("snowflake_private_link_url", new()
{
ZoneId = snowflakePrivateLinkRoute53Zone.ZoneId,
Name = snowflakePrivateLink.Apply(getSystemGetPrivateLinkConfigResult => getSystemGetPrivateLinkConfigResult.AccountUrl),
Type = "CNAME",
Ttl = "300",
Records = new[]
{
snowflakePrivateLinkVpcEndpoint.DnsEntry[0].Dns_name,
},
});
var snowflakePrivateLinkOcspUrl = new Aws.Index.Route53Record("snowflake_private_link_ocsp_url", new()
{
ZoneId = snowflakePrivateLinkRoute53Zone.ZoneId,
Name = snowflakePrivateLink.Apply(getSystemGetPrivateLinkConfigResult => getSystemGetPrivateLinkConfigResult.OcspUrl),
Type = "CNAME",
Ttl = "300",
Records = new[]
{
snowflakePrivateLinkVpcEndpoint.DnsEntry[0].Dns_name,
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.snowflake.SnowflakeFunctions;
import com.pulumi.aws.securityGroup;
import com.pulumi.aws.SecurityGroupArgs;
import com.pulumi.aws.vpcEndpoint;
import com.pulumi.aws.VpcEndpointArgs;
import com.pulumi.aws.route53Zone;
import com.pulumi.aws.Route53ZoneArgs;
import com.pulumi.aws.route53Record;
import com.pulumi.aws.Route53RecordArgs;
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 snowflakePrivateLink = SnowflakeFunctions.getSystemGetPrivateLinkConfig();
var snowflakePrivateLinkSecurityGroup = new SecurityGroup("snowflakePrivateLinkSecurityGroup", SecurityGroupArgs.builder()
.vpcId(vpcId)
.ingress(
%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),
%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.build());
var snowflakePrivateLinkVpcEndpoint = new VpcEndpoint("snowflakePrivateLinkVpcEndpoint", VpcEndpointArgs.builder()
.vpcId(vpcId)
.serviceName(snowflakePrivateLink.applyValue(getSystemGetPrivateLinkConfigResult -> getSystemGetPrivateLinkConfigResult.awsVpceId()))
.vpcEndpointType("Interface")
.securityGroupIds(snowflakePrivateLinkSecurityGroup.id())
.subnetIds(subnetIds)
.privateDnsEnabled(false)
.build());
var snowflakePrivateLinkRoute53Zone = new Route53Zone("snowflakePrivateLinkRoute53Zone", Route53ZoneArgs.builder()
.name("privatelink.snowflakecomputing.com")
.vpc(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
.build());
var snowflakePrivateLinkUrl = new Route53Record("snowflakePrivateLinkUrl", Route53RecordArgs.builder()
.zoneId(snowflakePrivateLinkRoute53Zone.zoneId())
.name(snowflakePrivateLink.applyValue(getSystemGetPrivateLinkConfigResult -> getSystemGetPrivateLinkConfigResult.accountUrl()))
.type("CNAME")
.ttl("300")
.records(snowflakePrivateLinkVpcEndpoint.dnsEntry()[0].dns_name())
.build());
var snowflakePrivateLinkOcspUrl = new Route53Record("snowflakePrivateLinkOcspUrl", Route53RecordArgs.builder()
.zoneId(snowflakePrivateLinkRoute53Zone.zoneId())
.name(snowflakePrivateLink.applyValue(getSystemGetPrivateLinkConfigResult -> getSystemGetPrivateLinkConfigResult.ocspUrl()))
.type("CNAME")
.ttl("300")
.records(snowflakePrivateLinkVpcEndpoint.dnsEntry()[0].dns_name())
.build());
}
}
resources:
snowflakePrivateLinkSecurityGroup:
type: aws:securityGroup
name: snowflake_private_link
properties:
vpcId: ${vpcId}
ingress:
- fromPort: 80
toPort: 80
cidrBlocks: ${vpcCidr}
protocol: tcp
- fromPort: 443
toPort: 443
cidrBlocks: ${vpcCidr}
protocol: tcp
snowflakePrivateLinkVpcEndpoint:
type: aws:vpcEndpoint
name: snowflake_private_link
properties:
vpcId: ${vpcId}
serviceName: ${snowflakePrivateLink.awsVpceId}
vpcEndpointType: Interface
securityGroupIds:
- ${snowflakePrivateLinkSecurityGroup.id}
subnetIds: ${subnetIds}
privateDnsEnabled: false
snowflakePrivateLinkRoute53Zone:
type: aws:route53Zone
name: snowflake_private_link
properties:
name: privatelink.snowflakecomputing.com
vpc:
- vpcId: ${vpcId}
snowflakePrivateLinkUrl:
type: aws:route53Record
name: snowflake_private_link_url
properties:
zoneId: ${snowflakePrivateLinkRoute53Zone.zoneId}
name: ${snowflakePrivateLink.accountUrl}
type: CNAME
ttl: '300'
records:
- ${snowflakePrivateLinkVpcEndpoint.dnsEntry[0].dns_name}
snowflakePrivateLinkOcspUrl:
type: aws:route53Record
name: snowflake_private_link_ocsp_url
properties:
zoneId: ${snowflakePrivateLinkRoute53Zone.zoneId}
name: ${snowflakePrivateLink.ocspUrl}
type: CNAME
ttl: '300'
records:
- ${snowflakePrivateLinkVpcEndpoint.dnsEntry[0].dns_name}
variables:
snowflakePrivateLink:
fn::invoke:
Function: snowflake:getSystemGetPrivateLinkConfig
Arguments: {}
Using getSystemGetPrivateLinkConfig
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 getSystemGetPrivateLinkConfig(opts?: InvokeOptions): Promise<GetSystemGetPrivateLinkConfigResult>
function getSystemGetPrivateLinkConfigOutput(opts?: InvokeOptions): Output<GetSystemGetPrivateLinkConfigResult>
def get_system_get_private_link_config(opts: Optional[InvokeOptions] = None) -> GetSystemGetPrivateLinkConfigResult
def get_system_get_private_link_config_output(opts: Optional[InvokeOptions] = None) -> Output[GetSystemGetPrivateLinkConfigResult]
func GetSystemGetPrivateLinkConfig(ctx *Context, opts ...InvokeOption) (*GetSystemGetPrivateLinkConfigResult, error)
func GetSystemGetPrivateLinkConfigOutput(ctx *Context, opts ...InvokeOption) GetSystemGetPrivateLinkConfigResultOutput
> Note: This function is named GetSystemGetPrivateLinkConfig
in the Go SDK.
public static class GetSystemGetPrivateLinkConfig
{
public static Task<GetSystemGetPrivateLinkConfigResult> InvokeAsync(InvokeOptions? opts = null)
public static Output<GetSystemGetPrivateLinkConfigResult> Invoke(InvokeOptions? opts = null)
}
public static CompletableFuture<GetSystemGetPrivateLinkConfigResult> getSystemGetPrivateLinkConfig(InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: snowflake:index/getSystemGetPrivateLinkConfig:getSystemGetPrivateLinkConfig
arguments:
# arguments dictionary
getSystemGetPrivateLinkConfig Result
The following output properties are available:
- Account
Name string - The name of your Snowflake account.
- Account
Url string - The URL used to connect to Snowflake through AWS PrivateLink or Azure Private Link.
- Aws
Vpce stringId - The AWS VPCE ID for your account.
- Azure
Pls stringId - The Azure Private Link Service ID for your account.
- Id string
- The provider-assigned unique ID for this managed resource.
- Internal
Stage string - The endpoint to connect to your Snowflake internal stage using AWS PrivateLink or Azure Private Link.
- Ocsp
Url string - The OCSP URL corresponding to your Snowflake account that uses AWS PrivateLink or Azure Private Link.
- Regionless
Account stringUrl - The regionless URL to connect to your Snowflake account using AWS PrivateLink, Azure Private Link, or Google Cloud Private Service Connect.
- Regionless
Snowsight stringUrl - The URL for your organization to access Snowsight using Private Connectivity to the Snowflake Service.
- Snowsight
Url string - The URL containing the cloud region to access Snowsight and the Snowflake Marketplace using Private Connectivity to the Snowflake Service.
- Account
Name string - The name of your Snowflake account.
- Account
Url string - The URL used to connect to Snowflake through AWS PrivateLink or Azure Private Link.
- Aws
Vpce stringId - The AWS VPCE ID for your account.
- Azure
Pls stringId - The Azure Private Link Service ID for your account.
- Id string
- The provider-assigned unique ID for this managed resource.
- Internal
Stage string - The endpoint to connect to your Snowflake internal stage using AWS PrivateLink or Azure Private Link.
- Ocsp
Url string - The OCSP URL corresponding to your Snowflake account that uses AWS PrivateLink or Azure Private Link.
- Regionless
Account stringUrl - The regionless URL to connect to your Snowflake account using AWS PrivateLink, Azure Private Link, or Google Cloud Private Service Connect.
- Regionless
Snowsight stringUrl - The URL for your organization to access Snowsight using Private Connectivity to the Snowflake Service.
- Snowsight
Url string - The URL containing the cloud region to access Snowsight and the Snowflake Marketplace using Private Connectivity to the Snowflake Service.
- account
Name String - The name of your Snowflake account.
- account
Url String - The URL used to connect to Snowflake through AWS PrivateLink or Azure Private Link.
- aws
Vpce StringId - The AWS VPCE ID for your account.
- azure
Pls StringId - The Azure Private Link Service ID for your account.
- id String
- The provider-assigned unique ID for this managed resource.
- internal
Stage String - The endpoint to connect to your Snowflake internal stage using AWS PrivateLink or Azure Private Link.
- ocsp
Url String - The OCSP URL corresponding to your Snowflake account that uses AWS PrivateLink or Azure Private Link.
- regionless
Account StringUrl - The regionless URL to connect to your Snowflake account using AWS PrivateLink, Azure Private Link, or Google Cloud Private Service Connect.
- regionless
Snowsight StringUrl - The URL for your organization to access Snowsight using Private Connectivity to the Snowflake Service.
- snowsight
Url String - The URL containing the cloud region to access Snowsight and the Snowflake Marketplace using Private Connectivity to the Snowflake Service.
- account
Name string - The name of your Snowflake account.
- account
Url string - The URL used to connect to Snowflake through AWS PrivateLink or Azure Private Link.
- aws
Vpce stringId - The AWS VPCE ID for your account.
- azure
Pls stringId - The Azure Private Link Service ID for your account.
- id string
- The provider-assigned unique ID for this managed resource.
- internal
Stage string - The endpoint to connect to your Snowflake internal stage using AWS PrivateLink or Azure Private Link.
- ocsp
Url string - The OCSP URL corresponding to your Snowflake account that uses AWS PrivateLink or Azure Private Link.
- regionless
Account stringUrl - The regionless URL to connect to your Snowflake account using AWS PrivateLink, Azure Private Link, or Google Cloud Private Service Connect.
- regionless
Snowsight stringUrl - The URL for your organization to access Snowsight using Private Connectivity to the Snowflake Service.
- snowsight
Url string - The URL containing the cloud region to access Snowsight and the Snowflake Marketplace using Private Connectivity to the Snowflake Service.
- account_
name str - The name of your Snowflake account.
- account_
url str - The URL used to connect to Snowflake through AWS PrivateLink or Azure Private Link.
- aws_
vpce_ strid - The AWS VPCE ID for your account.
- azure_
pls_ strid - The Azure Private Link Service ID for your account.
- id str
- The provider-assigned unique ID for this managed resource.
- internal_
stage str - The endpoint to connect to your Snowflake internal stage using AWS PrivateLink or Azure Private Link.
- ocsp_
url str - The OCSP URL corresponding to your Snowflake account that uses AWS PrivateLink or Azure Private Link.
- regionless_
account_ strurl - The regionless URL to connect to your Snowflake account using AWS PrivateLink, Azure Private Link, or Google Cloud Private Service Connect.
- regionless_
snowsight_ strurl - The URL for your organization to access Snowsight using Private Connectivity to the Snowflake Service.
- snowsight_
url str - The URL containing the cloud region to access Snowsight and the Snowflake Marketplace using Private Connectivity to the Snowflake Service.
- account
Name String - The name of your Snowflake account.
- account
Url String - The URL used to connect to Snowflake through AWS PrivateLink or Azure Private Link.
- aws
Vpce StringId - The AWS VPCE ID for your account.
- azure
Pls StringId - The Azure Private Link Service ID for your account.
- id String
- The provider-assigned unique ID for this managed resource.
- internal
Stage String - The endpoint to connect to your Snowflake internal stage using AWS PrivateLink or Azure Private Link.
- ocsp
Url String - The OCSP URL corresponding to your Snowflake account that uses AWS PrivateLink or Azure Private Link.
- regionless
Account StringUrl - The regionless URL to connect to your Snowflake account using AWS PrivateLink, Azure Private Link, or Google Cloud Private Service Connect.
- regionless
Snowsight StringUrl - The URL for your organization to access Snowsight using Private Connectivity to the Snowflake Service.
- snowsight
Url String - The URL containing the cloud region to access Snowsight and the Snowflake Marketplace using Private Connectivity to the Snowflake Service.
Package Details
- Repository
- Snowflake pulumi/pulumi-snowflake
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
snowflake
Terraform Provider.