Terraform Cloud "No agents are available" agent pool in CI
The workspace uses Agent execution mode, so runs execute on a self-hosted HCP Terraform agent, not on HashiCorp infrastructure. The run queues but no agent in the assigned pool is connected, so it waits or fails.
What this error means
A remote run for an agent-mode workspace sits pending or fails with a message that no agents are available in the assigned agent pool.
No agents are available in the pool "self-hosted-prod" assigned to this
workspace. The run will remain pending until an agent connects.Common causes
No agent is connected to the pool
Agent-mode runs need at least one running, registered agent in the assigned pool. If all agents are down, runs never start.
The workspace points at the wrong pool
The workspace is assigned an agent pool that has no capacity, while agents are actually running in a different pool.
How to fix it
Bring an agent online in the pool
- Start a
tfc-agentinstance registered to the assigned pool. - Confirm it shows as connected in the agent pool page.
- Re-queue the run so an available agent picks it up.
docker run -e TFC_AGENT_TOKEN=${TFC_AGENT_TOKEN} \
-e TFC_AGENT_NAME=ci-agent-1 hashicorp/tfc-agent:latestAssign the workspace to a live pool
Point the workspace at the agent pool that actually has connected agents, or switch it to Remote execution if agents are not needed.
How to prevent it
- Keep at least one agent connected per pool CI depends on.
- Alert on agent pool capacity so a dead pool is noticed early.
- Only use Agent mode where private networking requires it.