Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix: adjust Docusaurus config for v3
  • Loading branch information
arnaudlh committed Mar 2, 2025
commit d277192956daf65ca81ad9c1d12e18bc6d9c37f8
10 changes: 5 additions & 5 deletions website/blog/2019-05-28-first-blog-post.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
---
slug: first-blog-post
title: First Blog Post
authors:
name: Gao Wei
title: Docusaurus Core Team
url: https://github.com/wgao19
image_url: https://github.com/wgao19.png
authors: wgao19
tags: [hola, docusaurus]
---

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque elementum dignissim ultricies. Fusce rhoncus ipsum tempor eros aliquam consequat. Lorem ipsum dolor sit amet

<!-- truncate -->

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque elementum dignissim ultricies. Fusce rhoncus ipsum tempor eros aliquam consequat. Lorem ipsum dolor sit amet
2 changes: 2 additions & 0 deletions website/blog/2021-08-01-mdx-blog-post.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ tags: [docusaurus]

Blog posts support [Docusaurus Markdown features](https://docusaurus.io/docs/markdown-features), such as [MDX](https://mdxjs.com/).

{/* truncate */}

:::tip

Use the power of React to create interactive blog posts.
Expand Down
2 changes: 2 additions & 0 deletions website/blog/2021-08-26-welcome/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ tags: [facebook, hello, docusaurus]

Simply add Markdown files (or folders) to the `blog` directory.

<!-- truncate -->

Regular blog authors can be added to `authors.yml`.

The blog post date can be extracted from filenames, such as:
Expand Down
6 changes: 6 additions & 0 deletions website/blog/authors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,9 @@ slorber:
title: Docusaurus maintainer
url: https://sebastienlorber.com
image_url: https://github.com/slorber.png

wgao19:
name: Gao Wei
title: Docusaurus Core Team
url: https://github.com/wgao19
image_url: https://github.com/wgao19.png
34 changes: 30 additions & 4 deletions website/docs/rover/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ rover \
-launchpad \
-env contoso \
-level level0 \
-p ${TF_DATA_DIR}/caf_launchpad.tfstate.tfplan \
-p "$TF_DATA_DIR/caf_launchpad.tfstate.tfplan" \
-a plan
```

Expand All @@ -68,14 +68,40 @@ The following table summarizes the most common parameters and their default valu
| -tfstate_subscription_id | no | If no value specified, rover is assuming the currently logged-in subscription from az cli context. | GUID of the subscription containing the tfstate (launchpad). This will be used to locate and store the tfstate files. | ```a-b-c-d-e ``` |
| -target_subscription | no | If no value specified, rover is assuming the currently logged-in subscription from az cli context. | GUID of the subscription where to deploy the resources. | ```a-b-c-d-e``` |
| -workspace | no | ```tfstate``` | Specifies the storage account container where to store the tfstate for this landing zone. This could be used to isolate landing zones from each others by specifying Azure AD RBAC entries on the specific container withing the storage account. | ```my_container``` |
| -p | no | N/A | Specifies the location where to store the plan file, if not specified a plan file will be automatically created for you when you specify ```-a apply ``` and will be stored ```in ${TF_DATA_DIR}``` | ${TF_DATA_DIR}/caf_launchpad.tfstate.tfplan |
| -p | no | N/A | Specifies the location where to store the plan file, if not specified a plan file will be automatically created for you when you specify ```-a apply ``` and will be stored in the TF_DATA_DIR directory | ```"$TF_DATA_DIR/caf_launchpad.tfstate.tfplan"``` |
| -launchpad | no | N/A | Flag that indicates that the current deployment is a launchpad. | ```-launchpad ``` |
| -tfc | no | N/A | Flag that indicates that the current deployment will use the TFC configured settings to store the state (refer to the Use TFC section of this guide) | ```-tfc ``` |
| -skip-permission-check | no | N/A | Flag to skip the check that the currently logged-in principal is owner of the target subscription (only checked for launchpad) | ```-skip-permission-check ``` |
| -skip-permission-check | no | N/A | Flag to skip the check that the currently logged-in principal is owner of the target subscription (only checked for launchpad) | ```-skip-permission-check ``` |
| -impersonate-sp-from-keyvault-url | no | N/A | Flag that indicates rover to use impersonate the Service Principal and use the credentials stored in the Azure Key Vault which URL is specified as parameter. Requires launchpad_credentials landing zone to be setup (more details to be published soon.) | ```-impersonate-sp-from-keyvault-url https://myakv.vault.azure.net/```|
| init | no | N/A | Initialize developer remote state management in azurerm | ```init -env name -location southeastasia```|
| init --clean | no | N/A | Delete the initialized remote state management in azurerm | ```init --clean -env name -location southeastasia ``` |

## Examples of using the -p parameter

### Planning with a specific plan file
```bash
rover \
-lz /tf/caf/landingzones/caf_launchpad \
-var-folder /tf/caf/configuration/contoso/platform/level0/launchpad \
-tfstate caf_launchpad.tfstate \
-env contoso \
-level level0 \
-p "$TF_DATA_DIR/my_custom_plan.tfplan" \
-a plan
```

### Applying a previously created plan file
```bash
rover \
-lz /tf/caf/landingzones/caf_launchpad \
-var-folder /tf/caf/configuration/contoso/platform/level0/launchpad \
-tfstate caf_launchpad.tfstate \
-env contoso \
-level level0 \
-p "$TF_DATA_DIR/my_custom_plan.tfplan" \
-a apply
```

## Examples

### untaint
Expand Down Expand Up @@ -113,7 +139,7 @@ rover \
-env contoso \
-level level3 \
-w data-landing-zone-prod `\
-p ${TF_DATA_DIR}/data-landing-zone_prod_level3.tfstate.tfplan \
-p "$TF_DATA_DIR/data-landing-zone_prod_level3.tfstate.tfplan" \
-a untaint "module.solution.module.storage_containers[\"storageWorkspace_di001\"].azurerm_storage_container.stg"
```

Expand Down
22 changes: 12 additions & 10 deletions website/docusaurus.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
// @ts-check
// Note: type annotations allow type checking and IDEs autocompletion

const lightCodeTheme = require('prism-react-renderer/themes/github');
const darkCodeTheme = require('prism-react-renderer/themes/dracula');

/** @type {import('@docusaurus/types').Config} */
const config = {
title: 'Azure Terraform SRE',
Expand All @@ -15,7 +12,6 @@ const config = {
favicon: 'img/landingzones.ico',
organizationName: 'aztfmod', // Usually your GitHub org/user name.
projectName: 'documentation', // Usually your repo name.

presets: [
[
'classic',
Expand Down Expand Up @@ -45,10 +41,20 @@ const config = {
}),
],
],

themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
// Updated: Replaced themes from prism-react-renderer with new syntax for v3
prism: {
theme: {
plain: {},
styles: []
},
darkTheme: {
plain: {},
styles: []
},
},
navbar: {
title: 'Azure Terraform SRE',
logo: {
Expand Down Expand Up @@ -145,11 +151,7 @@ const config = {
],
copyright: `Copyright © ${new Date().getFullYear()} Azure Terraform SRE`,
},
prism: {
theme: darkCodeTheme,
darkTheme: darkCodeTheme,
},
})
}),
};

