Skip to content

Commit

Permalink
docs: Update placeholder value in ALZ module code creation (#203)
Browse files Browse the repository at this point in the history
# Pull Request

## Description

This pull request includes several documentation updates to clarify the
usage of configuration file paths and default directory values. The most
important changes involve adding instructions for escaping backslashes
in YAML file paths on Windows and specifying how to handle default
directory values.

Clarifications in documentation:

* `docs/wiki/[User-Guide]-Quick-Start-Phase-2-Local.md`: Updated the
description for the `target_directory` input to specify that the
placeholder value `<target-directory>` should be removed to use the
default value.
([docs/wiki/[User-Guide]-Quick-Start-Phase-2-Local.mdL45-R45](diffhunk://#diff-f86bb4f6ce154adfd0bf07c039be16f163e0e081779c957de4826e664e2792d0L45-R45),
[docs/wiki/[User-Guide]-Quick-Start-Phase-2-Local.mdL113-R113](diffhunk://#diff-f86bb4f6ce154adfd0bf07c039be16f163e0e081779c957de4826e664e2792d0L113-R113))

*
`docs/wiki/[User-Guide]-Starter-Module-Terraform-Complete-Multi-Region.md`:
Added a note that backslashes need to be escaped in YAML file paths on
Windows.
([docs/wiki/[User-Guide]-Starter-Module-Terraform-Complete-Multi-Region.mdL18-R18](diffhunk://#diff-edeec51894dbd58453488f2badb0e44737d2aa7e16be2dd6fe71cd211149db69L18-R18))

* `docs/wiki/[User-Guide]-Starter-Module-Terraform-Complete-VNext.md`:
Added a note that backslashes need to be escaped in YAML file paths on
Windows.
([docs/wiki/[User-Guide]-Starter-Module-Terraform-Complete-VNext.mdL19-R19](diffhunk://#diff-94372c563fe90e45582ccdb428559491398b4e10af345feeebdbe737633c417bL19-R19))

* `docs/wiki/[User-Guide]-Starter-Module-Terraform-Complete.md`: Added a
note that backslashes need to be escaped in YAML file paths on Windows.
([docs/wiki/[User-Guide]-Starter-Module-Terraform-Complete.mdL17-R17](diffhunk://#diff-c95238aa2c2777c9c78aaf4534391f3195707d10f6edf94a1defa573a10d017aL17-R17))

## License

By submitting this pull request, I confirm that my contribution is made
under the terms of the projects associated license.

---------

Co-authored-by: Jared Holgate <[email protected]>
  • Loading branch information
Springstone and jaredfholgate authored Oct 2, 2024
1 parent 4f25ad4 commit 1f302b9
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 20 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/wiki-sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ permissions:
# yamllint disable-line rule:truthy
on:
release:
types: [published]
types: [published, released]
workflow_dispatch:

env:
Expand Down
16 changes: 6 additions & 10 deletions docs/wiki/[User-Guide]-Quick-Start-Phase-2-Local.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,17 @@ Although you can just run `Deploy-Accelerator` and fill out the prompted inputs,
# Windows
New-Item -ItemType "file" c:\accelerator\config\inputs.yaml -Force
New-Item -ItemType "directory" c:\accelerator\output
New-Item -ItemType "directory" c:\accelerator\target
# Linux/Mac
New-Item -ItemType "file" /accelerator/config/inputs.yaml -Force
New-Item -ItemType "directory" /accelerator/output
New-Item -ItemType "directory" /accelerator/target
```

```plaintext
📂accelerator
┣ 📂config
┃ ┗ 📜inputs.yaml
┃ 📂output
┗ 📂target
┗ 📂output
```

1. Open your `inputs.yaml` file in Visual Studio Code (or your preferred editor) and copy the content from [inputs-local-bicep-complete.yaml][example_powershell_inputs_local_bicep_complete] into that file.
Expand All @@ -47,7 +44,7 @@ Although you can just run `Deploy-Accelerator` and fill out the prompted inputs,
| `subscription_id_management` | `TF_VAR` | `<management-subscription-id>` | Replace `<management-subscription-id>` with the id of the management subscription you created in the previous phase. |
| `subscription_id_identity` | `TF_VAR` | `<identity-subscription-id>` | Replace `<identity-subscription-id>` with the id of the identity subscription you created in the previous phase. |
| `subscription_id_connectivity` | `TF_VAR` | `<connectivity-subscription-id>` | Replace `<connectivity-subscription-id>` with the id of the connectivity subscription you created in the previous phase. |
| `target_directory` | `TF_VAR` | `/accelerator/target` | This is the directory where the ALZ module code will be created. This defaults a directory called `local-output` in the root of the accelerator output directory if not supplied. |
| `target_directory` | `TF_VAR` | `""` | This is the directory where the ALZ module code will be created. This defaults a directory called `local-output` in the root of the accelerator output directory if not supplied. |
| `create_bootstrap_resources_in_azure` | `TF_VAR` | `true` | This determines whether the bootstrap will create the bootstrap resources in Azure. This defaults to `true`. |
| `bootstrap_subscription_id` | `TF_VAR` | `""` | Enter the id of the subscription in which you would like to deploy the bootstrap resources in Azure. If left blank, the subscription you are connected to via `az login` will be used. In most cases this is the management subscription, but you can specifiy a separate subscription if you prefer. |
| `service_name` | `TF_VAR` | `alz` | This is used to build up the names of your Azure and Azure DevOps resources, for example `rg-<service_name>-mgmt-uksouth-001`. We recommend using `alz` for this. |
Expand All @@ -71,6 +68,7 @@ Although you can just run `Deploy-Accelerator` and fill out the prompted inputs,
1. There will be a pause after the `plan` phase you allow you to validate what is going to be deployed.
1. If you are happy with the plan, then type `yes` and hit enter.
1. The Terraform will `apply` and your environment will be bootstrapped.
1. You will find the output in the `/accelerator/output/local-output` folder if you didn't specifiy a different location for `target_directory`.

### 2.2.3.2 Local File System with Terraform

Expand All @@ -82,20 +80,17 @@ Although you can just run `Deploy-Accelerator` and fill out the prompted inputs,
# Windows
New-Item -ItemType "file" c:\accelerator\config\inputs.yaml -Force
New-Item -ItemType "directory" c:\accelerator\output
New-Item -ItemType "directory" c:\accelerator\target
# Linux/Mac
New-Item -ItemType "file" /accelerator/config/inputs.yaml -Force
New-Item -ItemType "directory" /accelerator/output
New-Item -ItemType "directory" /accelerator/target
```

```plaintext
📂accelerator
┣ 📂config
┃ ┗ 📜inputs.yaml
┃ 📂output
┗ 📂target
┗ 📂output
```

1. Open your `inputs.yaml` file in Visual Studio Code (or your preferred editor) and copy the content from the relevant input file for your chosen starter module:
Expand All @@ -118,7 +113,7 @@ Although you can just run `Deploy-Accelerator` and fill out the prompted inputs,
| `subscription_id_management` | `TF_VAR` | `<management-subscription-id>` | Replace `<management-subscription-id>` with the id of the management subscription you created in the previous phase. |
| `subscription_id_identity` | `TF_VAR` | `<identity-subscription-id>` | Replace `<identity-subscription-id>` with the id of the identity subscription you created in the previous phase. |
| `subscription_id_connectivity` | `TF_VAR` | `<connectivity-subscription-id>` | Replace `<connectivity-subscription-id>` with the id of the connectivity subscription you created in the previous phase. |
| `target_directory` | `TF_VAR` | `/accelerator/target` | This is the directory where the ALZ module code will be created. This defaults a directory called `local-output` in the root of the accelerator output directory if not supplied. |
| `target_directory` | `TF_VAR` | `""` | This is the directory where the ALZ module code will be created. This defaults a directory called `local-output` in the root of the accelerator output directory if not supplied. |
| `create_bootstrap_resources_in_azure` | `TF_VAR` | `true` | This determines whether the bootstrap will create the bootstrap resources in Azure. This defaults to `true`. |
| `bootstrap_subscription_id` | `TF_VAR` | `""` | Enter the id of the subscription in which you would like to deploy the bootstrap resources in Azure. If left blank, the subscription you are connected to via `az login` will be used. In most cases this is the management subscription, but you can specifiy a separate subscription if you prefer. |
| `service_name` | `TF_VAR` | `alz` | This is used to build up the names of your Azure and Azure DevOps resources, for example `rg-<service_name>-mgmt-uksouth-001`. We recommend using `alz` for this. |
Expand Down Expand Up @@ -146,6 +141,7 @@ Although you can just run `Deploy-Accelerator` and fill out the prompted inputs,
1. There will be a pause after the `plan` phase you allow you to validate what is going to be deployed.
1. If you are happy with the plan, then type `yes` and hit enter.
1. The Terraform will `apply` and your environment will be bootstrapped.
1. You will find the output in the `/accelerator/output/local-output` folder if you didn't specifiy a different location for `target_directory`.

## Next Steps

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The following table describes the inputs required for the `complete_multi_region

| Input | Placeholder | Description |
| - | -- | --- |
| `configuration_file_path` | `<configuration-file-path>` | This is the absolute path to the configuration file. E.g. `c:\my-config\config.yaml` or `~/my-config/config.yaml` |
| `configuration_file_path` | `<configuration-file-path>` | This is the absolute path to the configuration file. E.g. `c:\my-config\config.yaml` or `~/my-config/config.yaml`. For YAML on Windows you will need to escape the `\`, i.e. `c:\\my-config\\config.yaml`. |
| `default_postfix` | `<postfix>` | This is the default postfix used for resource names. |

You can create a custom yaml config to tailor to your needs, for example an Azure Landing Zone with a three-region mesh. Get started with our two region samples:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ The following table describes the inputs required for the `complete_vnext` start

| Input | Placeholder | Description |
| - | -- | --- |
| `configuration_file_path` | `<configuration-file-path>` | This is the absolute path to the configuration file. E.g. `c:\my-config\config.yaml` or `~/my-config/config.yaml` |
| `configuration_file_path` | `<configuration-file-path>` | This is the absolute path to the configuration file. E.g. `c:\my-config\config.yaml` or `~/my-config/config.yaml`. For YAML on Windows you will need to escape the `\`, i.e. `c:\\my-config\\config.yaml`. |
| `default_postfix` | `<postfix>` | This is the default postfix used for resource names. |

## Further details on the Complete Starter Module and config file
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ The following table describes the inputs required for the `complete` starter mod

| Input | Placeholder | Description |
| - | -- | --- |
| `configuration_file_path` | `<configuration-file-path>` | This is the absolute path to the configuration file. E.g. `c:\my-config\config.yaml` or `~/my-config/config.yaml` |
| `configuration_file_path` | `<configuration-file-path>` | This is the absolute path to the configuration file. E.g. `c:\my-config\config.yaml` or `~/my-config/config.yaml`. For YAML on Windows you will need to escape the `\`, i.e. `c:\\my-config\\config.yaml`. |
| `default_postfix` | `<postfix>` | This is the default postfix used for resource names. |

## Further details on the Complete Starter Module and config file
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subscription_id_identity: "<identity-subscription-id>"
subscription_id_connectivity: "<connectivity-subscription-id>"

# Bootstrap Inputs
target_directory: "/accelerator/target"
target_directory: ""
create_bootstrap_resources_in_azure: "true"
bootstrap_subscription_id: ""
service_name: "alz"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subscription_id_identity: "<identity-subscription-id>"
subscription_id_connectivity: "<connectivity-subscription-id>"

# Bootstrap Inputs
target_directory: "/accelerator/target"
target_directory: ""
create_bootstrap_resources_in_azure: true
bootstrap_subscription_id: ""
service_name: "alz"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subscription_id_identity: "<identity-subscription-id>"
subscription_id_connectivity: "<connectivity-subscription-id>"

# Bootstrap Inputs
target_directory: "/accelerator/target"
target_directory: ""
create_bootstrap_resources_in_azure: true
bootstrap_subscription_id: ""
service_name: "alz"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subscription_id_identity: "<identity-subscription-id>"
subscription_id_connectivity: "<connectivity-subscription-id>"

# Bootstrap Inputs
target_directory: "/accelerator/target"
target_directory: ""
create_bootstrap_resources_in_azure: true
bootstrap_subscription_id: ""
service_name: "alz"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subscription_id_identity: "<identity-subscription-id>"
subscription_id_connectivity: "<connectivity-subscription-id>"

# Bootstrap Inputs
target_directory: "/accelerator/target"
target_directory: ""
create_bootstrap_resources_in_azure: true
bootstrap_subscription_id: ""
service_name: "alz"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ subscription_id_identity: "<identity-subscription-id>"
subscription_id_connectivity: "<connectivity-subscription-id>"

# Bootstrap Inputs
target_directory: "/accelerator/target"
target_directory: ""
create_bootstrap_resources_in_azure: true
bootstrap_subscription_id: ""
service_name: "alz"
Expand Down

0 comments on commit 1f302b9

Please sign in to comment.