style95 commented on a change in pull request #4430: Update docker client 
version to 18.06.3
URL: 
https://github.com/apache/incubator-openwhisk/pull/4430#discussion_r280305236
 
 

 ##########
 File path: ansible/roles/invoker/tasks/clean.yml
 ##########
 @@ -21,9 +21,9 @@
 - name: pause/resume at runc-level to restore docker consistency
   shell: |
         DOCKER_PAUSED=$(docker ps --filter status=paused --filter name=wsk{{ 
invoker_index }} -q --no-trunc)
-        for C in $DOCKER_PAUSED; do docker-runc pause $C; done
+        for C in $DOCKER_PAUSED; do docker-runc --root {{ 
invoker.docker.runcdir }} pause $C; done
 
 Review comment:
   This comes from newer version Docker.
   In the newer version of runc, it respects an environment variable, 
`XDG_RUNTIME_DIR`.
   (Reference: https://github.com/opencontainers/runc/blob/master/main.go#L67)
   
   Since that environment variable differs based on the current user, non-root 
users cannot unpause or resume containers with the previous command.
   
   ```
   style95@ubuntu:~/git/openwhisk/ansible$ docker-runc --help | grep "root dir"
      --root value        root directory for storage of container state (this 
should be located in tmpfs) (default: "/run/user/1000/runc")
   style95@ubuntu:~/git/openwhisk/ansible$ sudo docker-runc --help | grep "root 
dir"
      --root value        root directory for storage of container state (this 
should be located in tmpfs) (default: "/run/runc")
   ```
   (Even, the location of root dir in docker 18.06 is 
`/run/docker/runtime-runc/moby`.)
   
   So I explicitly configured this value.
   
   
   

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


With regards,
Apache Git Services

Reply via email to