Drone

Runner - Cannot ping the remote server

Hi,

I configure runner and now get the below error:

time="2020-01-04T17:37:54Z" level=error msg="cannot ping the remote server" error="<!DOCTYPE HTML>\r\n<html>\r\n\r\n    <head>\r\n        <title>404 Error - Page Not Found</title>\r\n        <style>\r\n            #ad_frame{ height:800px; width:100%; }\r\n            body{ margin:0; border: 0; padding: 0; }\r\n        </style>\r\n        <script src=\"//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js\"></script>\r\n        <script type=\"text/javascript\" language=\"JavaScript\">\r\n            var url = 'http://www.iyfipgun.com/?dn='\r\n                + document.domain + '&pid=9POL6F2H4';\r\n\r\n            $(document).ready(function() {\r\n                $('#ad_frame').attr('src', url);\r\n            });\r\n        </script>\r\n    </head>\r\n    <body>\r\n        <iframe id=\"ad_frame\" src=\"http://www.iyfipgun.com/\"\r\n            frameborder=\"0\" scrolling=\"no\">\r\n\r\n            <!-- browser does not support iframe's -->\r\n\r\n        </iframe>\r\n    </body>\r\n\r\n</html>\r\n"

Thanks :blush:

see Builds are Stuck in Pending Status which deals with the issue of runners not being able to connect with the server. It also specifies all information that must be provided in order to receive support.

1 Like

I run the command: docker logs drone1

Output

{"level":"info","msg":"main: internal scheduler enabled","time":"2020-01-06T16:48:24Z"}
{"build.limit":5000,"expires":"0001-01-01T00:00:00Z","kind":"trial","level":"debug","msg":"main: license loaded","repo.limit":0,"time":"2020-01-06T16:48:24Z","user.limit":0}
{"interval":"30m0s","level":"info","msg":"starting the cron scheduler","time":"2020-01-06T16:48:24Z"}
{"acme":false,"host":"drone.domain.com","level":"info","msg":"starting the http server","port":":80","proto":"http","time":"2020-01-06T16:48:24Z","url":"http://drone.domain.com"}
{"level":"debug","msg":"events: stream opened","request-id":"1W1uDr7QfDzF57Ncual34NcJPap","time":"2020-01-06T16:48:25Z"}

And run docker logs runner

Output

time="2020-01-06T16:50:55Z" level=error msg="cannot ping the remote server" error="<!DOCTYPE HTML>\r\n<html>\r\n\r\n    <head>\r\n        <title>404 Error - Page Not Found</title>\r\n        <style>\r\n            #ad_frame{ height:800px; width:100%; }\r\n            body{ margin:0; border: 0; padding: 0; }\r\n        </style>\r\n        <script src=\"//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js\"></script>\r\n        <script type=\"text/javascript\" language=\"JavaScript\">\r\n            var url = 'http://www.iyfipgun.com/?dn='\r\n                + document.domain + '&pid=9POL6F2H4';\r\n\r\n            $(document).ready(function() {\r\n                $('#ad_frame').attr('src', url);\r\n            });\r\n        </script>\r\n    </head>\r\n    <body>\r\n        <iframe id=\"ad_frame\" src=\"http://www.iyfipgun.com/\"\r\n            frameborder=\"0\" scrolling=\"no\">\r\n\r\n            <!-- browser does not support iframe's -->\r\n\r\n        </iframe>\r\n    </body>\r\n\r\n</html>\r\n"

Runner config

docker run -d \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -e DRONE_RPC_PROTO=${DRONE_RPC_PROTO} \
  -e DRONE_RPC_HOST=${DRONE_RPC_HOST} \
  -e DRONE_RPC_SECRET=${DRONE_RPC_SECRET} \
  -e DRONE_RUNNER_CAPACITY=${DRONE_RUNNER_CAPACITY} \
  -e DRONE_RUNNER_NAME=${DRONE_RUNNER_NAME} \
  -e DRONE_TRACE=${DRONE_TRACE} \
  -p 3000:3000 \
  --restart always \
  --name runner \
  drone/drone-runner-docker:1

Server config

