HN 표시: PipeStep – GitHub Actions 워크플로를 위한 단계별 디버거

hackernews | | 📰 뉴스
#ci/cd #devops #docker #github actions #디버거 #하드웨어/반도체
원문 출처: hackernews · Genesis Park에서 요약 및 분석

요약

개발자가 GitHub Actions의 CI 파이프라인을 디버깅할 때 겪는 불편함을 해소하기 위해 'PipeStep'이라는 단계별 실행 디버거가 개발되었습니다. 이 도구는 GitHub Actions YAML을 분석해 Docker 컨테이너를 실행하며, 사용자는 파이프라인 중단점을 설정하거나 실행 중인 컨테이너에 접속해 상태를 점검할 수 있습니다. PipeStep은 완전한 로컬 실행 환경 대신 CI 파이프라인 오류를 신속하게 파악하는 것에 초점을 맞추고 있으며, Python 3.11 이상과 Docker 환경이 필요합니다.

본문

A debugger for your CI pipeline. Step through GitHub Actions workflows locally with Docker. Pause before each step, inspect the environment, drop into a shell, modify variables, re-run failed steps — without pushing and waiting. The CI debugging loop: - Commit a fix - Push to GitHub - Wait 2-5 minutes for the runner - Watch it fail - Read the logs, guess what went wrong - Repeat A single debugging session eats 30-60 minutes. PipeStep lets you step through the pipeline locally, inspect the container at each stage, and fix issues before you push. # Prerequisites: Docker Desktop running, Python 3.11+ pip install pipestep # or from source: python3.11 -m venv .venv source .venv/bin/activate pip install -r requirements.txt # Pre-pull the base image docker pull ubuntu:22.04 Requires Python 3.11+ and Docker Desktop running. # Point it at any GitHub Actions workflow in your project pipestep run .github/workflows/ci.yml # or from source: python cli.py run sample_workflow.yml | Key | Action | |---|---| | R | Run the current step (or run local equivalent for action steps) | | S | Skip the current step | | I | Shell into the container (interactive bash) | | B | Toggle breakpoint on a step | | N | Auto-run to the next breakpoint | | Q | Quit and cleanup containers | | Arrow keys | Navigate step list | PipeStep pauses at action steps instead of silently skipping them. For common actions, it provides local equivalents that you can run with R: | Action | Local Equivalent | |---|---| actions/checkout@* | Workspace already mounted via Docker volume | actions/setup-node@* | Installs Node.js via apt | actions/setup-python@* | Installs Python via apt | actions/setup-go@* | Installs Go via apt | actions/setup-java@* | Installs Java via apt | actions/cache@* | No-op (caching not needed locally) | For unknown actions, press I to shell into the container and set up manually, or S to skip. PipeStep pauses and lets you: - Shell in to the exact container where it failed — same filesystem, same env vars - Retry the step after making changes inside the container - Skip past it and continue the pipeline - Quit and clean up No more guessing from log output. You're inside the environment where it broke. Every debugging session is automatically recorded. When you quit, PipeStep saves a bash script capturing every step you ran, skipped, or shelled into. Use these recordings to reproduce debugging sessions or as the basis for tests. - Parses your GitHub Actions YAML - Maps runs-on to a local Docker image (e.g.ubuntu-latest →ubuntu:22.04 ) - Creates a container and executes each step sequentially - Pauses between steps so you can inspect, modify, or debug | PipeStep | act | | |---|---|---| | Execution model | Step-through with pause/inspect | Batch run | | Shell into container | Yes, mid-pipeline | No | | Breakpoints | Yes | No | | Re-run failed steps | Yes | Restart entire pipeline | | Primary use case | Debugging | Running locally | act is great for running pipelines locally. PipeStep is for when things go wrong and you need to figure out why. PipeStep runs your run: steps in a local Docker container. It does not replicate the full GitHub Actions runtime: - GitHub Actions ( uses: ) are detected — best-effort equivalents for common actions, but no full execution - Secrets and ${{ secrets.* }} are not available — replace them with local env vars or hardcode test values in the container - Service containers ( services: ) are not started - Matrix builds ( strategy.matrix ) are not expanded — pick one combination and test it - Artifact upload/download actions won't run GITHUB_TOKEN and GitHub API access are not provided- Runner OS is mapped to stock Docker images ( ubuntu-latest →ubuntu:22.04 ) — pre-installed tools on GitHub's runners may be missing - Apple Silicon — Docker runs x86 Linux images through emulation on M-series Macs, which is noticeably slower if: conditionals are not evaluated (all steps are presented)- Shell is always bash (nopwsh or custom shells) These are real constraints. PipeStep's value is debugging your shell commands (run: steps) in the exact container environment — not emulating the full GitHub Actions platform. For full local runs, use act . git clone https://github.com/photobombastic/pipestep.git cd pipestep python3.11 -m venv .venv source .venv/bin/activate pip install -e ".[dev]" # Run tests pytest

Genesis Park 편집팀이 AI를 활용하여 작성한 분석입니다. 원문은 출처 링크를 통해 확인할 수 있습니다.

공유

관련 저널 읽기

전체 보기 →