Skip to content

Commit 785a432

Browse files
authored
Merge pull request #3925 from ClickHouse/vpc-resource-doc
Add docs for AWS PrivateLink using VPC Resource
2 parents 97a6da2 + ac19421 commit 785a432

File tree

1 file changed

+80
-10
lines changed

1 file changed

+80
-10
lines changed

docs/integrations/data-ingestion/clickpipes/aws-privatelink.md

Lines changed: 80 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -32,26 +32,96 @@ ClickPipes reverse private endpoint can be configured with one of the following
3232
- [MSK multi-VPC connectivity for MSK ClickPipe](https://docs.aws.amazon.com/msk/latest/developerguide/aws-access-mult-vpc.html)
3333
- [VPC endpoint service](https://docs.aws.amazon.com/vpc/latest/privatelink/privatelink-share-your-services.html)
3434

35-
Follow the links above for detailed instructions on how to set up the respective AWS PrivateLink shares.
36-
3735
### VPC resource {#vpc-resource}
3836

39-
Your VPC resources can be accessed in ClickPipes using PrivateLink.
37+
Your VPC resources can be accessed in ClickPipes using PrivateLink and [AWS VPC Lattice](https://docs.aws.amazon.com/vpc-lattice/latest/ug/what-is-vpc-lattice.html). This approach doesn't require setting up a load balancer in front of your data source.
38+
4039
Resource configuration can be targeted with a specific host or RDS cluster ARN.
4140
Cross-region is not supported.
4241

4342
It's the preferred choice for Postgres CDC ingesting data from an RDS cluster.
4443

45-
See a [getting started](https://docs.aws.amazon.com/vpc/latest/privatelink/resource-configuration.html) guide for more details.
44+
To set up PrivateLink with VPC resource:
45+
1. Create a resource gateway
46+
2. Create a resource configuration
47+
3. Create a resource share
4648

47-
:::info
48-
VPC resource needs to be shared with a ClickPipes account. Add `072088201116` to the allowed principals to your resource share configuration.
49-
See AWS guide for [sharing resources](https://docs.aws.amazon.com/ram/latest/userguide/working-with-sharing-create.html) for more details.
50-
:::
49+
#### 1. Create a Resource-Gateway {#create-resource-gateway}
50+
51+
Resource-Gateway is the point that receives traffic for specified resources in your VPC.
52+
53+
You can create a Resource-Gateway from the [AWS console](https://docs.aws.amazon.com/vpc/latest/privatelink/create-resource-gateway.html) or with the following command:
54+
55+
```bash
56+
aws vpc-lattice create-resource-gateway \
57+
--vpc-identifier <VPC_ID> \
58+
--subnet-ids <SUBNET_IDS> \
59+
--security-group-ids <SG_IDs> \
60+
--name <RESOURCE_GATEWAY_NAME>
61+
```
62+
63+
The output will contain a Resource-Gateway id, which you will need for the next step.
64+
65+
Before you can proceed, you'll need to wait for the Resource-Gateway to enter into an `Active` state. You can check the state by running the following command:
66+
67+
```bash
68+
aws vpc-lattice get-resource-gateway \
69+
--resource-gateway-identifier <RESOURCE_GATEWAY_ID>
70+
```
71+
72+
#### 2. Create a VPC Resource-Configuration {#create-resource-configuration}
73+
74+
Resource-Configuration is associated with Resource-Gateway to make your resource accessible.
75+
76+
You can create a Resource-Configuration from the [AWS console](https://docs.aws.amazon.com/vpc/latest/privatelink/create-resource-configuration.html) or with the following command:
77+
78+
```bash
79+
aws vpc-lattice create-resource-configuration \
80+
--resource-gateway-identifier <RESOURCE_GATEWAY_ID> \
81+
--type <RESOURCE_CONFIGURATION_TYPE> \
82+
--resource-configuration-definition <RESOURCE_CONFIGURATION_DEFINITION> \
83+
--name <RESOURCE_CONFIGURATION_NAME>
84+
```
85+
86+
The simplest [resource configuration type](https://docs.aws.amazon.com/vpc-lattice/latest/ug/resource-configuration.html#resource-configuration-types) is a single Resource-Configuration. You can configure with the ARN directly, or share an IP address or a domain name that is publicly resolvable.
87+
88+
For example, to configure with the ARN of an RDS Cluster:
89+
90+
```bash
91+
aws vpc-lattice create-resource-configuration \
92+
--name my-rds-cluster-config \
93+
--type ARN \
94+
--resource-gateway-identifier rgw-0bba03f3d56060135 \
95+
--resource-configuration-definition 'arnResource={arn=arn:aws:rds:us-east-1:123456789012:cluster:my-rds-cluster}'
96+
```
97+
98+
The output will contain a Resource-Configuration ARN, which you will need for the next step. It will also contain a Resource-Configuration ID, which you will need to set up a ClickPipe connection with VPC resource.
99+
100+
#### 3. Create a Resource-Share {#create-resource-share}
101+
102+
Sharing your resource requires a Resource-Share. This is facilitated through the Resource Access Manager (RAM).
103+
104+
You can put the Resource-Configuration into the Resource-Share through [AWS console](https://docs.aws.amazon.com/ram/latest/userguide/working-with-sharing-create.html) or by running the following command with ClickPipes account ID `072088201116`:
105+
106+
```bash
107+
aws ram create-resource-share \
108+
--principals 072088201116 \
109+
--resource-arns <RESOURCE_CONFIGURATION_ARN> \
110+
--name <RESOURCE_SHARE_NAME>
111+
```
112+
113+
The output will contain a Resource-Share ARN, which you will need to set up a ClickPipe connection with VPC resource.
114+
115+
You are ready to [create a ClickPipe with Reverse private endpoint](#creating-clickpipe) using VPC resource. You will need to:
116+
- Set `VPC endpoint type` to `VPC Resource`.
117+
- Set `Resource configuration ID` to the ID of the Resource-Configuration created in step 2.
118+
- Set `Resource share ARN` to the ARN of the Resource-Share created in step 3.
119+
120+
For more details on PrivateLink with VPC resource, see [AWS documentation](https://docs.aws.amazon.com/vpc/latest/privatelink/privatelink-access-resources.html).
51121

52122
### MSK multi-VPC connectivity {#msk-multi-vpc}
53123

54-
The MSK multi-VPC is a built-in feature of AWS MSK that allows you to connect multiple VPCs to a single MSK cluster.
124+
The [Multi-VPC connectivity](https://docs.aws.amazon.com/msk/latest/developerguide/aws-access-mult-vpc.html) is a built-in feature of AWS MSK that allows you to connect multiple VPCs to a single MSK cluster.
55125
Private DNS support is out of the box and does not require any additional configuration.
56126
Cross-region is not supported.
57127

@@ -67,7 +137,7 @@ Follow our [MSK setup guide for ClickPipes](/knowledgebase/aws-privatelink-setup
67137

68138
### VPC endpoint service {#vpc-endpoint-service}
69139

70-
VPC service is another approach to share your data source with ClickPipes.
140+
[VPC endpoint service](https://docs.aws.amazon.com/vpc/latest/privatelink/privatelink-share-your-services.html) is another approach to share your data source with ClickPipes.
71141
It requires setting up a NLB (Network Load Balancer) in front of your data source
72142
and configuring the VPC endpoint service to use the NLB.
73143

0 commit comments

Comments
 (0)