keith-turner commented on a change in pull request #346:
URL: https://github.com/apache/fluo-muchos/pull/346#discussion_r421806129



##########
File path: ansible/docker.yml
##########
@@ -24,7 +24,7 @@
   tasks:
     - name: get swarm status
       shell: >
-        set -o pipefail && docker info | egrep '^Swarm: ' | cut -d ' ' -f 2
+        set -o pipefail && docker info | grep 'Swarm' | sed 's/\s*Swarm\:\s//'

Review comment:
       Seems like the sed regex is expecting a `:` after Swarm, so I was 
thinking the grep could also have this to make it more specific.  Also was 
wondering if would make sense to do `\s*` after `Swarm\:` in the sed regex.
   
   ```suggestion
           set -o pipefail && docker info | grep 'Swarm:' | sed 
's/\s*Swarm\:\s*//'
   ```




----------------------------------------------------------------
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