act Cheatsheet
act runs GitHub Actions workflows locally without pushing to GitHub. Validate your CI/CD pipelines instantly, debug faster with local Docker-based execution. It supports all common event types.
Updated: 2026-07-20·22 commands
Quick Start
``bash
act # Run all workflows (push event)
act -l # List all workflows
act -j build # Run a specific job
act pull_request # Simulate PR event
act --secret-file .secrets # Load secrets from file
act --reuse # Reuse containers for speed
``
Install & Setup(3)
| Command | Level | ||
|---|---|---|---|
act --helpShow act help | Basic | act --help | |
act --versionShow act version | Basic | act --version | |
.actrcDefault act config file (project root or ~/.actrc) | Intermediate | # ~/.actrc
-P ubuntu-latest=catthehacker/ubuntu:act-latest
--pull=false |
Basic Usage(7)
| Command | Level | ||
|---|---|---|---|
actRun all workflows (default trigger: push) | Basic | act | |
act -lList all available workflows and their events | Basic | act -l | |
act -gDisplay workflow structure as a graph | Basic | act -g | |
act -jRun a specific job (not the entire workflow) | Basic | act -j test | |
act -WSpecify a workflow file or directory | Basic | act -W .github/workflows/ci.yml | |
act --defaultbranchSpecify the default branch name (default: main) | Intermediate | act --defaultbranch master | |
act --container-architectureSpecify container architecture (e.g., linux/amd64, linux/arm64) | Intermediate | act --container-architecture linux/amd64 |
Event Triggers(4)
| Command | Level | ||
|---|---|---|---|
act pull_requestRun workflows simulating a pull_request event | Basic | act pull_request | |
act pushRun workflows simulating a push event | Basic | act push | |
act scheduleRun workflows simulating a schedule event | Intermediate | act schedule | |
act workflow_dispatchRun workflows simulating a workflow_dispatch event | Intermediate | act workflow_dispatch |
Secrets & Env(4)
| Command | Level | ||
|---|---|---|---|
act -sSet a secret (multiple -s flags allowed) | Intermediate | act -s MY_SECRET=value | |
act --secret-fileLoad secrets from a file (one KEY=value per line) | Intermediate | act --secret-file .secrets | |
act --env-fileLoad environment variables from a file | Intermediate | act --env-file .env | |
act --varSet GitHub Actions variables | Intermediate | act --var MY_VAR=value |
Advanced(4)
| Command | Level | ||
|---|---|---|---|
act -PCustom platform-to-image mapping (for newer versions) | Expert | act -P ubuntu-latest=catthehacker/ubuntu:act-latest | |
act --pull=falseDisable pulling new Docker images (use cached) | Intermediate | act --pull=false | |
act --reuseReuse containers from the previous run (faster debugging) | Intermediate | act --reuse | |
act --bindBind mount the working directory into the container (instead of copy) | Expert | act --bind |
FAQ
This cheatsheet is compiled from official tool documentation. Last updated: 2026-07-20.