You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CentOS Linux release 7.2.1511 (Core)
Linux lees-remote-dev 3.10.0-327.10.1.el7.x86_64 #1 SMP Tue Feb 16 17:03:50 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Issue
I created a task with the same name as my image. When using a slash in a task name running the job fails with the error:
2016/04/28 22:06:24 [ERR] client: failed to start task 'amos/build-8' for alloc 'd60c2cd5-5e61-6105-7386-ec23fc266d28': error creating rpc client for executor plugin: plugin exited before we could connect
It wasn't immediately clear that the slash was the problem until I saw the logs. Perhaps it would be good to do some or all of the following:
support this by running os.MkdirAll
sanitize the name before using it in a path. e.g. slugify it
check the config and report an accurate error
add additional details to the documentation that note the task name is used to create files on disk
I'd be happy to contribute a patch if someone has some direction on the best solution(s).
Reproduction steps
Create a job with a task name with a slash.
Nomad Server logs
2016/04/28 22:06:24 [DEBUG] driver.docker: identified image 127.0.0.1:5000/amos/build-8 as sha256:c73e3f8ce8c8efe2fc48a601d2ce001fbdbc0f898928da1eb3ffeb9579d4bd7e
2016/04/28 22:06:24 [DEBUG] plugin: starting plugin: /usr/local/bin/nomad []string{"/usr/local/bin/nomad", "executor", "/run/nomad/alloc/d60c2cd5-5e61-6105-7386-ec23fc266d28/amos/build-8/amos/build-8-executor.out"}
2016/04/28 22:06:24 [DEBUG] plugin: waiting for RPC address for: /usr/local/bin/nomad
2016/04/28 22:06:24 [DEBUG] plugin: nomad: open /run/nomad/alloc/d60c2cd5-5e61-6105-7386-ec23fc266d28/amos/build-8/amos/build-8-executor.out: no such file or directory
2016/04/28 22:06:24 [DEBUG] plugin: /usr/local/bin/nomad: plugin process exited
I think our best path forward is disallowing tasks containing the slash from being submitted. This can be accomplished by patching the validation logic.
I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Nomad version
Nomad v0.3.2
Operating system and Environment details
CentOS Linux release 7.2.1511 (Core)
Linux lees-remote-dev 3.10.0-327.10.1.el7.x86_64 #1 SMP Tue Feb 16 17:03:50 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Issue
I created a task with the same name as my image. When using a slash in a task name running the job fails with the error:
It wasn't immediately clear that the slash was the problem until I saw the logs. Perhaps it would be good to do some or all of the following:
os.MkdirAll
I'd be happy to contribute a patch if someone has some direction on the best solution(s).
Reproduction steps
Create a job with a task name with a slash.
Nomad Server logs
Job file
Bad job
Good job
The text was updated successfully, but these errors were encountered: