DevOps / Github Interview questions
What are jobs and steps in a GitHub Actions workflow?
A job is a set of steps that run together on the same runner instance. A step is a single task within a job: either running a shell command (run) or invoking a reusable action (uses).
| Job | Step |
| Runs on its own runner instance. | Runs sequentially inside a job's runner. |
| Multiple jobs run in parallel by default. | Steps within a job always run in order, one at a time. |
Can depend on other jobs via needs. | Cannot depend on steps in a different job directly. |
Because jobs run in parallel by default and on separate runner instances, sharing data between jobs requires artifacts (uploaded by one job, downloaded by another); steps within the same job can simply share the runner's filesystem directly.
More Related questions...