Skip to content

Dockerfile: add package-lock.json before npm install, copy Orca last 🐎#251

Merged
antoinerg merged 1 commit intomasterfrom
ci-docker-caching
Sep 23, 2019
Merged

Dockerfile: add package-lock.json before npm install, copy Orca last 🐎#251
antoinerg merged 1 commit intomasterfrom
ci-docker-caching

Conversation

@antoinerg
Copy link
Collaborator

It is much faster to copy Orca's source code last in order to hit the cache on all the first (rarely changing) build steps. This saves us roughly 8 minutes in the docker-build-and-push step on CircleCI now that we have Docker layer caching enabled.

Also, we copy package-lock.json prior to running npm install to get exactly the right dependencies in the Docker image.

cc @etpinard

@etpinard
Copy link
Contributor

Awesome 💃

@antoinerg antoinerg merged commit 46d6bc5 into master Sep 23, 2019
@antoinerg antoinerg deleted the ci-docker-caching branch September 23, 2019 22:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants