Setup - Avalin/Unity-CI-CD GitHub Wiki
🛠 Setup & Configuration
This page explains how to set up your Unity-CI-CD environment, configure required secrets, and control pipeline variables.
🔑 Required Secrets
You must add these under your repository:
GitHub → Settings → Secrets → Actions
| Secret Name | Description |
|---|---|
UNITY_LICENSE |
Base64-encoded Unity license file or .ulf string |
UNITY_EMAIL |
Unity account email address |
UNITY_PASSWORD |
Unity account password |
CICD_PAT |
GitHub Personal Access Token for workflow dispatch |
📖 See detailed setup for each secret:
Required Secrets
⚙️ Optional Secrets (Per Deploy Target)
Depending on your deploy targets, you may also need:
| Secret Name | Purpose |
|---|---|
SLACK_WEBHOOK |
Slack webhook URL for notifications |
DISCORD_WEBHOOK |
Discord webhook URL for notifications |
ITCH_USERNAME |
itch.io username for Butler uploads |
ITCH_PROJECT |
itch.io project identifier |
FIREBASE_TOKEN |
Firebase CLI authentication token |
AWS_ACCESS_KEY_ID |
AWS key for S3 deploy |
AWS_SECRET_ACCESS_KEY |
AWS secret for S3 deploy |
| (and others — see Deployment Guide) |
📋 Example Parameters
| Parameter | Description |
|---|---|
UNITY_VERSION |
Unity version (e.g., 2022.3.14f1) |
PROJECT_NAME |
Project name used in builds/artifacts |
BUILD_TARGETS |
JSON array of build targets (e.g., [ "WebGL" ]) |
DEPLOY_TARGETS |
JSON array of deploy targets (e.g., [ "gh-pages" ]) |
USE_GIT_LFS |
Whether to enable Git LFS (default: false) |
EXCLUDE_UNITY_TESTS |
Whether to skip tests (default: false) |
🏗 Example .github/config Files
For fallback defaults, you can create these files in .github/config:
defaults.json→ Defines fallback values for pipeline variables.deploy-targets.json→ Maps deploy targets to required OS.target-platforms.json→ Lists supported Unity build platforms.
💡 Note: Repository variables override config files, and manual workflow inputs override both.
The architecture of the .config files can be found here
🏆 Parameter Resolution Priority
When the pipeline resolves parameters (like unityVersion, buildType, deployTargets), it follows this priority order:
| Priority Rank | Source | Description |
|---|---|---|
| 🥇 1 | Workflow Dispatch Inputs | Passed when manually running workflows via the GitHub UI or gh workflow run |
| 🥈 2 | Repository Variables | Set under Settings → Variables → Actions in your GitHub repository |
| 🥉 3 | Config Files | Fallback defaults stored in .github/config/*.json (e.g., defaults.json) |
For example:
- If you set
inputs.unityVersionin a manual run, it overrides both theUNITY_VERSIONrepo variable and the defaults in the config file. - If no manual input is provided, the pipeline checks for a repository variable.
- If neither is provided, the pipeline falls back to the config file.
Tip:
You can check or change repository variables under GitHub → Settings → Variables → Actions.
Config files live in.github/config/and define project-wide defaults.