> On Jan. 22, 2018, 9:55 p.m., Joseph Wu wrote:
> > src/checks/checker_process.cpp
> > Lines 479-481 (original), 479-487 (patched)
> > <https://reviews.apache.org/r/65127/diff/4/?file=1941032#file1941032line479>
> >
> >     This is a bit unexpected.  Considering that these arguments will be 
> > joined a few lines down, how is the quoting maintained?
> 
> Akash Gupta wrote:
>     It's a bit weird. The implementation of `subprocess` for a shell command 
> creates an argument list that looks like this: `{os::shell::arg0, 
> os::shell::arg1, <command>}`. So, in Windows, `<command>` will then get 
> quoted when it transforms `argv` into a single command line for 
> `CreateProcess`. If you add the quotes here, it won't work, since you will 
> have double quotes.

I looked further into this. I'm not sure why the `docker exec` command was 
wrapped in a shell command. This causes issues with quoting on Windows. It 
seems better do `.set_shell(false)` and then set the arguments properly.


- Akash


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/65127/#review195942
-----------------------------------------------------------


On Jan. 29, 2018, 6:33 p.m., Akash Gupta wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/65127/
> -----------------------------------------------------------
> 
> (Updated Jan. 29, 2018, 6:33 p.m.)
> 
> 
> Review request for mesos, Alexander Rukletsov and Andrew Schwartzmeyer.
> 
> 
> Bugs: MESOS-8498
>     https://issues.apache.org/jira/browse/MESOS-8498
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> The network health checks called curl and then executed setns to
> enter to container network namespace, which did not work on Windows.
> To do the equivalent, Windows nows calls docker run with powershell's
> curl equivalent (Invoke-WebRequest) and uses the
> network=container:<ID> flag to enter the container's namespace.
> 
> 
> Diffs
> -----
> 
>   src/checks/checker_process.hpp 510f3b2e6e689faaf26595214ce377c2b5518f28 
>   src/checks/checker_process.cpp ddb197b8cc2c503fef5ae20af32f5881fff9833f 
> 
> 
> Diff: https://reviews.apache.org/r/65127/diff/5/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Akash Gupta
> 
>

Reply via email to