Fix the Jenkins error: Invalid agent type Docker specified [any, label, none]

Jenkins Docker error: Invalid agent type

If you’re Jenkins Docker build jobs are failing with the following error, don’t fret, as there’s a simple fix.

Invalid agent type "docker" specified. Must be one of [any, label, none].

If you’ve hit this error, you likely have a Jenkinsfile that references a Docker container, but you haven’t installed either the Jenkins Docker plugin, or the Jenkins Docker Pipeline plugin. Just add those two Jenkins plugins and the Docker error will go away.

Jenkins Docker invalid agent type

Quickly fix the Jenkins Docker invalid agent type error by installing the right plugins.


Cameron McKenzie Cameron McKenzie is an AWS Certified AI Practitioner, Machine Learning Engineer, Solutions Architect and author of many popular books in the software development and Cloud Computing space. His growing YouTube channel training devs in Java, Spring, AI and ML has well over 30,000 subscribers.