Skip to content

fix(docker): narrow the Docker build context and keep the checkout credentials out of it - #2035

Closed
Yury Semikhatsky (yury-s) wants to merge 3 commits into
microsoft:mainfrom
yury-s:fix-docker-build-context
Closed

Yury Semikhatsky (yury-s) wants to merge 3 commits into
microsoft:mainfrom
yury-s:fix-docker-build-context

Conversation

@yury-s

Copy link
Copy Markdown
Member

Summary

  • Check out the repository with persistCredentials: false in the publish pipeline, and exclude .git and the target directories from the Docker build context.
  • COPY only the root POM and the driver, driver-bundle and playwright modules into the image build instead of the whole build context.
  • Install libatomic1, which the Node.js Linux binaries link against since Node.js 25; the driver runs before install-deps.

…line and the build context

Check out the repository without persisting the credentials in the git
config, and exclude .git from the Docker build context.
Copy the root POM and the driver, driver-bundle and playwright modules
into the build instead of the whole build context, and keep the target
directories out of the build context.
The official Node.js Linux binaries link against libatomic since
Node.js 25, and the driver runs before install-deps adds it.
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.

1 participant