trigger-config
Skill70 starsChanged 2 months agoMITView on GitHub
Configure Trigger.dev projects with trigger.config.ts. Use when setting up build extensions for Prisma, Playwright, FFmpeg, Python, or customizing deployment settings.
- Reads credentials
5 other projects use a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- adrianhajdin/ghost-aiword for word, first seen Oct 9, 2026
- papermark/papermarkword for word, first seen Oct 8, 2026
- mfts/papermarkword for word, first seen Oct 8, 2026
- trycompai/compedited, first seen Oct 8, 2026
- Visitha2001/ghost-ai-sseword for word, first seen Jun 24, 2026
Other versions5 projects use a version of this.
Word for word · 4
- mfts/papermark★ 9.2k100% same
- papermark/papermark★ 9.2k100% same
- adrianhajdin/ghost-ai★ 332100% same
- Visitha2001/ghost-ai-sse★ 0100% same
Edited · 1
- trycompai/comp★ 2.1k19% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository11 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- graduate-to-triggerSkill
- research-agentSkill
- research-process-builderSkill
- trigger-agentsSkill
- trigger-cost-savingsSkill
- trigger-realtimeSkill
- trigger-setupSkill
- trigger-tasksSkill
- research-process-builderSkill
The file
Files
Trigger.dev Configuration
Configure your Trigger.dev project with trigger.config.ts and build extensions.
When to Use
- Setting up a new Trigger.dev project
- Adding database support (Prisma, TypeORM)
- Configuring browser automation (Playwright, Puppeteer)
- Adding media processing (FFmpeg)
- Running Python scripts from tasks
- Syncing environment variables
- Installing system packages
Basic Configuration
// trigger.config.ts
import { defineConfig } from "@trigger.dev/sdk";
export default defineConfig({
project: "<project-ref>",
dirs: ["./trigger"],
runtime: "node", // "node", "node-22", or "bun"
logLevel: "info",
retries: {
enabledInDev: false,
default: {
maxAttempts: 3,
minTimeoutInMs: 1000,
maxTimeoutInMs: 10000,
factor: 2,
},
},
build: {
extensions: [], // Add extensions here
},
});Common Build Extensions
Prisma
import { prismaExtension } from "@trigger.dev/build/extensions/prisma";
export default defineConfig({
// ...
build: {
extensions: [
prismaExtension({
schema: "prisma/schema.prisma",
migrate: true,
directUrlEnvVarName: "DIRECT_DATABASE_URL",
}),
],
},
});Playwright (Browser Automation)
import { playwright } from "@trigger.dev/build/extensions/playwright";
extensions: [
playwright({
browsers: ["chromium"], // or ["chromium", "firefox", "webkit"]
}),
]Puppeteer
import { puppeteer } from "@trigger.dev/build/extensions/puppeteer";
extensions: [puppeteer()]
// Set env var: PUPPETEER_EXECUTABLE_PATH="/usr/bin/google-chrome-stable"FFmpeg (Media Processing)
import { ffmpeg } from "@trigger.dev/build/extensions/core";
extensions: [
ffmpeg({ version: "7" }),
]
// Automatically sets FFMPEG_PATH and FFPROBE_PATHPython
import { pythonExtension } from "@trigger.dev/build/extensions/python";
extensions: [
pythonExtension({
scripts: ["./python/**/*.py"],
requirementsFile: "./requirements.txt",
devPythonBinaryPath: ".venv/bin/python",
}),
]
// Usage in tasks:
const result = await python.runScript("./python/process.py", ["arg1"]);System Packages (apt-get)
import { aptGet } from "@trigger.dev/build/extensions/core";
extensions: [
aptGet({
packages: ["imagemagick", "curl"],
}),
]Additional Files
import { additionalFiles } from "@trigger.dev/build/extensions/core";
extensions: [
additionalFiles({
files: ["./assets/**", "./templates/**"],
}),
]Environment Variable Sync
import { syncEnvVars } from "@trigger.dev/build/extensions/core";
extensions: [
syncEnvVars(async (ctx) => {
return [
{ name: "API_KEY", value: await getSecret(ctx.environment) },
{ name: "ENV", value: ctx.environment },
];
}),
]Common Extension Combinations
Full-Stack Web App
extensions: [
prismaExtension({ schema: "prisma/schema.prisma", migrate: true }),
additionalFiles({ files: ["./assets/**"] }),
syncEnvVars(async (ctx) => [...envVars]),
]AI/ML Processing
extensions: [
pythonExtension({
scripts: ["./ai/**/*.py"],
requirementsFile: "./requirements.txt",
}),
ffmpeg({ version: "7" }),
]Web Scraping
extensions: [
playwright({ browsers: ["chromium"] }),
additionalFiles({ files: ["./selectors.json"] }),
]Global Lifecycle Hooks
export default defineConfig({
// ...
onStartAttempt: async ({ payload, ctx }) => {
console.log("Task starting:", ctx.task.id);
},
onSuccess: async ({ payload, output, ctx }) => {
console.log("Task succeeded");
},
onFailure: async ({ payload, error, ctx }) => {
console.error("Task failed:", error);
},
});Machine Defaults
export default defineConfig({
// ...
defaultMachine: "medium-1x",
maxDuration: 300, // seconds
});Telemetry Integration
import { PrismaInstrumentation } from "@prisma/instrumentation";
export default defineConfig({
// ...
telemetry: {
instrumentations: [new PrismaInstrumentation()],
},
});Best Practices
- Pin versions for reproducible builds
- Use
syncEnvVarsfor dynamic secrets - Add native modules to
build.externalarray - Debug with
--log-level debug --dry-run
Extensions only affect deployment, not local development.
See references/config.md for complete documentation.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

