Skip to content

Commit

Permalink
docs(VpcPeering): improve tutorial to identify correct principals
Browse files Browse the repository at this point in the history
  • Loading branch information
vandjelk committed Jan 30, 2025
1 parent e6e70d9 commit 87ca774
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion docs/user/resources/04-30-10-aws-vpc-peering.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Cloud Manager uses [`AssumeRole`](https://awscli.amazonaws.com/v2/documentation/

Use the following table to identify Cloud Manager principal based on your Kyma landscape:

| BTP cockpit URL | Kyma dashboard URL | Cloud Manager principal ARN |
| BTP cockpit URL | Kyma dashboard URL | Cloud Manager principal |
|------------------------------------|----------------------------------------|--------------------------------------------------------------|
| https://canary.cockpit.btp.int.sap | https://dashboard.stage.kyma.cloud.sap | `arn:aws:iam::194230256199:user/cloud-manager-peering-stage` |
| https://emea.cockpit.btp.cloud.sap | https://dashboard.kyma.cloud.sap | `arn:aws:iam::194230256199:user/cloud-manager-peering-prod` |
Expand Down
6 changes: 3 additions & 3 deletions docs/user/tutorials/01-30-10-aws-vpc-peering.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,18 @@ This tutorial explains how to create a Virtual Private Cloud (VPC) peering conne
export AWS_REGION={REGION}
```

2. Create a trust policy document. See [AwsVpcPeering Custom Resource](../resources/04-30-10-aws-vpc-peering.md?id=authorization) to identify Cloud Manager principal ARN:
2. Create a trust policy document. See [AwsVpcPeering Custom Resource](../resources/04-30-10-aws-vpc-peering.md?id=authorization) to identify Cloud Manager principal:

```shell
export PRINCIPAL_ARN=`arn:aws:iam::194230256199:user/cloud-manager-peering-stage`
export CLOUD_MANAGER_PRINCIPAL=`arn:aws:iam::194230256199:user/cloud-manager-peering-stage`
cat > trust_policy.json <<- EOF
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"AWS": "$PRINCIPAL_ARN"
"AWS": "$CLOUD_MANAGER_PRINCIPAL"
},
"Action": "sts:AssumeRole"
}
Expand Down
4 changes: 2 additions & 2 deletions docs/user/tutorials/01-30-30-azure-vpc-peering.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ This tutorial explains how to create a Virtual Private Cloud (VPC) peering conne
2. Assign the required roles to the Cloud Manager peering service principal. See [AzureVpcPeering Custom Resource](../resources/04-30-30-azure-vpc-peering.md?id=authorization) to identify Cloud Manager service principal:
```shell
export SUBSCRIPTION_ID=$(az account show --query id -o tsv)
export PRINCIPAL_NAME={PRINCIPAL_NAME}
export OBJECT_ID=$(az ad sp list --display-name $PRINCIPAL_NAME --query "[].id" -o tsv)
export CLOUD_MANAGER_PRINCIPAL={CLOUD_MANAGER_PRINCIPAL}
export OBJECT_ID=$(az ad sp list --display-name $CLOUD_MANAGER_PRINCIPAL --query "[].id" -o tsv)
az role assignment create --assignee $OBJECT_ID \
--role "Network Contributor" \
Expand Down

0 comments on commit 87ca774

Please sign in to comment.