docker run \
 --volume=/var/lib/drone:/data \
  --env=DRONE_AGENTS_ENABLED=true \
  --env=DRONE_LOGS_TRACE=${DRONE_LOGS_TRACE} \
  --env=DRONE_GITHUB_SERVER=https://github.com \
  --env=DRONE_GITHUB_CLIENT_ID=${DRONE_GITHUB_CLIENT_ID} \
  --env=DRONE_GITHUB_CLIENT_SECRET=${DRONE_GITHUB_CLIENT_SECRET} \
  --env=DRONE_RPC_SECRET=${DRONE_RPC_SECRET} \
  --env=DRONE_SERVER_HOST=${DRONE_SERVER_HOST} \
  --env=DRONE_SERVER_PROTO=${DRONE_SERVER_PROTO} \
  --publish=80:80 \
  --publish=443:443 \
  --restart=always \
  --detach=true \
  --name=drone1 \
  drone/drone:1

My envs

docker inspect drone1 && docker inspect runner

[
    {
        "Id": "f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d",
        "Created": "2020-01-06T16:48:24.581139914Z",
        "Path": "/bin/drone-server",
        "Args": [],
        "State": {
            "Status": "running",
            "Running": true,
            "Paused": false,
            "Restarting": false,
            "OOMKilled": false,
            "Dead": false,
            "Pid": 39021,
            "ExitCode": 0,
            "Error": "",
            "StartedAt": "2020-01-06T16:48:24.980986809Z",
            "FinishedAt": "0001-01-01T00:00:00Z"
        },
        "Image": "sha256:33e222a2826687f20448a3a7509c291c6212f2f8e22e4bd8c645f5b192747491",
        "ResolvConfPath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/resolv.conf",
        "HostnamePath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/hostname",
        "HostsPath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/hosts",
        "LogPath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d-json.log",
        "Name": "/drone1",
        "RestartCount": 0,
        "Driver": "overlay2",
        "Platform": "linux",
        "MountLabel": "",
        "ProcessLabel": "",
        "AppArmorProfile": "",
        "ExecIDs": null,
        "HostConfig": {
            "Binds": [
                "/var/lib/drone:/data"
            ],
            "ContainerIDFile": "",
            "LogConfig": {
                "Type": "json-file",
                "Config": {}
            },
            "NetworkMode": "default",
            "PortBindings": {
                "443/tcp": [
                    {
                        "HostIp": "",
                        "HostPort": "443"
                    }
                ],
                "80/tcp": [
                    {
                        "HostIp": "",
                        "HostPort": "80"
                    }
                ]
            },
            "RestartPolicy": {
                "Name": "always",
                "MaximumRetryCount": 0
            },
            "AutoRemove": false,
            "VolumeDriver": "",
            "VolumesFrom": null,
            "CapAdd": null,
            "CapDrop": null,
            "Capabilities": null,
            "Dns": [],
            "DnsOptions": [],
            "DnsSearch": [],
            "ExtraHosts": null,
            "GroupAdd": null,
            "IpcMode": "private",
            "Cgroup": "",
            "Links": null,
            "OomScoreAdj": 0,
            "PidMode": "",
            "Privileged": false,
            "PublishAllPorts": false,
            "ReadonlyRootfs": false,
            "SecurityOpt": null,
            "UTSMode": "",
            "UsernsMode": "",
            "ShmSize": 67108864,
            "Runtime": "runc",
            "ConsoleSize": [
                0,
                0
            ],
            "Isolation": "",
            "CpuShares": 0,
            "Memory": 0,
            "NanoCpus": 0,
            "CgroupParent": "",
            "BlkioWeight": 0,
            "BlkioWeightDevice": [],
            "BlkioDeviceReadBps": null,
            "BlkioDeviceWriteBps": null,
            "BlkioDeviceReadIOps": null,
            "BlkioDeviceWriteIOps": null,
            "CpuPeriod": 0,
            "CpuQuota": 0,
            "CpuRealtimePeriod": 0,
            "CpuRealtimeRuntime": 0,
            "CpusetCpus": "",
            "CpusetMems": "",
            "Devices": [],
            "DeviceCgroupRules": null,
            "DeviceRequests": null,
            "KernelMemory": 0,
            "KernelMemoryTCP": 0,
            "MemoryReservation": 0,
            "MemorySwap": 0,
            "MemorySwappiness": null,
            "OomKillDisable": false,
            "PidsLimit": null,
            "Ulimits": null,
            "CpuCount": 0,
            "CpuPercent": 0,
            "IOMaximumIOps": 0,
            "IOMaximumBandwidth": 0,
            "MaskedPaths": [
                "/proc/asound",
                "/proc/acpi",
                "/proc/kcore",
                "/proc/keys",
                "/proc/latency_stats",
                "/proc/timer_list",
                "/proc/timer_stats",
                "/proc/sched_debug",
                "/proc/scsi",
                "/sys/firmware"
            ],
            "ReadonlyPaths": [
                "/proc/bus",
                "/proc/fs",
                "/proc/irq",
                "/proc/sys",
                "/proc/sysrq-trigger"
            ]
        },
        "GraphDriver": {
            "Data": {
                "LowerDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33-init/diff:/var/lib/docker/overlay2/809b3642355ed9350db55ccc592a95f79690699d5ae7113312514523764ab26d/diff:/var/lib/docker/overlay2/66ac81678980d77faa711f439bfea02519ab613ca8c7b063806f79013684f855/diff:/var/lib/docker/overlay2/45760bbf6c2f8d966b9b0001dca3b4f8ad8128c8ba633822a3090472650c5ab0/diff:/var/lib/docker/overlay2/f0b073ae77ea612b069cfd77cf3aac828f0492abab20b2ec3f9ee3a9edd931d4/diff",
                "MergedDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33/merged",
                "UpperDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33/diff",
                "WorkDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33/work"
            },
            "Name": "overlay2"
        },
        "Mounts": [
            {
                "Type": "bind",
                "Source": "/var/lib/drone",
                "Destination": "/data",
                "Mode": "",
                "RW": true,
                "Propagation": "rprivate"
            }
        ],
        "Config": {
            "Hostname": "f85bc55b8262",
            "Domainname": "",
            "User": "",
            "AttachStdin": false,
            "AttachStdout": false,
            "AttachStderr": false,
            "ExposedPorts": {
                "443/tcp": {},
                "80/tcp": {}
            },
            "Tty": false,
            "OpenStdin": false,
            "StdinOnce": false,
            "Env": [
                "DRONE_AGENTS_ENABLED=true",
                "DRONE_LOGS_TRACE=true",
                "DRONE_GITHUB_SERVER=https://github.com",
                "DRONE_GITHUB_CLIENT_ID=96b395e91cea1f41eec8",
                "DRONE_GITHUB_CLIENT_SECRET=afa898b9b8675009d88239ec16b61362fcca6b3e",
                "DRONE_RPC_SECRET=c2bbd352ba3fc9d9da38e3d439da4899",
                "DRONE_SERVER_HOST=drone.domain.com",
                "DRONE_SERVER_PROTO=http",
                "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
                "GODEBUG=netdns=go",
                "XDG_CACHE_HOME=/data",
                "DRONE_DATABASE_DRIVER=sqlite3",
                "DRONE_DATABASE_DATASOURCE=/data/database.sqlite",
                "DRONE_RUNNER_OS=linux",
                "DRONE_RUNNER_ARCH=amd64",
                "DRONE_SERVER_PORT=:80",
                "DRONE_DATADOG_ENABLED=true",
                "DRONE_DATADOG_ENDPOINT=https://stats.drone.ci/api/v1/series"
            ],
            "Cmd": null,
            "Image": "drone/drone:1",
            "Volumes": {
                "/data": {}
            },
            "WorkingDir": "",
            "Entrypoint": [
                "/bin/drone-server"
            ],
            "OnBuild": null,
            "Labels": {
                "org.label-schema.build-date": "2019-12-30T02:20:31Z",
                "org.label-schema.schema-version": "1.0",
                "org.label-schema.vcs-ref": "c42273084f62309ef3cdce35a985e7f404335558",
                "org.label-schema.vcs-url": "https://github.com/drone/drone.git"
            }
        },
        "NetworkSettings": {
            "Bridge": "",
            "SandboxID": "d90a03824f67d51c69b547dc316cdf53d9d60ec752f9779b5332aa0545c75f57",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "443/tcp": [
                    {
                        "HostIp": "0.0.0.0",
                        "HostPort": "443"
                    }
                ],
                "80/tcp": [
                    {
                        "HostIp": "0.0.0.0",
                        "HostPort": "80"
                    }
                ]
            },
            "SandboxKey": "/var/run/docker/netns/d90a03824f67",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "c2ce3463be9a0c8ba59538fd62eb2776d42146c3a453dd99b22a1f5ddba5c673",
            "Gateway": "172.17.0.1",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "172.17.0.3",
            "IPPrefixLen": 16,
            "IPv6Gateway": "",
            "MacAddress": "02:42:ac:11:00:03",
            "Networks": {
                "bridge": {
                    "IPAMConfig": null,
                    "Links": null,
                    "Aliases": null,
                    "NetworkID": "07dfc7bc60b52984a4202e97d6bf5f3a5bfc11ecb387ae51f5385024f155926c",
                    "EndpointID": "c2ce3463be9a0c8ba59538fd62eb2776d42146c3a453dd99b22a1f5ddba5c673",
                    "Gateway": "172.17.0.1",
                    "IPAddress": "172.17.0.3",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:ac:11:00:03",
                    "DriverOpts": null
                }
            }
        }
    }
]
[
    {
        "Id": "f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d",
        "Created": "2020-01-06T16:48:24.581139914Z",
        "Path": "/bin/drone-server",
        "Args": [],
        "State": {
            "Status": "running",
            "Running": true,
            "Paused": false,
            "Restarting": false,
            "OOMKilled": false,
            "Dead": false,
            "Pid": 39021,
            "ExitCode": 0,
            "Error": "",
            "StartedAt": "2020-01-06T16:48:24.980986809Z",
            "FinishedAt": "0001-01-01T00:00:00Z"
        },
        "Image": "sha256:33e222a2826687f20448a3a7509c291c6212f2f8e22e4bd8c645f5b192747491",
        "ResolvConfPath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/resolv.conf",
        "HostnamePath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/hostname",
        "HostsPath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/hosts",
        "LogPath": "/var/lib/docker/containers/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d/f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d-json.log",
        "Name": "/drone1",
        "RestartCount": 0,
        "Driver": "overlay2",
        "Platform": "linux",
        "MountLabel": "",
        "ProcessLabel": "",
        "AppArmorProfile": "",
        "ExecIDs": null,
        "HostConfig": {
            "Binds": [
                "/var/lib/drone:/data"
            ],
            "ContainerIDFile": "",
            "LogConfig": {
                "Type": "json-file",
                "Config": {}
            },
            "NetworkMode": "default",
            "PortBindings": {
                "443/tcp": [
                    {
                        "HostIp": "",
                        "HostPort": "443"
                    }
                ],
                "80/tcp": [
                    {
                        "HostIp": "",
                        "HostPort": "80"
                    }
                ]
            },
            "RestartPolicy": {
                "Name": "always",
                "MaximumRetryCount": 0
            },
            "AutoRemove": false,
            "VolumeDriver": "",
            "VolumesFrom": null,
            "CapAdd": null,
            "CapDrop": null,
            "Capabilities": null,
            "Dns": [],
            "DnsOptions": [],
            "DnsSearch": [],
            "ExtraHosts": null,
            "GroupAdd": null,
            "IpcMode": "private",
            "Cgroup": "",
            "Links": null,
            "OomScoreAdj": 0,
            "PidMode": "",
            "Privileged": false,
            "PublishAllPorts": false,
            "ReadonlyRootfs": false,
            "SecurityOpt": null,
            "UTSMode": "",
            "UsernsMode": "",
            "ShmSize": 67108864,
            "Runtime": "runc",
            "ConsoleSize": [
                0,
                0
            ],
            "Isolation": "",
            "CpuShares": 0,
            "Memory": 0,
            "NanoCpus": 0,
            "CgroupParent": "",
            "BlkioWeight": 0,
            "BlkioWeightDevice": [],
            "BlkioDeviceReadBps": null,
            "BlkioDeviceWriteBps": null,
            "BlkioDeviceReadIOps": null,
            "BlkioDeviceWriteIOps": null,
            "CpuPeriod": 0,
            "CpuQuota": 0,
            "CpuRealtimePeriod": 0,
            "CpuRealtimeRuntime": 0,
            "CpusetCpus": "",
            "CpusetMems": "",
            "Devices": [],
            "DeviceCgroupRules": null,
            "DeviceRequests": null,
            "KernelMemory": 0,
            "KernelMemoryTCP": 0,
            "MemoryReservation": 0,
            "MemorySwap": 0,
            "MemorySwappiness": null,
            "OomKillDisable": false,
            "PidsLimit": null,
            "Ulimits": null,
            "CpuCount": 0,
            "CpuPercent": 0,
            "IOMaximumIOps": 0,
            "IOMaximumBandwidth": 0,
            "MaskedPaths": [
                "/proc/asound",
                "/proc/acpi",
                "/proc/kcore",
                "/proc/keys",
                "/proc/latency_stats",
                "/proc/timer_list",
                "/proc/timer_stats",
                "/proc/sched_debug",
                "/proc/scsi",
                "/sys/firmware"
            ],
            "ReadonlyPaths": [
                "/proc/bus",
                "/proc/fs",
                "/proc/irq",
                "/proc/sys",
                "/proc/sysrq-trigger"
            ]
        },
        "GraphDriver": {
            "Data": {
                "LowerDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33-init/diff:/var/lib/docker/overlay2/809b3642355ed9350db55ccc592a95f79690699d5ae7113312514523764ab26d/diff:/var/lib/docker/overlay2/66ac81678980d77faa711f439bfea02519ab613ca8c7b063806f79013684f855/diff:/var/lib/docker/overlay2/45760bbf6c2f8d966b9b0001dca3b4f8ad8128c8ba633822a3090472650c5ab0/diff:/var/lib/docker/overlay2/f0b073ae77ea612b069cfd77cf3aac828f0492abab20b2ec3f9ee3a9edd931d4/diff",
                "MergedDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33/merged",
                "UpperDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33/diff",
                "WorkDir": "/var/lib/docker/overlay2/bcc824243b78d76d4f7287c275c5e235f317025a9200494aec42b55faf42fa33/work"
            },
            "Name": "overlay2"
        },
        "Mounts": [
            {
                "Type": "bind",
                "Source": "/var/lib/drone",
                "Destination": "/data",
                "Mode": "",
                "RW": true,
                "Propagation": "rprivate"
            }
        ],
        "Config": {
            "Hostname": "f85bc55b8262",
            "Domainname": "",
            "User": "",
            "AttachStdin": false,
            "AttachStdout": false,
            "AttachStderr": false,
            "ExposedPorts": {
                "443/tcp": {},
                "80/tcp": {}
            },
            "Tty": false,
            "OpenStdin": false,
            "StdinOnce": false,
            "Env": [
                "DRONE_AGENTS_ENABLED=true",
                "DRONE_LOGS_TRACE=true",
                "DRONE_GITHUB_SERVER=https://github.com",
                "DRONE_GITHUB_CLIENT_ID=96b395e91cea1f41eec8",
                "DRONE_GITHUB_CLIENT_SECRET=afa898b9b8675009d88239ec16b61362fcca6b3e",
                "DRONE_RPC_SECRET=c2bbd352ba3fc9d9da38e3d439da4899",
                "DRONE_SERVER_HOST=drone.domain.com",
                "DRONE_SERVER_PROTO=http",
                "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
                "GODEBUG=netdns=go",
                "XDG_CACHE_HOME=/data",
                "DRONE_DATABASE_DRIVER=sqlite3",
                "DRONE_DATABASE_DATASOURCE=/data/database.sqlite",
                "DRONE_RUNNER_OS=linux",
                "DRONE_RUNNER_ARCH=amd64",
                "DRONE_SERVER_PORT=:80",
                "DRONE_DATADOG_ENABLED=true",
                "DRONE_DATADOG_ENDPOINT=https://stats.drone.ci/api/v1/series"
            ],
            "Cmd": null,
            "Image": "drone/drone:1",
            "Volumes": {
                "/data": {}
            },
            "WorkingDir": "",
            "Entrypoint": [
                "/bin/drone-server"
            ],
            "OnBuild": null,
            "Labels": {
                "org.label-schema.build-date": "2019-12-30T02:20:31Z",
                "org.label-schema.schema-version": "1.0",
                "org.label-schema.vcs-ref": "c42273084f62309ef3cdce35a985e7f404335558",
                "org.label-schema.vcs-url": "https://github.com/drone/drone.git"
            }
        },
        "NetworkSettings": {
            "Bridge": "",
            "SandboxID": "d90a03824f67d51c69b547dc316cdf53d9d60ec752f9779b5332aa0545c75f57",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "443/tcp": [
                    {
                        "HostIp": "0.0.0.0",
                        "HostPort": "443"
                    }
                ],
                "80/tcp": [
                    {
                        "HostIp": "0.0.0.0",
                        "HostPort": "80"
                    }
                ]
            },
            "SandboxKey": "/var/run/docker/netns/d90a03824f67",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "c2ce3463be9a0c8ba59538fd62eb2776d42146c3a453dd99b22a1f5ddba5c673",
            "Gateway": "172.17.0.1",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "172.17.0.3",
            "IPPrefixLen": 16,
            "IPv6Gateway": "",
            "MacAddress": "02:42:ac:11:00:03",
            "Networks": {
                "bridge": {
                    "IPAMConfig": null,
                    "Links": null,
                    "Aliases": null,
                    "NetworkID": "07dfc7bc60b52984a4202e97d6bf5f3a5bfc11ecb387ae51f5385024f155926c",
                    "EndpointID": "c2ce3463be9a0c8ba59538fd62eb2776d42146c3a453dd99b22a1f5ddba5c673",
                    "Gateway": "172.17.0.1",
                    "IPAddress": "172.17.0.3",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:ac:11:00:03",
                    "DriverOpts": null
                }
            }
        }
    }
]

