Skip to content

Commit 66487d8

Browse files
authored
Merge pull request #299703 from RoseHJM/mdb-customizations-agentic-workflow
MDB - customizations - agentic workflow
2 parents 61cb707 + 91c1582 commit 66487d8

File tree

7 files changed

+137
-0
lines changed

7 files changed

+137
-0
lines changed
Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,135 @@
1+
---
2+
title: Streamline Dev Box Customizations with AI-Powered Workflows
3+
description: Use AI to automate Dev Box customizations. Generate YAML configurations with natural language prompts for consistent development environments.
4+
#customer intent: As a Dev Center Admin or Project Admin, I want to understand how to use Dev Box customizations so that I can create efficient, ready-to-code configurations for my development teams.
5+
author: RoseHJM
6+
ms.author: rosemalcolm
7+
ms.service: dev-box
8+
ms.custom:
9+
- ignite-2024
10+
- ai-gen-docs-bap
11+
- ai-gen-title
12+
- ai-seo-date:05/12/2025
13+
- ai-gen-description
14+
ms.topic: how-to
15+
ms.date: 05/12/2025
16+
---
17+
18+
# Use AI-powered workflows to generate Team Customizations (imagedefinition.yaml)
19+
20+
Dev Box supports an agentic workflow using GitHub Copilot agent mode to help generate the team customization file (imagedefinition.yaml) using natural language prompts. GitHub Copilot simplifies setting up your Dev Box environment by letting you describe your needs conversationally instead of manually creating YAML files.
21+
22+
## Supported scenarios
23+
24+
The Dev Box agentic workflow supports the following scenarios:
25+
26+
1. **Mimic your current development environment** - Generate or modify a definition that replicates the configuration of your current machine.
27+
28+
1. **Use repository context** - Create or modify a definition in the context of a specific GitHub repository.
29+
30+
1. **Natural language instructions** - Generate a customization file by describing the development environment you want.
31+
32+
> [!NOTE]
33+
> The agentic workflow supports only Dev Box primitive tasks, including WinGet, PowerShell, and Git-Clone.
34+
35+
## Prerequisites
36+
37+
Before you start, ensure you install the following software:
38+
39+
- [Visual Studio Code](https://code.visualstudio.com/download) (latest version)
40+
41+
- [GitHub Copilot extension set up in VS Code](https://code.visualstudio.com/docs/copilot/setup)
42+
43+
## Steps to generate the team customization file (imagedefinition.yaml)
44+
45+
1. Open Visual Studio Code.
46+
47+
1. Install the Dev Box extension if it's not already installed.
48+
49+
Open Extensions (Ctrl+Shift+X), search for **Dev Box**, and install the extension.
50+
51+
:::image type="content" source="media/how-to-use-copilot-generate-image-definition-file/dev-box-extension.png" alt-text="Screenshot of the Extensions pane in Visual Studio Code, showing the Dev Box extension.":::
52+
53+
1. Make sure agent mode is enabled by setting [chat.agent.enabled](vscode://settings/chat.agent.enabled) in the [Settings editor](https://code.visualstudio.com/docs/getstarted/personalize-vscode#_configure-settings). This setting requires VS Code 1.99 or later.
54+
55+
1. Open Copilot Chat in VS Code.
56+
57+
- Make sure **Dev Box tools** are preselected under "Select tools."
58+
59+
:::image type="content" source="media/how-to-use-copilot-generate-image-definition-file/dev-box-extension-tools.png" alt-text="Screenshot of the Copilot Chat pane in Visual Studio Code, showing Dev Box tools preselected.":::
60+
61+
:::image type="content" source="media/how-to-use-copilot-generate-image-definition-file/dev-box-extension-tools-list.png" alt-text="Screenshot of the Copilot Chat interface in Visual Studio Code.":::
62+
63+
- Select **Agent Mode**, and choose the model: **Claude 3.5 Sonnet**.
64+
65+
:::image type="content" source="media/how-to-use-copilot-generate-image-definition-file/dev-box-extension-select-agent.png" alt-text="Screenshot of the Agent Mode selection in Copilot Chat, showing the Claude 3.5 Sonnet model.":::
66+
67+
1. **Provide natural language prompts**, such as:
68+
69+
- *"I want to configure a dev box with all the tools and packages required to work on this [repo name] repo."*
70+
71+
- *"I want to preconfigure a dev box with Visual Studio 2022 Enterprise, VS Code, Git, .NET SDK 8, Node.js LTS, Docker Desktop installed, and have the team's repo [URL] cloned onto the dev box."*
72+
73+
- *"I want to configure a dev box with all the dev tools and packages installed on my current machine."*
74+
75+
> [!TIP]
76+
> Clone and open the specific repo in VS Code if you want to generate the definition in the context of a repository.
77+
78+
1. Follow the prompts to configure packages.
79+
80+
- When prompted, select **Continue** to proceed with package configuration.
81+
82+
- Copilot generates the imagedefinition.yaml file.
83+
84+
1. Refine with more prompts.
85+
86+
- Continue interacting with the agent until the tools and packages you want are reflected in the file.
87+
88+
## Validating or Applying the Customizations
89+
90+
Perform these steps **within a Dev Box** instance.
91+
92+
1. Select **Continue** when prompted to proceed with validation, or provide the prompt to validate the imagedefinition.yaml.
93+
94+
- Submit a prompt to the agent: *Validate my imagedefinition.yaml file.*
95+
96+
1. Apply customizations to the current Dev Box.
97+
98+
- Open Command Palette (Ctrl+Shift+P).
99+
100+
- Select **Apply Customization Tasks**.
101+
102+
- Confirm the User Account Control (UAC) prompt to install tools and apply settings.
103+
104+
:::image type="content" source="media/how-to-use-copilot-generate-image-definition-file/dev-box-extension-apply-customization-tasks.png" alt-text="Screenshot of the Apply Customization Tasks option in Visual Studio Code.":::
105+
106+
## Save and configure the project to use the image definition
107+
108+
After your imagedefinition.yaml is ready:
109+
110+
1. Save the file to a GitHub or Azure DevOps repository.
111+
112+
1. Attach the repository as a catalog to your project.
113+
114+
- This step is necessary to make the imagedefinition.yaml available for use in your Dev Box pool.
115+
116+
- For more information, see [Add and configure a catalog from GitHub or Azure Repos](../deployment-environments/how-to-configure-catalog.md).
117+
118+
1. Configure a Dev Box pool using the generated imagedefinition.yaml:
119+
120+
- Go to **Dev Box Pools** in your project.
121+
122+
- Create a new Dev Box pool or edit an existing one.
123+
124+
- Select the image definition created from your imagedefinition.yaml.
125+
126+
- For more information, see [Manage a dev box pool in Microsoft Dev Box](how-to-manage-dev-box-pools.md).
127+
128+
This method ensures that every Dev Box created from this pool uses the ready-to-code configuration.
129+
130+
This AI-powered workflow streamlines the process of setting up Dev Box customizations, letting platform engineers and dev managers create reusable, consistent environments with minimal effort.
131+
132+
## Related content
133+
134+
- [Dev Box customizations overview](concept-what-are-team-customizations.md)
135+
- [Write an image definition file for Dev Box team customizations](how-to-write-image-definition-file.md)

articles/dev-box/index.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,8 @@ landingContent:
9090
url: how-to-write-image-definition-file.md
9191
- text: Use secrets in customization files
9292
url: how-to-use-secrets-customization-files.md
93+
- text: Use GitHub Copilot to generate an image definition file
94+
url: how-to-use-copilot-generate-image-definition-file.md
9395
- text: Configure imaging for Customizations
9496
url: how-to-configure-customization-imaging.md
9597
- text: Create customization tasks
Loading
9.67 KB
Loading
23.5 KB
Loading
4 KB
Loading
43.6 KB
Loading

0 commit comments

Comments
 (0)