Build stuck: `Still waiting to schedule task. ‘Jenkins’ doesn’t have label ‘docker’`
BeginnerTroubleshootingAgents, executors & the queue
Answer
Likely causes → No node or pod template has the label docker; the label is misspelled; the agent with that label was removed.
Diagnose →
curl -s -u admin:$TOKEN "https://jenkins/computer/api/json?tree=computer[displayName,offline,assignedLabels[name]]" | jq
Also check Manage Jenkins > Clouds pod template labels.
Fix → Add the label to the right node or pod template, or fix the Jenkinsfile label expression.
Prevent → Keep labels documented and managed in JCasC.
More on Agents, executors & the queue
`Waiting for next available executor on ‘linux’` for 20 minutes during peak hoursBeginner`All nodes of label ‘windows’ are offline`Beginner`hudson.remoting.ChannelClosedException: Channel "hudson.remoting.Channel@6e4b:agent-07": Remote call on agent-07 failed. The channel is closing down or has closed down`IntermediateInbound agent fails: `SEVERE: http://jenkins:8080/tcpSlaveAgentListener/ is invalid: 404 Not Found`IntermediateAgent connects but builds fail with `java.io.IOException: Cannot run program "nohup" (in directory "C:\jenkins\workspace\app"): CreateProcess error=2`Beginner`Building on the built-in node can be a security issue. You should set up distributed builds.` warning, and some jobs still run thereBeginner