Reputation: 3209
I am trying to submit the following job to my nomad server. The job basically uses a payload which is a python file from my localhost.
job "agent-collector-bot" {
datacenters = ["staging"]
type = "batch"
periodic {
cron = "*/10 * * * *"
prohibit_overlap = true
}
group "python-bot" {
count = 1
task "slack-bot" {
driver = "raw_exec"
config {
command = "python"
args = ["local/agent-collector-slackbot.py"]
}
dispatch_payload {
file = "agent-collector-slackbot.py"
}
}
}
}
Now when i see the job status in nomad it says:
snomad status agent-collector-bot/
ID = agent-collector-bot/periodic-1512465000
Name = agent-collector-bot/periodic-1512465000
Submit Date = 12/05/17 14:40:00 IST
Type = batch
Priority = 50
Datacenters = staging
Status = pending
Periodic = false
Parameterized = false
Summary
Task Group Queued Starting Running Failed Complete Lost
python-bot 1 0 0 0 0 0
Placement Failure
Task Group "python-bot":
* Constraint "missing drivers" filtered 5 nodes
I checked my nomad clients (all 5) are having python on it.. can someone help me out?
Upvotes: 2
Views: 1975
Reputation: 960
The driver specified in the output is raw_exec
, not python.
You need to enable it in your client config (nomad raw_exec docs)
client {
options = {
"driver.raw_exec.enable" = "1"
}
}
Upvotes: 3