Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker-out-of-Docker (DooD) Solution #5

Closed
3 tasks done
sebastientourbier opened this issue Nov 8, 2019 · 2 comments
Closed
3 tasks done

Docker-out-of-Docker (DooD) Solution #5

sebastientourbier opened this issue Nov 8, 2019 · 2 comments
Labels
enhancement New feature or request

Comments

@sebastientourbier
Copy link
Member

sebastientourbier commented Nov 8, 2019

Brainhack Global Geneva 2019 Challenge

Build and run a Docker image executes a nipype workflow that should run an other Docker image that contains the C++ NLMdenoising program of the MIALSRTK library.

Road Map:

  • Creation of first sinapp workflow with BIDS App parser (python / not containerized yet)
  • Creation of Dockerfile
  • Build, test, and make it work
@sebastientourbier
Copy link
Member Author

sebastientourbier commented Nov 9, 2019

Summary of challenges and solutions

  • Access the docker engine of the OS host from within the first container

    Solution: Adopting the Docker-out-of-Docker framework maps /var/run/docker.sock into the first container, enabling the first container to access Docker running on the OS host.

    0D679D22-0C43-436E-8BAC-D2A7FCCCF45A

    It seems we also have to map /usr/bin/docker.

  • User/group permissions to access the docker.sock mapped within the first container

    Solution: Use of docker run -u $(id -u):$(id -g) --group-add 0 to add the current user/group to docker group that seems to be 0.

  • Access the BIDS dataset from the second container

    Solution: Give a name to the first container at execution with docker run --name sinapp_nlmdenoise -v <local/path/to/bids>:/fetaldata that also mounts your local bids directory as the /fetaldata volume of this container and then at the execution of the second container use docker run --volumes-from sinapp_nlmdenoise to be able to access to the volume /fetaldata mount in the first (SINAPP) container.

@sebastientourbier sebastientourbier added the enhancement New feature or request label Nov 10, 2019
sebastientourbier added a commit that referenced this issue Nov 10, 2019
…Geneva 2019

* Correction of the command to launch the notebook
* Instructions how to use the work developed during the brainhack as an example for the implmentation of the rest of the SINAPPs (Close #5 )
* Update list of contributors

*
@sebastientourbier
Copy link
Member Author

See Commit 6ffe6b8 for changes that made the first SINAPP working

@sebastientourbier sebastientourbier changed the title Docker-in-Docker Docker-out-of-Docker (DooD) Solution Nov 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant