Skip to content

Commit

Permalink
uniformize rst
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexVCaron committed Aug 17, 2023
1 parent a7ccafa commit dfdf7a6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions source/our_tools/development_containers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ Development containers
To streamline the execution of the various technologies the lab develops on a wide range of computing architectures and operating systems, and to facilitate their distribution to collaborators, we use Docker images. An image is a stand-alone, executable package that includes everything needed to run a collection of softwares, including the code, runtimes, libraries, environment variables, and configuration files. In Docker, images are used to create containers, isolated and portable environments that can be run on any computer with Docker installed, regardless of the operating system running on the computer.

Two specialized images are developed for the lab and its collaborators:
* [Scilus](https://hub.docker.com/r/scilus/scilus/): contains the :ref:`main dependencies <ref_scil_dependencies>` for the lab's projects, [Scilpy](https://github.com/scilus/scilpy) and [dmriqcpy](https://github.com/scilus/dmriqcpy)
* [Scilus-flows](https://hub.docker.com/r/scilus/scilus-flows/): contains :ref:`Nextflow <ref_nextflow>` and most pipelines developed by the lab, in addition to the content of Scilus.
* `Scilus <https://hub.docker.com/r/scilus/scilus/>`__: contains the :ref:`main dependencies <ref_scil_dependencies>`__ for the lab's projects, `Scilpy <https://github.com/scilus/scilpy>`__ and `dmriqcpy <https://github.com/scilus/dmriqcpy>`__
* `Scilus-flows <https://hub.docker.com/r/scilus/scilus-flows/>`__: contains :ref:`Nextflow <ref_nextflow>` and most pipelines developed by the lab, in addition to the content of Scilus.

.. _ref_dev_with_docker:

Expand Down Expand Up @@ -33,13 +33,13 @@ The ``--rm`` option will remove the container once you exit the shell. The ``-it
Docker in Visual Studio code
----------------------------

[Visual Studio Code](https://code.visualstudio.com/) is one of the IDE used by the lab. It is a free and open-source code editor developed by Microsoft. It includes support for debugging, embedded Git control, syntax highlighting, intelligent code completion, snippets, and code refactoring. It is also customizable, allowing users to change the theme, keyboard shortcuts, preferences, and install extensions that add additional functionality.
`Visual Studio Code <https://code.visualstudio.com/>`__ is one of the IDE used by the lab. It is a free and open-source code editor developed by Microsoft. It includes support for debugging, embedded Git control, syntax highlighting, intelligent code completion, snippets, and code refactoring. It is also customizable, allowing users to change the theme, keyboard shortcuts, preferences, and install extensions that add additional functionality.

Visual Studio Code has a [Docker extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) that allows you to develop inside a container. This is useful to avoid installing all the dependencies on your system and to ensure that the code will run in the same environment as the one used by the lab. To use this extension with the lab images, you need first to install Docker on your system and pull the Scilus image as described :ref:`above <ref_dev_with_docker>`.
Visual Studio Code has a `Docker extension <https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers>`__ that allows you to develop inside a container. This is useful to avoid installing all the dependencies on your system and to ensure that the code will run in the same environment as the one used by the lab. To use this extension with the lab images, you need first to install Docker on your system and pull the Scilus image as described :ref:`above <ref_dev_with_docker>`.

Once done, open a folder in Visual Studio Code and click on the Docker icon in the left menu. This will open the Docker tab, listing containers, images available locally and in connected remote registries, and much more.

Click on the ``+`` icon in the *containers* pane and select ``Open current folder in container``. Choose a configuration from the list of base (Ubuntu is a good default one), the version of the base OS and additional features if desired, to generate a template configuration file. This will create a ``.devcontainer`` folder in your project with a ``devcontainer.json`` file. You can then edit this file to specify the image to use, the user to use in the container, the extensions to install, etc. To get an idea of a configuration for the lab, you can refer to the ``.devcontainer`` folder in the [Scilpy repository](https://github.com/scilus/scilpy).
Click on the ``+`` icon in the *containers* pane and select ``Open current folder in container``. Choose a configuration from the list of base (Ubuntu is a good default one), the version of the base OS and additional features if desired, to generate a template configuration file. This will create a ``.devcontainer`` folder in your project with a ``devcontainer.json`` file. You can then edit this file to specify the image to use, the user to use in the container, the extensions to install, etc. To get an idea of a configuration for the lab, you can refer to the ``.devcontainer`` folder in the `Scilpy repository <https://github.com/scilus/scilpy>`__.

Once the configuration is done, click on the ``blue icon`` on the bottom left of the window and select ``Reopen in Container``. This will build the container and open a new window in the container.

Expand Down

0 comments on commit dfdf7a6

Please sign in to comment.