Skip to content

Commit

Permalink
Small doc update (#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
flemay authored Nov 24, 2023
1 parent 978e44b commit 8efa1e0
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions docs/guide/project-dependencies.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,13 +62,12 @@ services:

## Share dependencies with host or not

All the approaches discussed above can share third party dependencies with the host, usually by mounting a host directory to a Docker container and letting the container install the dependencies. An example would be like the 3 Musketeers website where a NodeJS container installs the packages and the `node_modules` folder is shared with the host. This is useful when developing as IDEs can provide autocomplete. The dependencies can also be bundled and passed along the pipeline stages which is usually faster that re-installing them.
All the approaches discussed above can share third party dependencies with the host, usually by mounting a host directory to a Docker container and letting the container install the dependencies. An example would be like the 3 Musketeers website where a NodeJS container installs the packages and the `node_modules` folder is shared with the host. This is useful when developing as IDEs can provide intellisense (autocomplete). The dependencies can also be bundled and passed along the pipeline stages which is usually faster that re-installing them.

Installing the dependencies when building a Docker image is another viable option especially if autocomplete is not needed, or if the pipeline is basically one stage.
Installing the dependencies when building a Docker image is another viable option especially if intellisense is not needed, or if the pipeline is basically one stage.

## One or many Docker images

Usually, using official images, which tend to follow the single responsibility principle, is preferable as those images' maintenance is already taken care of.

However, as stated before, they do not solve all problems and using a single custom Docker image may make the project development simpler. It is not uncommon for a project to rely on both official and custom images.

0 comments on commit 8efa1e0

Please sign in to comment.