Service unavailable when using docker agent

Hi Everyone,

So I am to use docker agent on Jenkins. However, I get a “service unavailable error” when I build the job.
The pipeline is

pipeline {
    agent { 
        docker {
        image 'jenkins/agent'
        registryUrl ''`Preformatted text`
       // registryCredentialsId 'docker_hub_id'

and the error message is

$ docker login -u s*** -p ******** []( 
WARNING! Using --password via the CLI is insecure. Use --password-stdin.
 **error during connect: Post "https://docker:2376/v1.24/auth": Service Unavailable**

I was able to ping other IP addresses on the host network from the dind container.