module.exports = config;
28 changes: 14 additions & 14 deletions website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,23 +69,23 @@
"@colors/colors": "1.5.0",
"@docsearch/css": "3.1.0",
"@docsearch/react": "3.1.0",
"@docusaurus/core": "^2.4.3",
"@docusaurus/cssnano-preset": "^2.4.3",
"@docusaurus/module-type-aliases": "^2.4.3",
"@docusaurus/plugin-debug": "^2.4.3",
"@docusaurus/plugin-google-analytics": "^2.4.3",
"@docusaurus/plugin-google-gtag": "^2.4.3",
"@docusaurus/plugin-sitemap": "^2.4.3",
"@docusaurus/preset-classic": "^2.4.3",
"@docusaurus/theme-classic": "^2.4.3",
"@docusaurus/theme-search-algolia": "^2.4.3",
"@docusaurus/types": "^2.4.3",
"@docusaurus/core": "^3.7.0",
"@docusaurus/cssnano-preset": "^3.7.0",
"@docusaurus/module-type-aliases": "^3.7.0",
"@docusaurus/plugin-debug": "^3.7.0",
"@docusaurus/plugin-google-analytics": "^3.7.0",
"@docusaurus/plugin-google-gtag": "^3.7.0",
"@docusaurus/plugin-sitemap": "^3.7.0",
"@docusaurus/preset-classic": "^3.7.0",
"@docusaurus/theme-classic": "^3.7.0",
"@docusaurus/theme-search-algolia": "^3.7.0",
"@docusaurus/types": "^3.7.0",
"@jridgewell/gen-mapping": "0.3.2",
"@jridgewell/resolve-uri": "3.0.8",
"@jridgewell/set-array": "1.1.2",
"@leichtgewicht/ip-codec": "2.0.5",
"@mdx-js/mdx": "1.6.22",
"@mdx-js/react": "^1.6.21",
"@mdx-js/react": "^2.0.0",
"@slorber/static-site-generator-webpack-plugin": "4.0.7",
"@svgr/core": "6.2.1",
"@svgr/hast-util-to-babel-ast": "6.2.1",
Expand Down Expand Up @@ -175,9 +175,9 @@
"prism-react-renderer": "^1.2.1",
"prismjs": "1.28.0",
"raw-body": "2.5.1",
"react": "^17.0.1",
"react": "^18.0.0",
"react-dev-utils": "12.0.1",
"react-dom": "^17.0.1",
"react-dom": "^18.0.0",
"react-error-overlay": "6.0.11",
"react-player": "^2.9.0",
"react-router": "5.3.3",
Expand Down
10 changes: 6 additions & 4 deletions website/versioned_docs/version-2203.1/rover/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ rover \
-launchpad \
-env contoso \
-level level0 \
-p ${TF_DATA_DIR}/caf_launchpad.tfstate.tfplan \
-p "$TF_DATA_DIR/caf_launchpad.tfstate.tfplan" \
-a plan
```

Expand All @@ -63,14 +63,14 @@ The following table summarizes the most common parameters and their default valu
| -env | yes | N/A | String that defines a name for an environment to use. This is defined as (used in the state locator function as described below.) | ```contoso``` |
| -level | yes | N/A | Specifies the level in the CAF hierarchy where to deploy the resources (possible value are level1-level4) | ```level1``` |
| -a | yes | N/A | Action to take with the current parameters, possible values are ```plan```, ```apply```, ```destroy```, ```validate```, ```refresh```, ```graph```, ```import```, ```output```, ```taint```, ```untaint```, ```'state list'```, ```'state rm'```, ```'state show'``` | ```plan``` |
| -log-severity | no | ERROR | Specifies the Terraform log verbosity this sets the ```TF_IN_AUTOMATION``` parameters, possible options are: ```TRACE```, ```DEBUG```, ```INFO```, ```WARN``` or ```ERROR``` | ```ERROR``` |
| -log-severity | no | ERROR | Specifies the Terraform log verbosity, possible options are: ```TRACE```, ```DEBUG```, ```INFO```, ```WARN``` or ```ERROR``` | ```ERROR``` |
| -tfstate_subscription_id | no | If no value specified, rover is assuming the currently logged-in subscription from az cli context. | GUID of the subscription containing the tfstate (launchpad). This will be used to locate and store the tfstate files. | ```a-b-c-d-e ``` |
| -target_subscription | no | If no value specified, rover is assuming the currently logged-in subscription from az cli context. | GUID of the subscription where to deploy the resources. | ```a-b-c-d-e``` |
| -workspace | no | ```tfstate``` | Specifies the storage account container where to store the tfstate for this landing zone. This could be used to isolate landing zones from each others by specifying Azure AD RBAC entries on the specific container withing the storage account. | ```my_container``` |
| -p | no | N/A | Specifies the location where to store the plan file, if not specified a plan file will be automatically created for you when you specify ```-a apply ``` and will be stored ```in ${TF_DATA_DIR}``` | ${TF_DATA_DIR}/caf_launchpad.tfstate.tfplan |
| -p | no | N/A | Specifies the location where to store the plan file, if not specified a plan file will be automatically created for you when you specify ```-a apply ``` | ```"$TF_DATA_DIR/caf_launchpad.tfstate.tfplan"``` |
| -launchpad | no | N/A | Flag that indicates that the current deployment is a launchpad. | ```-launchpad ``` |
| -tfc | no | N/A | Flag that indicates that the current deployment will use the TFC configured settings to store the state (refer to the Use TFC section of this guide) | ```-tfc ``` |
| -skip-permission-check | no | N/A | Flag to skip the check that the currently logged-in principal is owner of the target subscription (only checked for launchpad) | ```-skip-permission-check ``` |
| -skip-permission-check | no | N/A | Flag to skip the check that the currently logged-in principal is owner of the target subscription (only checked for launchpad) | ```-skip-permission-check ``` |
| -impersonate-sp-from-keyvault-url | no | N/A | Flag that indicates rover to use impersonate the Service Principal and use the credentials stored in the Azure Key Vault which URL is specified as parameter. Requires launchpad_credentials landing zone to be setup (more details to be published soon.) | ```-impersonate-sp-from-keyvault-url https://myakv.vault.azure.net/``` |

## Examples
Expand Down Expand Up @@ -110,6 +110,8 @@ rover \
-env contoso \
-level level3 \
-w data-landing-zone-prod `\
-p ${TF_DATA_DIR}/data-landing-zone_prod_level3.tfstate.tfplan \
-p ${TF_DATA_DIR}/data-landing-zone_prod_level3.tfstate.tfplan \
-p ${TF_DATA_DIR}/data-landing-zone_prod_level3.tfstate.tfplan \
-a untaint 'module.solution.module.storage_containers["storageWorkspace_di001"].azurerm_storage_container.stg'
```
Expand Down
Loading
Loading