Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions docs/basic_training/containers.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,26 +85,26 @@ To exit from the container, stop the BASH session with the `exit` command.

### Your first Dockerfile

Docker images are created by using a so-called `Dockerfile`, a simple text file containing a list of commands to assemble and configure the image with the software packages required. For example, a Dockerfile to create a container with `cowsay` installed could be as simple as this:
Docker images are created by using a so-called `Dockerfile`, a simple text file containing a list of commands to assemble and configure the image with the software packages required. For example, a Dockerfile to create a container with `curl` installed could be as simple as this:

```dockerfile linenums="1" title="Dockerfile"
FROM debian:bullseye-slim

LABEL image.author.name "Your Name Here"
LABEL image.author.email "your@email.here"

RUN apt-get update && apt-get install -y curl cowsay
RUN apt-get update && apt-get install -y curl

ENV PATH=$PATH:/usr/games/
```

Once your Dockerfile is ready, you can build the image by using the `build` command. For example:

```bash
docker build -t <my-image> .
docker build -t my-image .
```

Where `<my-image>` is the user-specified name for the container image you plan to build.
Where `my-image` is the user-specified name for the container image you plan to build.

!!! tip

Expand Down
Loading