- Clone and enter the repo.
- Run bootstrap once.
- Set your local DB connection string.
- Run the app in Development mode.
Clone:
git clone <your-repo-url> turbo-cloud
cd turbo-cloudBootstrap (PowerShell):
pwsh -File scripts/bootstrap.ps1Bootstrap (bash/zsh):
sh scripts/bootstrap.shSet Turbo:Database:ConnectionString in appsettings.Development.json, then run:
PowerShell:
$env:DOTNET_ENVIRONMENT="Development"; dotnet run --project Turbo.Main/Turbo.Main.csprojbash/zsh:
DOTNET_ENVIRONMENT=Development dotnet run --project Turbo.Main/Turbo.Main.csprojTurbo.Cloud.sln is the main Turbo emulator solution.
It includes the host executable (Turbo.Main), domain modules (Turbo.Rooms, Turbo.Players, Turbo.Database, and others), networking/message layers, and plugin infrastructure.
- .NET SDK 9.x (pinned via
global.json) - Git
- MySQL running locally (or reachable dev instance)
Check SDK:
dotnet --versionappsettings.jsoncontains shared defaults.appsettings.Development.jsonis local-only and gitignored.- The bootstrap script creates
appsettings.Development.jsonfromappsettings.jsonif missing.
- Fast local commit check:
dotnet build Turbo.Main/Turbo.Main.csproj -t:TurboCloudFastCheck
- Full quality gate (pre-push + CI):
dotnet build Turbo.Main/Turbo.Main.csproj -t:TurboCloudQualityGate
- AI policy rollout phase:
- Default is
TurboAIPolicyPhase=1(warn-first). - Preview strict mode with
-p:TurboAIPolicyPhase=2.
- Default is
Hooks are repository-managed in .githooks:
pre-commitruns the fast check.pre-pushruns the full quality gate.
| Command | Scope | Default? | Use when |
|---|---|---|---|
dotnet build Turbo.Main/Turbo.Main.csproj |
Core emulator only | Yes | Normal core development and CI-compatible local checks |
dotnet build Turbo.Cloud.sln |
All projects currently in solution (including sample plugin) | No | One-window integrated core + plugin work |
dotnet build ../turbo-sample-plugin/TurboSamplePlugin/TurboSamplePlugin.csproj |
Sample plugin only | No | Plugin-only iteration |
TurboSamplePlugin intentionally stays in Turbo.Cloud.sln for IDE convenience, but the default repo build contract is project-scoped to Turbo.Main.
- Core build (default):
dotnet build Turbo.Main/Turbo.Main.csproj - Integrated solution build (optional):
dotnet build Turbo.Cloud.sln - Plugin build only (optional):
dotnet build ../turbo-sample-plugin/TurboSamplePlugin/TurboSamplePlugin.csproj - Fast checks:
dotnet build Turbo.Main/Turbo.Main.csproj -t:TurboCloudFastCheck - Full quality gate:
dotnet build Turbo.Main/Turbo.Main.csproj -t:TurboCloudQualityGate - Run in Development:
dotnet run --project Turbo.Main/Turbo.Main.csproj
Plugin loading supports both the runtime plugin folder and dev-specific paths:
- Default folder:
<runtime>/plugins - Optional config:
Turbo:Plugin:DevPluginPaths
Example:
{
"Turbo": {
"Plugin": {
"DevPluginPaths": [
"C:/Users/you/RiderProjects/turbo-sample-plugin/TurboSamplePlugin/bin/Debug/net9.0"
]
}
}
}If the same plugin key exists in both places, DevPluginPaths wins and a warning is logged.
Your plugin's .csproj must copy manifest.json to the build output:
<ItemGroup>
<Content Include="manifest.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
</ItemGroup>You can list multiple plugin paths in DevPluginPaths when developing several plugins at once.
Terminal 1 (run emulator):
dotnet run --project Turbo.MainTerminal 2 (watch plugin):
cd C:/path/to/your-plugin
dotnet watch buildWhen dotnet watch rebuilds your plugin, Turbo Cloud detects the new DLL and hot-reloads the plugin in-process.
- Grain types cannot be hot-reloaded because Orleans grain type registration happens at silo startup.
- Memory may grow over many reloads if assembly references are retained; restart periodically during long sessions.
Canonical integrated workflow lives in the plugin repo:
- Guide:
../turbo-sample-plugin/README.md - PowerShell:
pwsh -File ../turbo-sample-plugin/scripts/dev-integrated.ps1 - bash/zsh:
sh ../turbo-sample-plugin/scripts/dev-integrated.sh
Turbo Cloud uses Orleans as its core runtime model for stateful domain workflows.
For project-specific Orleans guidance, see docs/orleans.md.
If you see Unable to connect to any of the specified MySQL hosts:
- Verify
Turbo:Database:ConnectionStringinappsettings.Development.json. - Verify MySQL host/port are reachable.
- Verify no
TURBO__...environment variables override your local setting.
- Ensure
DOTNET_ENVIRONMENT=Developmentwhen running. - Confirm
appsettings.Development.jsonexists at repo root.
- Run
dotnet tool restore. - Run
dotnet csharpier .. - Run
dotnet format style. - Run
dotnet format analyzers. - Re-run
dotnet build Turbo.Main/Turbo.Main.csproj -t:TurboCloudQualityGate.
If dotnet build Turbo.Cloud.sln fails because of plugin project state, use the default core build command:
dotnet build Turbo.Main/Turbo.Main.csprojCanonical AI context files:
AGENTS.md(coding contract and review rules)CONTEXT.md(architecture boundaries and placement rules)docs/patterns/(golden implementation examples)
Tool-specific adapters:
.github/copilot-instructions.md(GitHub Copilot)CLAUDE.md(Claude)CODEX.md(Codex)
Prompt recipe for any AI tool:
- Include task + exact target file paths.
- Attach
AGENTS.mdandCONTEXT.md. - Reference one relevant file from
docs/patterns/. - Ask for edge-case handling and validation commands.
Boost-style prompting pack:
- portable prompt contract + task recipes live in
AGENTS.md - architecture invariants live in
CONTEXT.md - tool adapters live in
.github/copilot-instructions.md,CLAUDE.md, andCODEX.md