| name | neo-azure-pipelines |
| description | Use this skill when the user asks to create, review, debug, or modernize Azure Pipelines YAML for CI/CD, especially .NET builds, Azure App Service deploys, or IIS/on-premises deploys. Prefer bundled templates and verify task syntax against Microsoft docs when version-specific accuracy matters.
|
| compatibility | Supports .NET 6.0 up to .NET 10.0. |
| metadata | {"version":"1.0.0","category":"DevOps"} |
Azure Pipeline Script Design Specifications
Perceive
- When version-specific syntax or task versions matter, verify them against
https://learn.microsoft.com/en-us/azure/devops/pipelines/?view=azure-devops; if browsing is unavailable, state the uncertainty and rely on bundled templates plus project evidence.
- Identify the application's development language (e.g., .NET, Java, Python, Node.js) and its specific version requirements.
- Identify the target deployment platform (e.g., Azure App Service, Azure Kubernetes Service, Function App, or on-premises servers).
- Detect the project source code structure to confirm build tools (e.g., Maven, Gradle, Npm, NuGet) and testing frameworks.
- Read security and compliance requirements, including Static Application Security Testing (SAST), package vulnerability scanning, and container image scanning.
- Confirm environment variable requirements, secret information sources (e.g., Azure Key Vault), and Service Connection permissions.
- Proactively scan the
skills/neo-azure-pipelines/templates/ directory to identify existing reusable template resources. Includes:
- Build:
build/build-dotnet.yml
- Deploy:
deploy/deploy-app-service.yml, deploy/deploy-iis.yml
- Utils:
util/clean-artifact.yml, util/extract-artifact.yml, util/iis/*.yml, etc.
Reason
- Compare documented task versions with existing configurations to determine if task versions need updating (e.g., using Checkout@v1 vs. Checkout@v4).
- Determine whether to adopt a multi-stage architecture based on project scale to achieve logical isolation of Build, Test, Staging, and Production.
- Evaluate and design build caching strategies, optimizing dependency package folders to reduce execution time.
- Design trigger mechanisms based on branching strategies, distinguishing trigger paths for Continuous Integration (CI) and Continuous Deployment (CD).
- Determine the applicability of deployment strategies, such as Blue-Green, Canary, or Rolling Update.
- Validate conditional execution syntax (Conditions) in Pipeline logic to ensure subsequent steps only execute on specific branches or after successful prerequisites.
- Prioritize using templates from
skills/neo-azure-pipelines/templates/ to assemble the Pipeline, rather than writing raw YAML from scratch.
- If the project is .NET and needs deployment to IIS, combine
build-dotnet.yml and deploy-iis.yml.
- If artifact manipulation is required, prioritize using
util/extract-artifact.yml.
Act
General Output Standards
- Output YAML configuration scripts that comply with the current project-compatible Azure DevOps schema; state assumptions when exact task versions cannot be verified.
- Provide comprehensive parameter definitions to increase the flexibility and reusability of Pipeline execution.
- Generate configuration recommendations for Environments and Approvals and Checks.
- Output a list of Task resource references used in the script, labeling version numbers to ensure execution environment consistency.
- Provide preventive comments and explanations for common execution errors (e.g., insufficient permissions, dependency conflicts).
- Use
template syntax to reference selected template files and correctly pass required parameters. For example:
- template: skills/neo-azure-pipelines/templates/build/build-dotnet.yml
parameters:
buildConfiguration: 'Release'
CI Workflow: .NET Build Pipeline
When configuring a CI process for a .NET project:
- Scan the project directory to identify the .NET version (e.g., .NET 6/8), project name, and solution file (
.sln).
- Check for any existing pipeline configurations.
- Create the
.pipelines/templates/build/ and .pipelines/templates/util/ directories.
- Copy
build/build-dotnet.yml and util/clean-artifact.yml templates to their respective locations.
- Generate
azure-pipelines-ci.yml in the project root, ensuring the structure uses proper template syntax with correct parameters.
CD Workflow: Azure App Service Deployment
When configuring a CD process for Azure App Service:
- Confirm the Azure App Service name, environment name (e.g., Production/Staging), and Service Connection name with the user or from the project context.
- Identify the Build Artifact name.
- Copy
deploy/deploy-app-service.yml to the project's .pipelines/templates/deploy/ directory.
- Generate the deployment pipeline file (e.g.,
azure-pipelines-cd-appservice.yml) in the project root.
- Ensure the YAML correctly configures
environment, strategy: runOnce, and template calls.
- Advise the user on setting up corresponding Environments and Approvals in Azure DevOps.
CD Workflow: On-Premises IIS Deployment
When configuring a CD process for on-premises IIS:
- Confirm IIS parameters: Website Name, Physical Path, Deployment Group name, and target environment.
- Verify if the project requires specific ASP.NET Core environment settings.
- Copy the entire
util/iis/ directory and the deploy/deploy-iis.yml template to the project's .pipelines/templates/ directory.
- Generate the deployment script (e.g.,
azure-pipelines-cd-iis.yml) in the project root, referencing deploy-iis.yml with parameters like websiteName and physicalPath.
- Ensure the script integrates
iis-backup.yml and iis-rollback.yml logic.
- Explain the requirements for Service Connection permissions and Deployment Group configuration.