Skip to content

Commit 2bfca47

Browse files
authored
Merge pull request #2057 from diggerhq/docs/convert-quickstarts-to-steps
docs: convert quickstart guides to Steps format
2 parents 05d0425 + 43baf17 commit 2bfca47

File tree

3 files changed

+53
-29
lines changed

3 files changed

+53
-29
lines changed

docs/ce/getting-started/with-opentofu.mdx

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,22 @@ title: "With OpenTofu"
44

55
In this tutorial, you will set up Digger to automate OpenTofu pull requests using Github Actions
66

7-
# Prerequisites
8-
7+
**Prerequisites**
98
- A GitHub repository with valid OpenTofu code
109
- Your cloud provider credentials:
1110
- For AWS: [Hashicorp's AWS tutorial](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/aws-build)
1211
- For GCP: [Hashicorp's GCP tutorial](https://developer.hashicorp.com/terraform/tutorials/gcp-get-started/google-cloud-platform-build)
1312
- For Azure: [Hashicorp's Azure tutorial](https://developer.hashicorp.com/terraform/tutorials/azure-get-started/azure-build)
1413

15-
# Step 1: create your Digger account
14+
<Steps>
15+
<Step title="Create your Digger account">
1616

1717
Head to [ui.digger.dev](https://ui.digger.dev) and sign up using your preferred method.
1818

1919
You should see an empty dashboard after you sign up.
20+
</Step>
2021

21-
# Step 2: install the Digger GitHub App
22+
<Step title="Install the Digger GitHub App">
2223

2324
Install the Digger [GitHub App](https://github.com/apps/digger-pro/installations/select_target) into your repository.
2425

@@ -28,8 +29,9 @@ Digger GitHub App does not need access to your cloud account, it just starts job
2829
You can also [self-host Digger orchestrator](/ce/self-host/deploy-docker) with a private GiHub app and issue your own token
2930

3031
</Note>
32+
</Step>
3133

32-
# Step 3: Create Action Secrets with cloud credentials
34+
<Step title="Create Action Secrets with cloud credentials">
3335

3436
In GitHub repository settings, go to Secrets and Variables - Actions. Create the following secrets:
3537

@@ -51,8 +53,9 @@ In GitHub repository settings, go to Secrets and Variables - Actions. Create the
5153
You'll need to configure OIDC authentication by setting up federated credentials in your Azure App Registration. See [Azure OIDC setup](/ce/azure-specific/azure) for details.
5254
</Tab>
5355
</Tabs>
56+
</Step>
5457

55-
# Step 4: Create digger.yml
58+
<Step title="Create digger.yml">
5659

5760
This file contains Digger configuration and needs to be placed at the root level of your repository. Assuming your OpenTofu code is in the `prod` directory:
5861

@@ -61,8 +64,9 @@ projects:
6164
- name: production
6265
dir: prod
6366
```
67+
</Step>
6468

65-
# Step 5: Create Github Actions workflow file
69+
<Step title="Create Github Actions workflow file">
6670

6771
Place it at `.github/workflows/digger_workflow.yml` (name is important!)
6872

@@ -218,16 +222,20 @@ Place it at `.github/workflows/digger_workflow.yml` (name is important!)
218222
- ARM_* environment variables for the Azure Terraform provider
219223
</Tab>
220224
</Tabs>
225+
</Step>
221226

222-
# Step 6: Create a PR to verify that it works
227+
<Step title="Create a PR to verify that it works">
223228

224229
OpenTofu will run an existing plan against your code.
225230

226231
Make any change to your OpenTofu code e.g. add a blank line. An action run should start (you can see log output in Actions). After some time you should see output of OpenTofu Plan added as a comment to your PR.
227232

228233
Then you can add a comment like `digger apply` and shortly after apply output will be added as comment too.
234+
</Step>
235+
236+
</Steps>
229237

230-
# Demo repositories
238+
## Demo repositories
231239

232240
- [AWS demo repo](https://github.com/diggerhq/quickstart-actions-aws)
233241
- [GCP demo repo](https://github.com/diggerhq/demo-conftest-gcp/)

docs/ce/getting-started/with-terraform.mdx

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,22 @@ title: "With Terraform"
44

55
In this tutorial, you will set up Digger to automate terraform pull requests using Github Actions
66

7-
# Prerequisites
8-
7+
**Prerequisites**
98
- A GitHub repository with valid terraform code
109
- Your cloud provider credentials:
1110
- For AWS: [Hashicorp's AWS tutorial](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/aws-build)
1211
- For GCP: [Hashicorp's GCP tutorial](https://developer.hashicorp.com/terraform/tutorials/gcp-get-started/google-cloud-platform-build)
1312
- For Azure: [Hashicorp's Azure tutorial](https://developer.hashicorp.com/terraform/tutorials/azure-get-started/azure-build)
1413

15-
# Step 1: create your Digger account
14+
<Steps>
15+
<Step title="Create your Digger account">
1616

1717
Head to [ui.digger.dev](https://ui.digger.dev) and sign up using your preferred method.
1818

1919
You should see an empty dashboard after you sign up.
20+
</Step>
2021

21-
# Step 2: install the Digger GitHub App
22+
<Step title="Install the Digger GitHub App">
2223

2324
Install the Digger [GitHub App](https://github.com/apps/digger-pro/installations/select_target) into your repository.
2425

@@ -28,8 +29,9 @@ Digger GitHub App does not need access to your cloud account, it just starts job
2829
You can also [self-host Digger orchestrator](/ce/self-host/deploy-docker) with a private GiHub app and issue your own token
2930

3031
</Note>
32+
</Step>
3133

32-
# Step 3: Create Action Secrets with cloud credentials
34+
<Step title="Create Action Secrets with cloud credentials">
3335

3436
In GitHub repository settings, go to Secrets and Variables - Actions. Create the following secrets:
3537

@@ -51,8 +53,9 @@ In GitHub repository settings, go to Secrets and Variables - Actions. Create the
5153
You'll need to configure OIDC authentication by setting up federated credentials in your Azure App Registration. See [Azure OIDC setup](/ce/azure-specific/azure) for details.
5254
</Tab>
5355
</Tabs>
56+
</Step>
5457

55-
# Step 4: Create digger.yml
58+
<Step title="Create digger.yml">
5659

5760
This file contains Digger configuration and needs to be placed at the root level of your repository. Assuming your terraform code is in the `prod` directory:
5861

@@ -61,8 +64,9 @@ projects:
6164
- name: production
6265
dir: prod
6366
```
67+
</Step>
6468

65-
# Step 5: Create Github Actions workflow file
69+
<Step title="Create Github Actions workflow file">
6670

6771
Place it at `.github/workflows/digger_workflow.yml` (name is important!)
6872

@@ -218,16 +222,20 @@ Place it at `.github/workflows/digger_workflow.yml` (name is important!)
218222
- ARM_* environment variables for the Azure Terraform provider
219223
</Tab>
220224
</Tabs>
225+
</Step>
221226

222-
# Step 6: Create a PR to verify that it works
227+
<Step title="Create a PR to verify that it works">
223228

224229
Terraform will run an existing plan against your code.
225230

226231
Make any change to your terraform code e.g. add a blank line. An action run should start (you can see log output in Actions). After some time you should see output of Terraform Plan added as a comment to your PR.
227232

228233
Then you can add a comment like `digger apply` and shortly after apply output will be added as comment too.
234+
</Step>
235+
236+
</Steps>
229237

230-
# Demo repositories
238+
## Demo repositories
231239

232240
- [AWS demo repo](https://github.com/diggerhq/quickstart-actions-aws)
233241
- [GCP demo repo](https://github.com/diggerhq/demo-conftest-gcp/)

docs/ce/getting-started/with-terragrunt.mdx

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,22 @@ title: "With Terragrunt"
44

55
In this tutorial, you will set up Digger to automate Terragrunt pull requests using Github Actions
66

7-
# Prerequisites
8-
7+
**Prerequisites**
98
- A GitHub repository with valid Terragrunt code
109
- Your cloud provider credentials:
1110
- For AWS: [Hashicorp's AWS tutorial](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/aws-build)
1211
- For GCP: [Hashicorp's GCP tutorial](https://developer.hashicorp.com/terraform/tutorials/gcp-get-started/google-cloud-platform-build)
1312
- For Azure: [Hashicorp's Azure tutorial](https://developer.hashicorp.com/terraform/tutorials/azure-get-started/azure-build)
1413

15-
# Step 1: create your Digger account
14+
<Steps>
15+
<Step title="Create your Digger account">
1616

1717
Head to [ui.digger.dev](https://ui.digger.dev) and sign up using your preferred method.
1818

1919
You should see an empty dashboard after you sign up.
20+
</Step>
2021

21-
# Step 2: install the Digger GitHub App
22+
<Step title="Install the Digger GitHub App">
2223

2324
Install the Digger [GitHub App](https://github.com/apps/digger-pro/installations/select_target) into your repository.
2425

@@ -28,8 +29,9 @@ Digger GitHub App does not need access to your cloud account, it just starts job
2829
You can also [self-host Digger orchestrator](/ce/self-host/deploy-docker) with a private GiHub app and issue your own token
2930

3031
</Note>
32+
</Step>
3133

32-
# Step 3: Create Action Secrets with cloud credentials
34+
<Step title="Create Action Secrets with cloud credentials">
3335

3436
In GitHub repository settings, go to Secrets and Variables - Actions. Create the following secrets:
3537

@@ -53,8 +55,9 @@ In GitHub repository settings, go to Secrets and Variables - Actions. Create the
5355
You'll need to configure OIDC authentication by setting up federated credentials in your Azure App Registration. See [Azure OIDC setup](/ce/azure-specific/azure) for details.
5456
</Tab>
5557
</Tabs>
58+
</Step>
5659

57-
# Step 4: Create digger.yml
60+
<Step title="Create digger.yml">
5861

5962
Terragrunt projects can be configured in two ways:
6063

@@ -109,8 +112,9 @@ This approach automatically discovers all Terragrunt modules under each director
109112
<Note>
110113
For more advanced configurations and performance optimization for large monorepos, see [Using Terragrunt](/ce/howto/using-terragrunt) and [Generate Projects](/ce/howto/generate-projects#blocks-syntax-with-terragrunt).
111114
</Note>
115+
</Step>
112116
113-
# Step 5: Create Github Actions workflow file
117+
<Step title="Create Github Actions workflow file">
114118
115119
Place it at `.github/workflows/digger_workflow.yml` (name is important!)
116120

@@ -268,23 +272,27 @@ Place it at `.github/workflows/digger_workflow.yml` (name is important!)
268272
<Note>
269273
Notice that we use `setup-terragrunt: true` instead of `setup-terraform`. Terragrunt will handle the Terraform binary installation internally.
270274
</Note>
275+
</Step>
271276

272-
# Step 6: Create a PR to verify that it works
277+
<Step title="Create a PR to verify that it works">
273278

274279
Terragrunt will run an existing plan against your code.
275280

276281
Make any change to your Terragrunt code e.g. add a blank line. An action run should start (you can see log output in Actions). After some time you should see output of Terragrunt Plan added as a comment to your PR.
277282

278283
Then you can add a comment like `digger apply` and shortly after apply output will be added as comment too.
284+
</Step>
285+
286+
</Steps>
279287

280-
# Demo repositories
288+
## Demo repositories
281289

282290
- [Individual projects demo](https://github.com/diggerhq/demo-terragrunt-gcp)
283291
- [Generated projects demo](https://github.com/diggerhq/test-terragrunt-racecondition)
284292

285-
# Important notes
293+
## Important notes
286294

287-
## SOPS integration
295+
### SOPS integration
288296

289297
If you use `sops_decrypt_file` in your `terragrunt.hcl`, you need to handle the case when Digger generates projects in the backend. Use the `DIGGER_GENERATE_PROJECT` environment variable:
290298

0 commit comments

Comments
 (0)