drone.yml config

kind: pipeline
type: docker
name: default
steps:
  - name: build
    image: node:alpine
    commands:
      - npm install
      - npm run build
      - echo $DRONE_COMMIT > version.txt
  - name: unit tests
    image: node:alpine
    commands:
       - npm run test
trigger:
   branch:
     - master

are you running Drone and Gitea on the same machine? If so you need to make sure they are on the same Docker network, otherwise they cannot communicate with one another. Also note that, in general, we do not recommend running the server and runner on the same machine.

It’s on the same machine. I’m not using Gitea, I’m using Github.

Also I create a network to connect the containers:

[
    {
        "Name": "droneci",
        "Id": "349155746cf7c91d98bda3b64f4cbb92b45cf26b38aae20fe46cc4cb6bf8cb35",
        "Created": "2020-01-06T15:28:18.372911326-03:00",
        "Scope": "local",
        "Driver": "bridge",
        "EnableIPv6": false,
        "IPAM": {
            "Driver": "default",
            "Options": {},
            "Config": [
                {
                    "Subnet": "172.18.0.0/16",
                    "Gateway": "172.18.0.1"
                }
            ]
        },
        "Internal": false,
        "Attachable": false,
        "Ingress": false,
        "ConfigFrom": {
            "Network": ""
        },
        "ConfigOnly": false,
        "Containers": {
            "6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d": {
                "Name": "runner",
                "EndpointID": "f7ac751f1915e263fb9b5c812ac74d011dc89f50e2885f6f5f0d7cf35d8d445e",
                "MacAddress": "02:42:ac:12:00:03",
                "IPv4Address": "172.18.0.3/16",
                "IPv6Address": ""
            },
            "f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d": {
                "Name": "drone1",
                "EndpointID": "27d423d9a7ac7719b02713d0a12e3a32dd02ceb68a84631c879f2be0a221bca4",
                "MacAddress": "02:42:ac:12:00:02",
                "IPv4Address": "172.18.0.2/16",
                "IPv6Address": ""
            }
        },
        "Options": {},
        "Labels": {}
    }
]

