Official build recipe templates for Internet Computer (ICP) canisters. Recipes provide standardized, reusable build configurations using Handlebars templates.
| Recipe | Description |
|---|---|
| Rust | Build Rust canisters using Cargo with WASM target |
| Motoko | Compile Motoko source code using the moc compiler |
| Pre-built | Use pre-compiled WASM files with metadata injection |
| Asset Canister | Deploy the official IC assets canister for frontend apps |
Reference a recipe in your icp.yaml file:
canister:
name: backend
recipe:
type: "@dfinity/rust"
configuration:
package: my-canister
shrink: trueRecipes follow the @dfinity/<recipe-name> naming pattern:
@dfinity/rust- Rust canister recipe@dfinity/motoko- Motoko canister recipe@dfinity/pre-built- Pre-built WASM recipe@dfinity/asset-canister- Asset canister recipe
To pin to a specific recipe version, append @<version> to the recipe type:
canister:
name: backend
recipe:
type: "@dfinity/rust@v3.0.0"
configuration:
package: my-canisterWithout a version specified, the latest stable version is used. View available versions in the releases page.
Each recipe is versioned independently. View release history by recipe type:
Releases follow semantic versioning and include auto-generated changelogs.
- Recipe Authoring Guide - Create custom recipes
- Recipe README Template - Documentation template
Contributions are welcome! Please see the contribution guide for details.
- Report issues: GitHub Issues
- Questions & discussions: DFINITY Developer Forum
This project is licensed under the Apache-2.0 license.