Skip to content

Commit db32eff

Browse files
authored
Merge pull request #54032 from MicrosoftDocs/NEW-lp4m8-guided
New lp4m8 guided
2 parents b7c85aa + 41c8ef9 commit db32eff

18 files changed

Lines changed: 670 additions & 0 deletions
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.introduction
3+
title: Introduction
4+
metadata:
5+
title: Introduction
6+
description: "Introduction"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 2
14+
content: |
15+
[!include[](includes/1-introduction.md)]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.exercise-open-cloud-shell
3+
title: Exercise - Open Cloud Shell and explore the environment
4+
metadata:
5+
title: Exercise - Open Cloud Shell and explore the environment
6+
description: "Exercise - Open Cloud Shell and explore the environment"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 7
14+
content: |
15+
[!include[](includes/2-exercise-open-cloud-shell.md)]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.exercise-create-list-resources
3+
title: Exercise - Create and list resources with CLI commands
4+
metadata:
5+
title: Exercise - Create and list resources with CLI commands
6+
description: "Exercise - Create and list resources with CLI commands"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 10
14+
content: |
15+
[!include[](includes/3-exercise-create-list-resources.md)]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.exercise-tag-query-clean-up
3+
title: Exercise - Tag, query, and clean up resources
4+
metadata:
5+
title: Exercise - Tag, query, and clean up resources
6+
description: "Exercise - Tag, query, and clean up resources"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 10
14+
content: |
15+
[!include[](includes/4-exercise-tag-query-clean-up.md)]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.validate-success
3+
title: Validate success
4+
metadata:
5+
title: Validate success
6+
description: "Validate success"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 2
14+
content: |
15+
[!include[](includes/5-validate-success.md)]
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.clean-up-resources
3+
title: Clean up resources
4+
metadata:
5+
title: Clean up resources
6+
description: "Clean up resources"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 5
14+
content: |
15+
[!include[](includes/6-clean-up-resources.md)]
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.knowledge-check
3+
title: Knowledge check
4+
metadata:
5+
title: Knowledge check
6+
description: "Knowledge check"
7+
ms.date: 03/29/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 5
14+
content: |
15+
[!include[](includes/7-knowledge-check.md)]
16+
quiz:
17+
title: "Check your knowledge"
18+
questions:
19+
- content: "What query language does the Azure CLI use to filter and shape JSON output?"
20+
choices:
21+
- content: "SQL"
22+
isCorrect: false
23+
explanation: "SQL is used for relational databases, not for filtering Azure CLI JSON output."
24+
- content: "JMESPath"
25+
isCorrect: true
26+
explanation: "The Azure CLI --query parameter uses JMESPath, a built-in query language for filtering and reshaping JSON results."
27+
- content: "KQL (Kusto Query Language)"
28+
isCorrect: false
29+
explanation: "KQL is used with Azure Monitor and Log Analytics, not with Azure CLI JSON output filtering."
30+
- content: "What happens when you delete a resource group using the Azure CLI?"
31+
choices:
32+
- content: "Only the resource group is deleted. Resources inside it are preserved."
33+
isCorrect: false
34+
explanation: "Deleting a resource group removes everything inside it, including all resources."
35+
- content: "All resources inside the resource group are also deleted."
36+
isCorrect: true
37+
explanation: "Deleting a resource group is a cascading operation that removes the group and every resource it contains."
38+
- content: "Resources are moved to a default resource group before the original is deleted."
39+
isCorrect: false
40+
explanation: "Azure does not move resources automatically. Deleting a resource group permanently removes all its contents."
41+
- content: "What shell environment does Cloud Shell use by default for Azure CLI commands?"
42+
choices:
43+
- content: "PowerShell"
44+
isCorrect: false
45+
explanation: "PowerShell is available in Cloud Shell, but Azure CLI commands use the Bash environment by default."
46+
- content: "Command Prompt"
47+
isCorrect: false
48+
explanation: "Command Prompt is a Windows-only shell and is not available in Cloud Shell."
49+
- content: "Bash"
50+
isCorrect: true
51+
explanation: "Cloud Shell defaults to a Bash environment for Azure CLI commands, providing a Linux-based shell experience."
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
### YamlMime:ModuleUnit
2+
uid: learn.wwl.guided-project-manage-resources-cloud-shell-cli.summary
3+
title: Summary
4+
metadata:
5+
title: Summary
6+
description: "Summary"
7+
ms.date: 03/25/2026
8+
author: wwlpublish
9+
ms.author: robbarefoot
10+
ms.topic: unit
11+
ms.custom:
12+
- N/A
13+
durationInMinutes: 2
14+
content: |
15+
[!include[](includes/8-summary.md)]
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
This guided project focuses on managing Azure resources using Cloud Shell and the Azure CLI.
2+
3+
Azure Cloud Shell is a browser-based terminal built into the Azure portal. It comes preinstalled with the Azure CLI, so you can create, manage, and delete resources from the command line without installing anything on your computer. The CLI is especially useful when you need to perform the same operations across multiple resources quickly.
4+
5+
## Scenario
6+
7+
Your IT administrator needs to create and manage Azure resources efficiently without navigating through multiple portal screens. You open Cloud Shell, create a resource group and storage accounts from the command line, apply tags, query resources with built-in filters, and delete everything when you're done—demonstrating the full resource lifecycle from the CLI.
8+
9+
- Exercise 1 - Open Cloud Shell and explore the environment.
10+
- Exercise 2 - Create and list resources with CLI commands.
11+
- Exercise 3 - Tag, query, and clean up resources from the command line.
12+
13+
:::image type="content" source="../media/overview-architecture.png" alt-text="Diagram showing the Cloud Shell CLI workflow from Bash commands through resource creation, tagging, querying, and cleanup." border="false":::
14+
15+
By the end of this project, you can navigate Cloud Shell, create and manage resources with CLI commands, and use JMESPath queries to filter and format output.
16+
17+
> [!NOTE]
18+
> This is a guided project module where you complete a project by following step-by-step instructions.
19+
20+
## Skilling areas
21+
22+
In this project, you practice skills in the following areas:
23+
24+
**Navigate Cloud Shell and the CLI environment**
25+
+ Launch Cloud Shell and select Bash mode.
26+
+ Verify account and subscription settings.
27+
+ Use the built-in help system to discover commands and parameters.
28+
29+
**Create and manage resources from the CLI**
30+
+ Create resource groups and storage accounts with CLI commands.
31+
+ List resources and format output as a table.
32+
33+
**Tag, query, and clean up resources**
34+
+ Apply tags to resource groups and individual resources.
35+
+ Use JMESPath queries to filter and reshape CLI output.
36+
+ Delete a resource group and verify cleanup.
37+
38+
> [!IMPORTANT]
39+
> This project uses Azure Cloud Shell in the Azure portal. No software installation is required on your local computer.
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
This guided project consists of the following exercises:
2+
3+
- **Open Cloud Shell and explore the environment**
4+
- Create and list resources with CLI commands
5+
- Tag, query, and clean up resources
6+
7+
In this exercise, you launch Cloud Shell, verify your subscription, explore the built-in help system, and list available regions. By the end, you're comfortable navigating the CLI and ready to start creating resources from the command line.
8+
9+
This exercise includes the following tasks:
10+
11+
- Launch Cloud Shell
12+
- Verify your account and subscription
13+
- Explore the CLI help system
14+
- List available regions
15+
16+
**Outcome:** Cloud Shell is running in Bash mode and you can verify your subscription and navigate the shell environment.
17+
18+
> [!TIP]
19+
> Pause after each major action and confirm the page status before moving on. This habit prevents compounding mistakes.
20+
21+
## Task 1: Launch Cloud Shell
22+
23+
Open Cloud Shell from the Azure portal. Cloud Shell is a browser-based terminal that comes preinstalled with the Azure CLI, so you can manage Azure resources without installing anything on your computer.
24+
25+
> [!WARNING]
26+
> This project creates Azure resources that may incur charges. If this is your first time using Cloud Shell, Azure also creates a small storage account to persist your files. Complete the clean-up unit when you're done to avoid unintended expenses.
27+
28+
1. Sign in to the [Azure portal](https://portal.azure.com) with an account that has permissions to create resources.
29+
2. Select the **Cloud Shell** icon in the top menu bar (it looks like a terminal prompt **>_**).
30+
3. If prompted to choose a shell type, select **Bash**.
31+
4. If prompted to create storage, select **Create storage** and wait for Cloud Shell to initialize.
32+
5. Confirm that the Cloud Shell terminal opens at the bottom of the portal with a **Bash** prompt.
33+
34+
> [!NOTE]
35+
> **Validation step:** Confirm Cloud Shell is running in Bash mode with a command prompt visible.
36+
37+
> [!NOTE]
38+
> Each exercise includes validation steps like this one. Track your results as you go—you'll review them all in the validation unit at the end of this module.
39+
40+
## Task 2: Verify your account and subscription
41+
42+
Confirm that Cloud Shell is connected to the correct subscription. Every CLI command you run will target this subscription by default.
43+
44+
1. Run the following command to display your account details:
45+
46+
```bash
47+
az account show --output table
48+
```
49+
50+
2. Review the output and confirm the **SubscriptionId** and **Name** match the subscription you want to use.
51+
3. If you have multiple subscriptions and need to switch, run:
52+
53+
```bash
54+
az account list --output table
55+
```
56+
57+
4. Note the subscription name and ID for the one you want to use.
58+
59+
> [!NOTE]
60+
> **Validation step:** Confirm the **SubscriptionId** and **Name** match the subscription you want to use.
61+
62+
## Task 3: Explore the CLI help system
63+
64+
Learn how to find commands and get help without leaving the terminal. The built-in help system is one of the most useful features for beginners learning the CLI.
65+
66+
1. Run the following command to see the top-level CLI command groups:
67+
68+
```bash
69+
az --help
70+
```
71+
72+
2. Scroll through the output and note the major groups such as **group**, **storage**, **monitor**, and **resource**.
73+
3. Run the following command to see the subcommands available for managing resource groups:
74+
75+
```bash
76+
az group --help
77+
```
78+
79+
4. Note the available commands: **create**, **delete**, **list**, **show**, and others.
80+
5. Run the following command to see the full parameter list for creating a resource group:
81+
82+
```bash
83+
az group create --help
84+
```
85+
86+
6. Note the required parameters: **--name** and **--location**.
87+
88+
> [!NOTE]
89+
> **Validation step:** Confirm you can navigate the CLI help system to discover commands and required parameters.
90+
91+
## Task 4: List available regions
92+
93+
Before creating resources, check which Azure regions are available to your subscription. This is the CLI equivalent of the region dropdown you see in the portal.
94+
95+
1. Run the following command to list available regions:
96+
97+
```bash
98+
az account list-locations --output table
99+
```
100+
101+
2. Find a region close to you and note its **Name** value (for example, **eastus**, **westeurope**, or **southeastasia**). You use this value in the next exercise.
102+
103+
> [!NOTE]
104+
> **Validation step:** Confirm you identified and recorded a target region for resource creation.
105+
106+
> [!TIP]
107+
> You can resize the Cloud Shell pane by dragging its top edge. A larger pane makes it easier to read command output.

0 commit comments

Comments
 (0)