-
Notifications
You must be signed in to change notification settings - Fork 0
Make 'exec' arguments consistent between k8s and dev/local #52
Comments
Super low priority in my mind, but ready for your eyes nonetheless @regisb. |
I agree that the fact that
This works in the simple cases, but fails with arguments that include spaces. For example:
Again, that would require that we space-split the arguments before passing them to I think that we should not attempt to do better than what our shells already do, outside of Docker. If you attempt to run
Instead, if people want to pass arguments as strings, then we should encourage them to wrap them in
which would then become in tutor:
|
Good point. Forget my proposed solution.
So we will fix this 👍🏻 The simplest fix I can image would tweak the
whereas this would continue to fail:
The end state would be somewhat inconsistent, yet backwards-compatible. Does that sound good? I can provide a PR if it'd make discussion easier. |
Previously, the `k8s exec` command did not support unknown "--options". This made it impossible to launch, say, a django shell in the lms container. While implementing this feature we saw an opportunity to simplify the way jobs are handled in the k8s commands. Close #636. Another related issue is: openedx-unsupported/wg-developer-experience#52
Previously, the `k8s exec` command did not support unknown "--options". This made it impossible to launch, say, a django shell in the lms container. While implementing this feature we saw an opportunity to simplify the way jobs are handled in the k8s commands. Close #636. Another related issue is: openedx-unsupported/wg-developer-experience#52
Will be fixed in overhangio/tutor#637 |
Previously, the `k8s exec` command did not support unknown "--options". This made it impossible to launch, say, a django shell in the lms container. While implementing this feature we saw an opportunity to simplify the way jobs are handled in the k8s commands. Close #636. Another related issue is: openedx-unsupported/wg-developer-experience#52
Context
The command
tutor k8s exec SERVICE COMMAND
expects the COMMAND's arguments to be contained within the COMMAND string. For example:In comparison,
tutor (dev|local) exec SERVICE COMMAND ARGS...
expects the COMMAND's arguments to be provided separately, in ARGS:Could we make these consistent, without breaking backwards compatibility?
Idea:
exec mysql 'bash -e'
would always work.exec mysql bash -e
would always work.tutor (k8s|local|dev) exec 'bash -e' -x
would be equivalent totutor (k8s|local|dev) exec 'bash -e -x'
would be equivalent totutor (k8s|local|dev) exec bash -e -x
.tutor (local|dev) run
for the sake of consistency, even thoughtutor k8s run
doesn't exit.Acceptance
TBD
The text was updated successfully, but these errors were encountered: