| name | cleanup-devops |
| description | Cleans up Azure DevOps resources (repositories, service connections, variable groups, pipelines) and resets configuration files. Use when you need to remove Azure DevOps artifacts after testing or to prepare for a fresh deployment of the Azure AI Foundry Starter template. |
Cleanup Azure DevOps Resources
Overview
This skill automates the cleanup of Azure DevOps resources created by the Azure AI Foundry Starter template, including repositories, service connections, variable groups, and pipelines. It also provides options to reset the configuration file to its template state.
Quick Start
Run the cleanup script interactively:
.\.github\skills\cleanup-devops\scripts\cleanup-devops.ps1
Core Capabilities
1. Azure DevOps Resource Deletion
Removes all Azure DevOps artifacts created during deployment:
- Repository: azure-ai-foundry-app
- Service Connections: {projectName}-dev, {projectName}-test, {projectName}-prod (from config.naming.projectName)
- Variable Groups: {projectName}-dev-vars, {projectName}-test-vars, {projectName}-prod-vars (from config.naming.projectName)
- Pipelines: All pipelines matching the project pattern
2. Configuration Reset
Resets starter-config.json to template state while creating a backup:
- Creates
.backup file before resetting
- Restores empty template structure
- Preserves original for reference
3. Safety Features
- Dry Run Mode: Preview deletions without making changes (
-DryRun)
- Confirmation Required: Must type 'DELETE' to proceed (unless
-Force)