GITHUB-ACTIONS · Question #32
As a developer, you are using a Docker container action in your workflow. What is required for the action to run successfully?
The correct answer is B. The job runs-on must specify a Linux machine with Docker installed.. For a Docker container action to run in a GitHub Actions workflow, the runner must have Docker installed. The runs-on attribute of the job should specify an environment that supports Docker, typically a Linux environment (e.g., ubuntu-latest), since Docker is widely supported and
Question
As a developer, you are using a Docker container action in your workflow. What is required for the action to run successfully?
Options
- AThe job env must be set to a Linux environment.
- BThe job runs-on must specify a Linux machine with Docker installed.
- CThe referenced action must be hosted on Docker Hub.
- DThe action must be published to the GitHub Marketplace.
How the community answered
(53 responses)- A4% (2)
- B92% (49)
- C2% (1)
- D2% (1)
Explanation
For a Docker container action to run in a GitHub Actions workflow, the runner must have Docker installed. The runs-on attribute of the job should specify an environment that supports Docker, typically a Linux environment (e.g., ubuntu-latest), since Docker is widely supported and commonly used in Linux-based environments.
Topics
Community Discussion
No community discussion yet for this question.