Generators

Dockerfile Builder

Build a Dockerfile from image, copy, run, and env options.

How to use Dockerfile Builder

Dockerfile Builder — Assemble a Dockerfile from a base image, copy lines, run commands, and environment options. Free to use in D2i DevTools — no account required.

Steps

  1. Fill in Base image. This field is required.
  2. Fill in Build args (NAME=value, one per line).
  3. Fill in Environment (KEY=value, one per line).
  4. Fill in Labels (KEY=value, one per line).
  5. Fill in Working directory.
  6. Fill in COPY lines (source destination).
  7. Fill in RUN commands (one per line).
  8. Fill in Expose ports (one per line).
  9. Fill in Volumes (one per line).
  10. Fill in User.
  11. Choose Entrypoint format.
  12. Fill in Entrypoint.
  13. Choose Command format.
  14. Fill in Command.
  15. Click Run and copy the result under the form.

Frequently asked questions

What is Dockerfile Builder used for?

Use it to draft a Dockerfile when you know the image and the build steps but do not want to remember the order.

How do I use the free online Dockerfile Builder tool?

Fill in Base image. This field is required. Fill in Build args (NAME=value, one per line). Fill in Environment (KEY=value, one per line). Fill in Labels (KEY=value, one per line). Fill in Working directory. Fill in COPY lines (source destination). Fill in RUN commands (one per line). Fill in Expose ports (one per line). Fill in Volumes (one per line). Fill in User. Choose Entrypoint format. Fill in Entrypoint. Choose Command format. Fill in Command. Click Run and copy the result under the form.

What can I paste or upload into Dockerfile Builder?

Enter a base image. Optional lines cover args, env, labels, copy, run, ports, volumes, user, entrypoint, and command.

What output does Dockerfile Builder give me?

A Dockerfile. A shell command is one quoted string. One argument per line becomes the JSON exec form.

Is Dockerfile Builder free, and is my input private?

Yes — Your input is processed in memory for this request only. It is not saved to disk or the database, and it is cleared after the tool finishes.

Does this build the image?

No. It only writes the file. Paths with spaces are split, so keep copy sources and destinations as single words.

Inputs are processed in memory only and are not saved to disk or the database. Data exists only for the duration of your request.