Inside an Actions Job

Under the Hood: What Happens Inside a GitHub Actions Job

Workflow Fundamentals to Self-Hosted and Pricing teach workflows; this section shows the machinery first. One tiny manual workflow, merged into BookNest as pull request #13, is enough:

.github/workflows/inside-a-job.ymlYAML
name: Inside a job
on: workflow_dispatch
jobs:
  on-the-runner:
    runs-on: ubuntu-24.04
    steps:
      - name: Look around
        run: |
          echo "Runner $RUNNER_NAME: $ImageOS $ImageVersion, $(nproc) CPUs"
          echo "Workspace $GITHUB_WORKSPACE, commit ${GITHUB_SHA::7}"
          echo "::add-mask::shelf-key-1234"
          echo "The shelf key is shelf-key-1234"
          echo "::notice title=BookNest::Hello from job ${{ github.job }}"
          echo "### Hello from the runner" >> "$GITHUB_STEP_SUMMARY"
  in-a-container:
    runs-on: ubuntu-24.04
    container: node:24-alpine
    steps:
      - run: echo "Node $(node --version) on Alpine $(cat /etc/alpine-release)"
Starting the workflow by hand and reading the runShell
gh workflow run inside-a-job.yml
gh run watch 36127936652 --exit-status > /dev/null
gh run view 36127936652
Output
https://github.com/binarybehemoth/booknest/actions/runs/36127936652
...
✓ in-a-container in 9s (ID 108048301698)
✓ on-the-runner in 4s (ID 108048302011)
...

Subsections