rabbah commented on a change in pull request #2524: Docker for mac support
URL: 
https://github.com/apache/incubator-openwhisk/pull/2524#discussion_r131037992
 
 

 ##########
 File path: ansible/roles/invoker/tasks/deploy.yml
 ##########
 @@ -39,20 +55,42 @@
 - name: define options when deploying invoker on Ubuntu
   set_fact:
     linuxOptions: "-v 
/usr/lib/x86_64-linux-gnu/libapparmor.so.1:/usr/lib/x86_64-linux-gnu/libapparmor.so.1"
-  when: whisk_version_name != "mac"
+  when: ansible_distribution == "Ubuntu"
 
 - name: get running invoker information
   uri: url="http://{{ inventory_hostname }}:{{ docker.port 
}}/containers/json?filters={{ '{"name":[ "invoker" ]}' | urlencode }}" 
return_content=yes
-  register: invokerInfo
+  register: invokerInfo_output
+  when: whisk_version_name == "mac"
+
+- set_fact:
+    invokerInfo: "{{ invokerInfo_output['json'] }}"
+  when: whisk_version_name == "mac"
+
+- name: "get invoker info"
+  shell: |
+    INFO=`echo -e "GET http:/v1.24/containers/json?filters={{ '{"name":[ 
"invoker" ]}' | urlencode }} HTTP/1.0\r\n" | nc -U /var/run/docker.sock | grep 
"{"`
+    if [ -z "$INFO" ]; then
+      echo []
+    else
+      echo $INFO
+    fi
+  args:
+    executable: /bin/bash
+  register: invokerInfo_output
+  when: whisk_version_name != "mac"
 
 Review comment:
   and here.
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to