Skip to content

Latest commit

Β 

History

History
58 lines (39 loc) Β· 1.31 KB

File metadata and controls

58 lines (39 loc) Β· 1.31 KB

How to Run GitHub Actions Locally Using act

This guide explains how to use nektos/act to run GitHub Actions locally on your machine for fast feedback and workflow testing.

πŸ›  Prerequisites

βš™οΈ Basic Usage

To run your default workflow locally:

act

To run a specific event:

act pull_request

To run a specific job from your workflow file:

act -j job-name

To run a specific workflow:

act -W workflow-file-name

πŸ§ͺ Dry Run Mode

To preview what act will do without actually running the jobs:

act --dryrun

πŸ› Troubleshooting

  • Cannot connect to the Docker daemon: ensure Docker is running and you are not overriding DOCKER_HOST.
  • platform mismatch: use --container-architecture linux/amd64 when needed.

βœ… Summary

Command Description
act Run all jobs locally
act -j <job> Run a specific job
act -W <workflow> Run a specific workflow
act pull_request Simulate a PR event
act --dryrun Preview actions without running