Skip to content

Config Files Overview

Astrid Avalin Soerensen edited this page May 11, 2025 · 3 revisions

๐Ÿ›  Configuration Files Overview

The Unity CI/CD pipeline reads four primary configuration files from .github/config/ to dynamically control build behavior, targets, and deployment strategies. See the ones defined in this project here.


๐Ÿ“ File Structure

.github/config/
โ”œโ”€โ”€ build-profiles.json
โ”œโ”€โ”€ build-targets.json
โ”œโ”€โ”€ defaults.json
โ””โ”€โ”€ deploy-targets.json

๐Ÿ”ง build-profiles.json

Defines Unity Build Profile names to be used with -buildProfile for Unity 6000+ (Unity 6) versions.

Each entry maps a Unity buildTarget to a profile name per build type.

"StandaloneLinux64-Server": {
  "preview": "CI-LinuxServer-Preview",
  "release_candidate": "CI-LinuxServer-RC",
  "release": "CI-LinuxServer-Release"
}

๐Ÿง  Used for:

  • Injecting -buildProfile ... in Unity 6+
  • Ensures correct config for client vs server, debug vs release

๐Ÿงฎ build-targets.json

Specifies OS requirements and minimum allowed build types per platform.

"StandaloneOSX": {
  "os": "macos-latest",
  "minimumBuildType": "preview"
}

๐Ÿง  Used for:

  • Validating inputs
  • Determining runner matrix (e.g., macOS for iOS, Linux for Android)

โš™๏ธ defaults.json

Global fallback settings, including:

  • Unity version
  • Default build & deploy targets
  • CI behavior flags
"pipeline": {
  "quietMode": false,
  "excludeUnityTests": false,
  "forceCombineArtifacts": false
}

๐Ÿง  Used for:

  • Resolving values when not passed as workflow inputs or repo vars
  • Controlling test skipping, Git LFS usage, etc.

๐Ÿš€ deploy-targets.json

Defines all supported deployment destinations, required OS runners, and artifact requirements.

"firebase": {
  "os": "ubuntu-latest",
  "requiresCombinedArtifact": true,
  "minimumBuildType": "release",
  "compatibleBuildTargets": ["WebGL"]
}

๐Ÿง  Used for:

  • Filtering deploy targets by compatibility
  • Assigning correct runners to deploy jobs
  • Determining if combined artifacts are required

๐Ÿ“Œ Tips

  • The defaults.json config can be overridden at runtime using workflow inputs or repo variables.
  • New targets or platforms can be added by editing the relevant config.
  • CI will skip incompatible targets based on minimumBuildType, os, or other criteria.
Clone this wiki locally