cf-natali commented on a change in pull request #383:
URL: https://github.com/apache/mesos/pull/383#discussion_r644309287



##########
File path: src/python/cli_new/lib/cli/plugins/task/main.py
##########
@@ -106,12 +108,13 @@ def list(self, argv):
         # pylint: disable=unused-argument
         try:
             master = self.config.master()
+            config = self.config

Review comment:
       OK!

##########
File path: src/python/cli_new/lib/cli/config.py
##########
@@ -119,6 +120,79 @@ def master(self):
 
         return master
 
+    def principal(self):
+        """
+        Return the principal in the configuration file
+        """
+        return self.data["master"].get("principal")
+
+    def secret(self):
+        """
+        Return the secret in the configuration file
+        """
+        return self.data["master"].get("secret")
+
+    def agent_ssl(self, default=False):
+        """
+        Return if the agent support ssl
+        """
+        if "agent" in self.data:
+            agent_ssl = self.data["agent"].get("ssl", default)
+            if not isinstance(agent_ssl, bool):
+                raise CLIException("The 'agent->ssl' field"
+                                   " must be True/False")
+
+            return agent_ssl
+
+        return default

Review comment:
       Up to you, I'm fine either way :).




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to