SuperAPI AI Directory

yaml-pipeline-validator

Deployment & operations

View repository

Updated 10-15 21:33

About this skill

YAML Pipeline Validator Skill

This is a skill for validating Azure Pipelines YAML.

Main Features

  • Syntax validation: YAML syntax check
  • Best practices: Recommended settings check
  • Security: Secret exposure check
  • Performance: Optimization suggestions

Validation Items

1. Required fields

# ❌ Bad: トリガーなし
pool:
  vmImage: 'ubuntu-latest'
✅ Good

trigger:

  • main

pool: vmImage: 'ubuntu-latest'


### 2. シークレット管理

```yaml
# ❌ Bad: ハードコード
steps:
  - script: echo "Password: MySecretPassword123"

# ✅ Good: 変数グループ使用
variables:
  - group: Secrets

steps:
  - script: echo "Password: $(SecretPassword)"

3. Cache usage

# ✅ Good: 依存関係キャッシュ
steps:
  - task: Cache@2
    inputs:
      key: 'npm | "$(Agent.OS)" | package-lock.json'
      path: $(npm_config_cache)

  - script: npm install

4. Parallel execution

# ✅ Good: 並列ジョブ
jobs:
  - job: TestLinux
    pool:
      vmImage: 'ubuntu-latest'
    steps:
      - script: npm test

  - job: TestWindows
    pool:
      vmImage: 'windows-latest'
    steps:
      - script: npm test

Azure CLI validation

# YAML検証
az pipelines validate \
  --repository myrepo \
  --branch main \
  --path azure-pipelines.yml

Version information

  • Version: 1.0.0