You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by kl...@apache.org on 2018/10/26 23:51:44 UTC

[mesos] branch 1.6.x updated: Fixed bug in 'execute.cpp' with tty-based tasks and no 'containerInfo'.

This is an automated email from the ASF dual-hosted git repository.

klueska pushed a commit to branch 1.6.x
in repository https://gitbox.apache.org/repos/asf/mesos.git


The following commit(s) were added to refs/heads/1.6.x by this push:
     new f272bcb  Fixed bug in 'execute.cpp' with tty-based tasks and no 'containerInfo'.
f272bcb is described below

commit f272bcb6521423d4980f4beaf2c49bd5697b1c90
Author: Kevin Klues <kl...@gmail.com>
AuthorDate: Fri Oct 26 16:49:32 2018 -0700

    Fixed bug in 'execute.cpp' with tty-based tasks and no 'containerInfo'.
    
    Previously, we could only launch tasks using the '--tty' flag if they
    had a backing docker image (or some other combination of other flags set
    that would cause the task to have a 'containerInfo' created for it).
    
    This commit makes sure that if '--tty' is passed, that a containerInfo
    gets created and its TTYInfo field gets populated.
    
    Review: https://reviews.apache.org/r/69103/
---
 src/cli/execute.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/cli/execute.cpp b/src/cli/execute.cpp
index 9e7c511..521a9df 100644
--- a/src/cli/execute.cpp
+++ b/src/cli/execute.cpp
@@ -810,7 +810,8 @@ static Result<ContainerInfo> getContainerInfo(
 
   // Mesos containerizer supports 'appc' and 'docker' images.
   if (containerizer == "mesos") {
-    if (appcImage.isNone() &&
+    if (!tty &&
+        appcImage.isNone() &&
         dockerImage.isNone() &&
         effective_capabilities.isNone() &&
         bounding_capabilities.isNone() &&