From febd0fc34733ec6c2865d5c01a55187e1b394087 Mon Sep 17 00:00:00 2001 From: Aaron Crawfis Date: Mon, 18 Sep 2023 16:36:23 -0700 Subject: [PATCH] Add HowTo guide on managing resource groups (#743) * Restructure groups page and add how-to guide * Shorten linkTitle * Reorder guide * Update docs/content/guides/operations/groups/howto-resourcegroups/index.md Co-authored-by: Will <28876888+willtsai@users.noreply.github.com> --------- Co-authored-by: Will <28876888+willtsai@users.noreply.github.com> --- .../guides/operations/groups/_index.md | 7 ++ .../groups/howto-resourcegroups/index.md | 89 ++++++++++++++++++ .../overview}/group-diagram.png | Bin .../groups => groups/overview}/group.svg | 0 .../groups => groups/overview}/index.md | 6 +- 5 files changed, 99 insertions(+), 3 deletions(-) create mode 100644 docs/content/guides/operations/groups/_index.md create mode 100644 docs/content/guides/operations/groups/howto-resourcegroups/index.md rename docs/content/guides/operations/{control-plane/groups => groups/overview}/group-diagram.png (100%) rename docs/content/guides/operations/{control-plane/groups => groups/overview}/group.svg (100%) rename docs/content/guides/operations/{control-plane/groups => groups/overview}/index.md (94%) diff --git a/docs/content/guides/operations/groups/_index.md b/docs/content/guides/operations/groups/_index.md new file mode 100644 index 000000000..0d01fa5e0 --- /dev/null +++ b/docs/content/guides/operations/groups/_index.md @@ -0,0 +1,7 @@ +--- +type: docs +title: "Resource groups" +linkTitle: "Resource groups" +description: "Manage collections of resources with resource groups" +weight: 600 +--- diff --git a/docs/content/guides/operations/groups/howto-resourcegroups/index.md b/docs/content/guides/operations/groups/howto-resourcegroups/index.md new file mode 100644 index 000000000..08c1fa1dd --- /dev/null +++ b/docs/content/guides/operations/groups/howto-resourcegroups/index.md @@ -0,0 +1,89 @@ +--- +type: docs +title: "How-To: Manage resource groups" +linkTitle: "Manage groups" +description: "Learn how to manage resource groups in Radius" +weight: 200 +--- + +This guide will walk you through the process of managing resource groups in Radius. For more information on resource groups, see [Resource groups]({{< ref groups >}}). + +## Pre-requisites + +- [Supported Kubernetes cluster]({{< ref supported-clusters >}}) +- [Radius CLI]({{< ref howto-rad-cli >}}) + +## Step 1: Ensure Radius is installed + +Begin by making sure that Radius is installed on your Kubernetes cluster: + +```bash +rad install kubernetes +``` + +## Step 2: Create a resource group + +Run [`rad group create`]({{< ref rad_group_create >}}) to create a resource group: + +```bash +rad group create myGroup +``` + +You should see: + +``` +creating resource group "myGroup" in namespace "default"... + +resource group "myGroup" created +``` + +## Step 3: View your resource group + +Run [`rad group show`]({{< ref rad_group_show >}}) to view the your resource group: + +```bash +rad group show myGroup +``` + +You should see: + +``` +ID NAME +/planes/radius/local/resourcegroups/myGroup myGroup +``` + +You can use the `-o json` flag to view more information about the resource group: + +```bash +rad group show -o json +``` + +You should see: + +``` +{ + "id": "/planes/radius/local/resourcegroups/myGroup", + "location": "global", + "name": "myGroup", + "tags": {}, + "type": "System.Resources/resourceGroups", +} +``` + +## Step 4: Set your resource group as the default + +Setting a default resource group allows you to run commands like `rad deploy` without specifying the `-g/--group` flag explicitly every time. Run [`rad group switch`]({{< ref rad_group_switch >}}) to set your new resource group as the default: + +```bash +rad group switch myGroup +``` + +You can now run `rad deploy` or `rad recipe list` without needing to specify the group. + +## Step 5: Delete your resource group + +Run [`rad group delete`]({{< ref rad_group_delete >}}) to delete a resource group: + +```bash +rad group delete myGroup +``` diff --git a/docs/content/guides/operations/control-plane/groups/group-diagram.png b/docs/content/guides/operations/groups/overview/group-diagram.png similarity index 100% rename from docs/content/guides/operations/control-plane/groups/group-diagram.png rename to docs/content/guides/operations/groups/overview/group-diagram.png diff --git a/docs/content/guides/operations/control-plane/groups/group.svg b/docs/content/guides/operations/groups/overview/group.svg similarity index 100% rename from docs/content/guides/operations/control-plane/groups/group.svg rename to docs/content/guides/operations/groups/overview/group.svg diff --git a/docs/content/guides/operations/control-plane/groups/index.md b/docs/content/guides/operations/groups/overview/index.md similarity index 94% rename from docs/content/guides/operations/control-plane/groups/index.md rename to docs/content/guides/operations/groups/overview/index.md index 452be5f59..675f90e3a 100644 --- a/docs/content/guides/operations/control-plane/groups/index.md +++ b/docs/content/guides/operations/groups/overview/index.md @@ -1,8 +1,8 @@ --- type: docs -title: "Resource groups" -linkTitle: "Resource groups" -description: "Manage collections of resources with resource groups" +title: "Overview: Resource groups" +linkTitle: "Overview" +description: "Learn how to manage collections of resources with resource groups" weight: 100 ---