Hot answers tagged

2

Valid steps in a Dockerfile include FROM, COPY, RUN, CMD, ENTRYPOINT, etc. The reference on the syntax is available at https://docs.docker.com/engine/reference/builder/ For your file I'd also recommend looking at the best practices, which would steer you towards: FROM debain RUN apt-get update \ && apt-get install -y \ wget \ && rm -...


2

Instead of installing Docker within Ubuntu within WSL 2, you probably will have better results installing Docker Desktop directly on Windows. It still uses WSL 2 to run your containers, but it integrates better with Windows. Specifically, Docker Desktop adds a hostname to the internal DNS resolver named host.docker.internal that resolves to the host computer....


1

The size of the final image ;-) The first stage installs required binaries and libs to compile something and the next stage just copies the compiled stuff to an "empty" image. You dont need to ship the whole build environment to run the software...


Only top voted, non community-wiki answers of a minimum length are eligible