azdo-classic-to-yaml
v1.0.1
Published
Generates classic release pipleines to Yaml.
Maintainers
Readme
Azdo Classic Release Pipeline to Yaml
This JavaScript package library extracts varibale groups, task groups and classic release pipleine as Yaml files.
Installation
- Run below commands to create
package.jsonfile and installazdo-classic-to-yaml.
npm init && npm i azdo-classic-to-yaml- Add
"generate": "node ./node_modules/azdo-classic-to-yaml/generate.js"in package.json file
{
"name": "demo",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"generate": "node ./node_modules/azdo-classic-to-yaml/generate.js"
},
"author": "",
"license": "ISC",
"dependencies": {
"azdo-classic-to-yaml": "^1.0.1"
}
}- Create
.envfile and update with yourORGANIZATION,PROJECTandPAT.(https://dev.azure.com/ORGANIZATION/PROJECT)
ORGANIZATION=
PROJECT=
PAT=- Run below command. This will generate yaml file in pipelines folder.
npm run generateEnvironment Variables
| Name | Description | Required | Default |
|:---|:---|:---:|:---:|
| AZURE_VSRM_URL | Azure VSRM URL | Optional | https://vsrm.dev.azure.com |
| AZDO_ENV_URL | Azdo environment url | Optional | https://dev.azure.com |
| ORGANIZATION | Organization Name | Yes | N/A |
| PROJECT | Project Name | Yes | N/A |
| PAT | Public Access Token | Yes | N/A |
Generated YAML files
- Variable Groups -
./pipelines/varibalegroups/*.yaml - Task Groups -
./pipelines/taskgroups/*.yaml - Release Pipeline -
./pipelines/*.yaml
Known Issues:
- This supports only for classic release pipelines and gives you simple template structure.
- Pre and Post approval flows are not covered and recommended to use deployment strategies with approval.
connectedServiceNameARM: $(az_service_connection)needs to be replaced withazureSubscription: $(az_service_connection)in some places.- Task groups needs to be updated with parameters -
$(az_service_connection)to${{ parameters.az_service_connection }} - Needs cleanup and fixes.
Samples:
name: "Release Pipeline 1"
trigger: none
paremeters: []
variables: []
resources:
pipelines: []
repositories: []
stages:
- stage: Development
variables: []
jobs:
- job: Bundle - DEV
- job: AKS Deployment - DEV
- job: DB Migration - DEV
- stage: Integration
variables: []
jobs:
- job: AKS Deployment - INT
- job: DB Migration - INT
- job: Post Deploy Testing - INT