After this, the problems continues… :cry:

the output of your docker inspect for the runner looks incorrect, since it shows you are running the drone server. Perhaps you posted the wrong output?

[
    {
        "Id": "f85bc55b8262bdba5f019867f066d58ceb3ad61b69fa8cddc2b782213c93a60d",
        "Created": "2020-01-06T16:48:24.581139914Z",
        "Path": "/bin/drone-server",

There are only three reasons the agent cannot ping the server:

  1. problem with networking (this is the most likely root cause)
  2. incorrect host address
  3. incorrect secret

Once you provide the correct docker inspect for the runner it will hopefully provide more details. However, one thing I noticed is that the runner seems to be trying to ping an address that is returning a webpage with jquery. Drone does not use jquery. Perhaps you have the wrong server address, or perhaps you have a reverse proxy or something that is improperly routing requests? Either way, this html page does not come from Drone.

<!DOCTYPE HTML>\r\n<html>\r\n\r\n    <head>\r\n        <title>404 Error - Page Not Found</title>\r\n        <style>\r\n            #ad_frame{ height:800px; width:100%; }\r\n            body{ margin:0; border: 0; padding: 0; }\r\n        </style>\r\n        <script src=\"//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js\"></script>\r\n

If you continue to experience difficultly you might also consider finding a docker-compose file in the forum that you can re-use, to ensure everything is configured properly.

Probably I post the wrong output to docker inspect runner, below it is the correct.

[
    {
        "Id": "6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d",
        "Created": "2020-01-06T14:53:14.520374535Z",
        "Path": "/bin/drone-runner-docker",
        "Args": [],
        "State": {
            "Status": "running",
            "Running": true,
            "Paused": false,
            "Restarting": false,
            "OOMKilled": false,
            "Dead": false,
            "Pid": 58319,
            "ExitCode": 0,
            "Error": "",
            "StartedAt": "2020-01-06T18:31:52.303516647Z",
            "FinishedAt": "2020-01-06T18:31:51.587427516Z"
        },
        "Image": "sha256:25d039088d35d66e76ee2e657f75c2100880ffb8c94fb2c2534a36b7c6a124c6",
        "ResolvConfPath": "/var/lib/docker/containers/6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d/resolv.conf",
        "HostnamePath": "/var/lib/docker/containers/6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d/hostname",
        "HostsPath": "/var/lib/docker/containers/6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d/hosts",
        "LogPath": "/var/lib/docker/containers/6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d/6e8261cea3accd6241f1f0b8f874adbb7dea46eeb3719e17057ab73014eeea2d-json.log",
        "Name": "/runner",
        "RestartCount": 0,
        "Driver": "overlay2",
        "Platform": "linux",
        "MountLabel": "",
        "ProcessLabel": "",
        "AppArmorProfile": "",
        "ExecIDs": null,
        "HostConfig": {
            "Binds": [
                "/var/run/docker.sock:/var/run/docker.sock"
            ],
            "ContainerIDFile": "",
            "LogConfig": {
                "Type": "json-file",
                "Config": {}
            },
            "NetworkMode": "default",
            "PortBindings": {
                "3000/tcp": [
                    {
                        "HostIp": "",
                        "HostPort": "3000"
                    }
                ]
            },
            "RestartPolicy": {
                "Name": "always",
                "MaximumRetryCount": 0
            },
            "AutoRemove": false,
            "VolumeDriver": "",
            "VolumesFrom": null,
            "CapAdd": null,
            "CapDrop": null,
            "Capabilities": null,
            "Dns": [],
            "DnsOptions": [],
            "DnsSearch": [],
            "ExtraHosts": null,
            "GroupAdd": null,
            "IpcMode": "private",
            "Cgroup": "",
            "Links": null,
            "OomScoreAdj": 0,
            "PidMode": "",
            "Privileged": false,
            "PublishAllPorts": false,
            "ReadonlyRootfs": false,
            "SecurityOpt": null,
            "UTSMode": "",
            "UsernsMode": "",
            "ShmSize": 67108864,
            "Runtime": "runc",
            "ConsoleSize": [
                0,
                0
            ],
            "Isolation": "",
            "CpuShares": 0,
            "Memory": 0,
            "NanoCpus": 0,
            "CgroupParent": "",
            "BlkioWeight": 0,
            "BlkioWeightDevice": [],
            "BlkioDeviceReadBps": null,
            "BlkioDeviceWriteBps": null,
            "BlkioDeviceReadIOps": null,
            "BlkioDeviceWriteIOps": null,
            "CpuPeriod": 0,
            "CpuQuota": 0,
            "CpuRealtimePeriod": 0,
            "CpuRealtimeRuntime": 0,
            "CpusetCpus": "",
            "CpusetMems": "",
            "Devices": [],
            "DeviceCgroupRules": null,
            "DeviceRequests": null,
            "KernelMemory": 0,
            "KernelMemoryTCP": 0,
            "MemoryReservation": 0,
            "MemorySwap": 0,
            "MemorySwappiness": null,
            "OomKillDisable": false,
            "PidsLimit": null,
            "Ulimits": null,
            "CpuCount": 0,
            "CpuPercent": 0,
            "IOMaximumIOps": 0,
            "IOMaximumBandwidth": 0,
            "MaskedPaths": [
                "/proc/asound",
                "/proc/acpi",
                "/proc/kcore",
                "/proc/keys",
                "/proc/latency_stats",
                "/proc/timer_list",
                "/proc/timer_stats",
                "/proc/sched_debug",
                "/proc/scsi",
                "/sys/firmware"
            ],
            "ReadonlyPaths": [
                "/proc/bus",
                "/proc/fs",
                "/proc/irq",
                "/proc/sys",
                "/proc/sysrq-trigger"
            ]
        },
        "GraphDriver": {
            "Data": {
                "LowerDir": "/var/lib/docker/overlay2/33bc8fd500cea6f5f887767eff554b41d3b489ec267438982628f13f0f3e5595-init/diff:/var/lib/docker/overlay2/c351d827f1d35b15dd17081d742a4aa238595fef05bf1684bcbd6dc2c05ca50e/diff:/var/lib/docker/overlay2/1d99d3847fa8ca251d2b3fcdfd5d3034b1b18fa9677baa91ac1e0c939891f192/diff:/var/lib/docker/overlay2/c96f7151155bd9a15c4c2dce6bd6ab23ced43c71a15bde4be687d8afd37d65a4/diff",
                "MergedDir": "/var/lib/docker/overlay2/33bc8fd500cea6f5f887767eff554b41d3b489ec267438982628f13f0f3e5595/merged",
                "UpperDir": "/var/lib/docker/overlay2/33bc8fd500cea6f5f887767eff554b41d3b489ec267438982628f13f0f3e5595/diff",
                "WorkDir": "/var/lib/docker/overlay2/33bc8fd500cea6f5f887767eff554b41d3b489ec267438982628f13f0f3e5595/work"
            },
            "Name": "overlay2"
        },
        "Mounts": [
            {
                "Type": "bind",
                "Source": "/var/run/docker.sock",
                "Destination": "/var/run/docker.sock",
                "Mode": "",
                "RW": true,
                "Propagation": "rprivate"
            }
        ],
        "Config": {
            "Hostname": "6e8261cea3ac",
            "Domainname": "",
            "User": "",
            "AttachStdin": false,
            "AttachStdout": false,
            "AttachStderr": false,
            "ExposedPorts": {
                "3000/tcp": {}
            },
            "Tty": false,
            "OpenStdin": false,
            "StdinOnce": false,
            "Env": [
                "DRONE_RPC_HOST=drone.domain.com",
                "DRONE_RPC_SECRET=c2bbd352ba3fc9d9da38e3d439da4899",
                "DRONE_RUNNER_CAPACITY=2",
                "DRONE_RUNNER_NAME=drone-testing",
                "DRONE_TRACE=true",
                "DRONE_RPC_PROTO=http",
                "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
                "GODEBUG=netdns=go",
                "DRONE_PLATFORM_OS=linux",
                "DRONE_PLATFORM_ARCH=amd64"
            ],
            "Cmd": null,
            "Image": "drone/drone-runner-docker:1",
            "Volumes": null,
            "WorkingDir": "",
            "Entrypoint": [
                "/bin/drone-runner-docker"
            ],
            "OnBuild": null,
            "Labels": {
                "com.centurylinklabs.watchtower.stop-signal": "SIGINT",
                "org.label-schema.build-date": "2019-12-11T21:43:25Z",
                "org.label-schema.schema-version": "1.0",
                "org.label-schema.vcs-ref": "adda9d7f38d4cd8e3f60a983810fd2914e6f184b",
                "org.label-schema.vcs-url": "https://github.com/drone-runners/drone-runner-docker.git"
            }
        },
        "NetworkSettings": {
            "Bridge": "",
            "SandboxID": "b0e5d22ba76752a4cdfbd1b4d85d80c33bed2da9be0e09f56d528b9e67e5e079",
            "HairpinMode": false,
            "LinkLocalIPv6Address": "",
            "LinkLocalIPv6PrefixLen": 0,
            "Ports": {
                "3000/tcp": [
                    {
                        "HostIp": "0.0.0.0",
                        "HostPort": "3000"
                    }
                ]
            },
            "SandboxKey": "/var/run/docker/netns/b0e5d22ba767",
            "SecondaryIPAddresses": null,
            "SecondaryIPv6Addresses": null,
            "EndpointID": "144b2e6b2e478cf5309aa800c9d7ddb23f789792559c709b0b6c08b52a5113b8",
            "Gateway": "172.17.0.1",
            "GlobalIPv6Address": "",
            "GlobalIPv6PrefixLen": 0,
            "IPAddress": "172.17.0.2",
            "IPPrefixLen": 16,
            "IPv6Gateway": "",
            "MacAddress": "02:42:ac:11:00:02",
            "Networks": {
                "bridge": {
                    "IPAMConfig": null,
                    "Links": null,
                    "Aliases": null,
                    "NetworkID": "07dfc7bc60b52984a4202e97d6bf5f3a5bfc11ecb387ae51f5385024f155926c",
                    "EndpointID": "144b2e6b2e478cf5309aa800c9d7ddb23f789792559c709b0b6c08b52a5113b8",
                    "Gateway": "172.17.0.1",
                    "IPAddress": "172.17.0.2",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:ac:11:00:02",
                    "DriverOpts": null
                },
                "droneci": {
                    "IPAMConfig": {},
                    "Links": null,
                    "Aliases": [
                        "6e8261cea3ac"
                    ],
                    "NetworkID": "349155746cf7c91d98bda3b64f4cbb92b45cf26b38aae20fe46cc4cb6bf8cb35",
                    "EndpointID": "8360b6328f9fdd24e01d9db07237ec8ea130c5224afb06f76b0eceb89944aec5",
                    "Gateway": "172.18.0.1",
                    "IPAddress": "172.18.0.3",
                    "IPPrefixLen": 16,
                    "IPv6Gateway": "",
                    "GlobalIPv6Address": "",
                    "GlobalIPv6PrefixLen": 0,
                    "MacAddress": "02:42:ac:12:00:03",
                    "DriverOpts": {}
                }
            }
        }
    }
]

How to discover if I have a reverse proxy or something like that?

Thanks for helping.

I see you have drone.company.com and drone.domain.com which are not your real hostname. You should replace these values (for both the server and runner) with your actual hostname or IP.