Skip to content

Commit 5e76043

Browse files
author
Felix Zieger
committed
docs: cloud shell instructions
1 parent 096307c commit 5e76043

File tree

1 file changed

+46
-21
lines changed

1 file changed

+46
-21
lines changed

README.md

Lines changed: 46 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,59 @@ Terraform module to integrate Azure as a meshPlatform into meshStack instance.
44

55
With this module, service principals used by meshStack are created with the required permissions.
66

7-
# Prerequisites
7+
## Prerequisites
8+
89
Permissions on AAD level are needed to run this module.
910
Tenant wide admin consent must be granted for a succesful meshPlatform setup. Therefore to integrate a meshPlatform you need:
1011

1112
> An Azure account with one of the following roles: Global Administrator, Privileged Role Administrator, Cloud Application Administrator, or Application Administrator. A user can also be authorized to grant tenant-wide consent if they are assigned a custom directory role that includes the permission to grant permissions to applications.[^1]
1213
1314
[^1]: See [Azure public documentation](https://docs.microsoft.com/en-us/azure/active-directory/manage-apps/grant-admin-consent#prerequisites)
1415

15-
# Usage
16+
## How to use this module
17+
18+
1. Login into [Azure Portal](https://portal.azure.com/) with your Admin user.
19+
20+
2. Open a cloud shell.
21+
22+
3. Create a directory and change into it
23+
24+
```sh
25+
mkdir terraform-azure-meshplatform
26+
cd terraform-azure-meshplatform
27+
```
28+
29+
4. Create a `main.tf` file that references this module:
30+
31+
```sh
32+
cat > ~/terraform-azure-meshplatform/main.tf << EOF
33+
module "meshplatform" {
34+
source = "git@github.com:meshcloud/terraform-azure-meshplatform.git"
35+
36+
spp_name_suffix = "unique-name"
37+
mgmt_group_name = "management-group-name"
38+
}
39+
EOF
40+
```
41+
42+
5. Run
43+
44+
```sh
45+
terraform init
46+
terraform apply
47+
```
48+
49+
6. Access terraform output and pass it securely to meshcloud.
50+
51+
```sh
52+
# The JSON output contains sensitive values that must not be transmitted to meshcloud in plain text.
53+
terraform output -json
54+
```
55+
56+
## Advanced Usage
57+
58+
The default case creates kraken, replicator and idplookup service principals.
59+
1660
```hcl
1761
module "meshplatform" {
1862
source = "git@github.com:meshcloud/terraform-azure-meshplatform.git"
@@ -21,11 +65,9 @@ module "meshplatform" {
2165
mgmt_group_name = "management-group-name"
2266
}
2367
```
24-
This will create kraken, replicator and idplookup service principals.
2568
2669
If UAMI blueprint user principal is required, you also need to pass a list of subscriptions this user will be assigned to.
2770
28-
example:
2971
```hcl
3072
module "meshplatform" {
3173
source = "git@github.com:meshcloud/terraform-azure-meshplatform.git"
@@ -40,20 +82,3 @@ module "meshplatform" {
4082
]
4183
}
4284
```
43-
44-
By default, kraken, replicator, and idplookup service principals are enabled and will be created. To disable a service principal, set its according flag to `false`.
45-
46-
e.g.:
47-
48-
```hcl
49-
module "meshplatform" {
50-
source = "git@github.com:meshcloud/terraform-azure-meshplatform.git"
51-
52-
spp_name_suffix = "unique-name"
53-
mgmt_group_name = "management-group-name"
54-
55-
replicator_enabled = false
56-
kraken_enabled = false
57-
idplookup_enabled = false
58-
}
59-
```

0 commit comments

Comments
 (0)