# =============================================================================
# IGCV3 Batch Generation Manifest
# =============================================================================
# This file allows you to generate multiple certificates in a single run.
# Usage: igcv3 generate --manifest manifest.yml
#
# Each item in the list can either:
# 1. Use a 'preset' defined in igcv3.conf.yml
# 2. Define a 'manual' configuration (ad-hoc)
# =============================================================================

# -----------------------------------------------------------------------------
# 1. Manual Definition (Ad-hoc / "Inline")
# -----------------------------------------------------------------------------
# Useful for legacy systems or one-off certificates that don't fit a preset.
- cn: 'legacy.system.local'
  # No preset used here, we define everything manually
  countryName: 'FR'
  organizationName: 'Legacy Corp'
  organizationalUnitName:
    - 'Old Systems'
    - 'Room 42'
  validityDays: 3650 # 10 years!
  subjectAltName:
    - 'DNS:legacy.system.local'
    - 'IP:192.168.0.99'
  key:
    algo: 'rsa'
    size: 4096
  # Optional: Control output location and filenames
  output:
    dir: './certs/legacy'
    filename: 'legacy-cert'
    # csr: "custom.csr" # Force specific filename
    # key: "custom.key" # Force specific filename

# -----------------------------------------------------------------------------
# 2. Standard Preset Usage
# -----------------------------------------------------------------------------
# Uses the 'web-standard' preset from configuration.
- cn: 'app.internal.net'
  preset: 'web-standard'
  output:
    dir: './certs/web'

# -----------------------------------------------------------------------------
# 3. Preset with Dynamic Variables
# -----------------------------------------------------------------------------
# Uses the 'project' preset which requires variables (PROJECT, ENV, IP_ADDRESS).
- cn: 'api.project-alpha.dev'
  preset: 'project'
  vars:
    PROJECT: 'alpha'
    ENV: 'dev'
    IP_ADDRESS: '10.0.0.42'
  output:
    dir: './certs/projects/alpha'

# -----------------------------------------------------------------------------
# 4. Bulk Generation Example
# -----------------------------------------------------------------------------
- cn: 'db-01.infra.local'
  preset: 'internal-service'
  output: { dir: './certs/infra' }

- cn: 'db-02.infra.local'
  preset: 'internal-service'
  output: { dir: './certs/infra' }

- cn: 'cache.infra.local'
  preset: 'internal-service'
  output: { dir: './certs/infra' }
