CI/CD Secrets Setup¶
This guide covers setting up the required secrets and variables for the automated publishing workflows.
It also covers optional dashboard integrations that use Open Cloud (for example, propagating moderation actions to live servers).
Overview¶
The publishing workflows use Roblox Open Cloud API to publish games directly from GitHub Actions. This enables:
- Automatic publishing to dev on every merge to
main - Manual promotion to staging with approval
- Manual promotion to production with approval (requires version tag)
Prerequisites¶
- A Roblox account with publishing permissions for the target experiences
- Admin access to the GitHub repository settings
- Separate Roblox experiences for each environment (dev, staging, production)
Step 1: Create Open Cloud API Keys¶
For each environment (dev, staging, production), create a separate API key:
- Go to Roblox Creator Hub
- Click Create API Key
- Configure the key:
- Name:
GitHub-{env}-Publish(e.g.,GitHub-Dev-Publish) - Experience Operations: Add your experience
- Select Write permission for "Place"
- If using the dashboard moderation bridge, also grant:
- Data Stores: Write (standard DataStores)
- Messaging Service: Publish (cross-server messaging)
- IP Restrictions: For GitHub Actions, either:
- Leave unrestricted (simpler but less secure)
- Use GitHub's IP ranges (more secure)
- Expiration: Set based on your security requirements
- Copy the API key immediately (it won't be shown again)
Step 2: Get Experience IDs¶
For each environment, you need the Universe ID and Place ID:
- Go to Roblox Creator Hub
- Click on your experience
- Find Universe ID in the URL:
create.roblox.com/dashboard/creations/experiences/{UNIVERSE_ID} - Go to Places tab
- Find Place ID in the places list
Step 3: Configure GitHub Environments¶
Create Environments¶
- Go to Repository Settings → Environments
- Create three environments:
devstagingproduction
Configure Environment Protection Rules¶
Dev Environment¶
No protection rules needed (auto-deploys on merge to main)
Staging Environment¶
- Enable Required reviewers
- Add 1-2 reviewers who can approve staging promotions
- Optionally enable Wait timer (e.g., 5 minutes)
Production Environment¶
- Enable Required reviewers
- Add 2+ reviewers for production approvals
- Optionally limit to specific branches/tags
- Enable Wait timer (recommended: 15 minutes)
Add Secrets and Variables¶
For each environment, add the following:
Secrets (encrypted)¶
| Name | Description |
|---|---|
ROBLOX_OPEN_CLOUD_API_KEY |
The API key for this environment |
Variables (visible)¶
The workflows support multiple games (starter, obby, etc.). Each game needs its own set of environment variables:
Starter Game:
| Name | Description |
| ---------------------------- | ------------------------------ |
| STARTER_DEV_UNIVERSE_ID | Universe ID for dev |
| STARTER_DEV_PLACE_ID | Place ID for dev |
| STARTER_STAGING_UNIVERSE_ID| Universe ID for staging |
| STARTER_STAGING_PLACE_ID | Place ID for staging |
| STARTER_PROD_UNIVERSE_ID | Universe ID for production |
| STARTER_PROD_PLACE_ID | Place ID for production |
Obby Game:
| Name | Description |
| ------------------------- | ------------------------------ |
| OBBY_DEV_UNIVERSE_ID | Universe ID for dev |
| OBBY_DEV_PLACE_ID | Place ID for dev |
| OBBY_STAGING_UNIVERSE_ID| Universe ID for staging |
| OBBY_STAGING_PLACE_ID | Place ID for staging |
| OBBY_PROD_UNIVERSE_ID | Universe ID for production |
| OBBY_PROD_PLACE_ID | Place ID for production |
Important: These values are read via
vars.*inside the GitHub Actions Environment context. Define them in each GitHub Environment (dev,staging,production) under: Repository Settings → Environments → (select env) → Variables.
Step 4: Verify Setup¶
Test Dev Publishing¶
- Make a change and push to
main - Check the Actions tab for the "Publish Dev" workflow
- Verify it completes successfully
Test Staging Promotion¶
- Go to Actions → Promote workflow
- Click Run workflow
- Select the
game(starter/obby) - Select
stagingenvironment - Enter the git ref to promote (commit SHA or tag)
- Provide a reason for promotion
- Approve the deployment when prompted
Test Production Promotion¶
- Create a version tag:
git tag v1.0.0 && git push origin v1.0.0 - Go to Actions → Promote workflow
- Click Run workflow
- Select the
game(starter/obby) - Select
productionenvironment - Enter the version tag (e.g.,
v1.0.0) - Provide a reason for promotion
- Get approval from required reviewers
Troubleshooting¶
"Invalid API Key" Error¶
- Verify the API key is correctly copied to GitHub secrets
- Check if the API key has expired
- Ensure the key has the correct experience permissions
"Permission Denied" Error¶
- Verify the API key has Write permission for Place operations
- Check that the Universe ID and Place ID match the API key's experience
"Artifact Not Found" Error¶
The current publishing workflows rebuild from the provided git ref (commit SHA or tag).
- Verify the
source_refexists (commit SHA or tag) - For production promotions, ensure the ref is a SemVer tag like
v1.2.3 - If you still see an artifact-related error, it likely comes from a custom/older workflow run; re-run the current workflow
Rate Limiting¶
- Open Cloud API has rate limits; space out large deployments
- Consider adding retry logic if hitting limits frequently
Security Best Practices¶
- Separate API keys per environment - Never reuse keys across environments
- Minimal permissions - Only grant Write permission for Place operations
- Regular key rotation - Rotate API keys quarterly
- Audit access - Review who has approval rights quarterly
- IP restrictions - Consider restricting API keys to GitHub's IP ranges
- Monitor usage - Check Roblox Creator Hub for API key usage
Quick Reference¶
Environment Matrix¶
| Environment | Auto-Deploy | Approvers | Tag Required |
|---|---|---|---|
| dev | ✅ Yes (on main) | None | No |
| staging | ❌ Manual | 1-2 | No |
| production | ❌ Manual | 2+ | ✅ Yes (v..*) |
Required Secrets per Environment¶
dev:
- ROBLOX_OPEN_CLOUD_API_KEY
staging:
- ROBLOX_OPEN_CLOUD_API_KEY
production:
- ROBLOX_OPEN_CLOUD_API_KEY
### Dashboard Moderation Bridge (Optional)
The dashboard can optionally propagate bans/unbans to live servers using Open Cloud.
Required environment variables for the dashboard runtime:
MODERATION_OPEN_CLOUD_ENABLED=true ROBLOX_OPEN_CLOUD_API_KEY=... ROBLOX_UNIVERSE_ID=... ROBLOX_MODERATION_DATASTORE_NAME=StarterModeration ROBLOX_MODERATION_DATASTORE_SCOPE=global # optional ROBLOX_MODERATION_BAN_TOPIC=ModBanSync # optional ROBLOX_MODERATION_MUTE_TOPIC=ModMuteSync # optional
Important: `ROBLOX_MODERATION_DATASTORE_NAME` must match the value passed to `getModeration(...)` in the game server (for starter, this is currently `StarterModeration`).
Dashboard Feature Flags Bridge (Optional)¶
The dashboard can optionally propagate feature flag changes to live servers using Open Cloud.
Required environment variables for the dashboard runtime:
FEATUREFLAGS_OPEN_CLOUD_ENABLED=true
ROBLOX_OPEN_CLOUD_API_KEY=...
ROBLOX_UNIVERSE_ID=...
ROBLOX_FEATUREFLAGS_DATASTORE_NAME=StarterFeatureFlags
ROBLOX_FEATUREFLAGS_DATASTORE_SCOPE=global # optional
ROBLOX_FEATUREFLAGS_TOPIC=FeatureFlagsSync # optional
ROBLOX_FEATUREFLAGS_ENTRY_KEY_PREFIX=featureflags_ # optional
Important: ROBLOX_FEATUREFLAGS_DATASTORE_NAME must match what the game server uses when initializing feature flag sync.
Variables summary¶
No additional repository-level variables are required. The workflows read game-specific variables (STARTER_*, OBBY_*) from the selected GitHub Actions Environment.