First install the dependencies, then copy the files from the build context into the image. This allows for more caching during rebuilds when files change and rebuilds are much faster.