Skip to content

Commit 9dc4ea3

Browse files
authored
docs: Dockerfile - Use ref links
1 parent af57ec4 commit 9dc4ea3

File tree

2 files changed

+17
-7
lines changed

2 files changed

+17
-7
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ RUN <<HEREDOC
1616
# Install packages to a custom root-fs location (defined in `ZYPPER_OPTIONS`):
1717
zypper "${ZYPPER_OPTIONS[@]}" --gpg-auto-import-keys refresh
1818
zypper "${ZYPPER_OPTIONS[@]}" --non-interactive install --download-in-advance --no-recommends \
19-
bash procps grep gawk sed coreutils busybox ldns libidn2-0 socat openssl curl
19+
bash procps grep gawk sed coreutils busybox ldns libidn2-0 socat openssl curl
2020

2121
# Optional - Avoid `CACHE_ZYPPER` from being redundantly cached in this RUN layer:
2222
# (doesn't improve `INSTALL_ROOT` size thanks to `--cache-dir`)

Dockerfile.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,19 @@ docker run --rm -it -v /tmp:/data --workdir /data ghcr.io/testssl/testssl.sh:3.2
1919

2020
> [!NOTE]
2121
> - The UID/GID ownership of the file will be created by the container user `testssl` (`1000:1000`), with permissions `644`.
22-
> - Your host directory must permit the `testssl` container user or group to write to that host volume. You could alternatively use [`docker cp`](https://docs.docker.com/reference/cli/docker/container/cp/).
22+
> - Your host directory must permit the `testssl` container user or group to write to that host volume. You could alternatively use [`docker cp`][docker-docs::cli::cp].
2323
2424
## Images
2525

2626
### Available at DockerHub and GHCR
2727

2828
You can pull the image from either of these registries:
29-
- DockerHub: [`drwetter/testssl.sh`](https://hub.docker.com/r/drwetter/testssl.sh)
30-
- GHCR: [`ghcr.io/testssl/testssl.sh`](https://github.com/testssl/testssl.sh/pkgs/container/testssl.sh)
29+
- DockerHub: [`drwetter/testssl.sh`][image-registry::dockerhub]
30+
- GHCR: [`ghcr.io/testssl/testssl.sh`][image-registry::ghcr]
3131

3232
Supported tags:
3333
- `3.2` / `latest`
34-
- `3.0` is the old stable version ([soon to become EOL](https://github.com/testssl/testssl.sh/tree/3.0#status))
34+
- `3.0` is the old stable version ([soon to become EOL][testssl::v3p0-eol])
3535

3636
### Building the `testssl.sh` container image
3737

@@ -47,7 +47,9 @@ There are two base images supported:
4747
- openSUSE Leap ([`Dockerfile`](./Dockerfile)), glibc-based + faster.
4848
- Alpine ([`Dockerfile`](./Dockerfile.alpine)), musl-based + half the size.
4949

50-
The Alpine variant is made available if you need broader platform support, or an image about 30MB smaller at the expense of slightly slower performance.
50+
The Alpine variant is made available if you need broader platform support, or an image about 30MB smaller at the expense of [slightly slower performance][testssl::base-image-performance].
51+
52+
For contributors, if needing context on the [package selection has been documented][testssl::base-image-packages] for each base image.
5153

5254
#### Tip - Remote build context + `Dockerfile`
5355

@@ -58,7 +60,7 @@ docker build --tag localhost/testssl.sh:3.2 https://github.com/testssl/testssl.s
5860
```
5961

6062
> [!NOTE]
61-
> This will produce a slightly larger image as [`.dockerignore` is not supported with remote build contexts](https://github.com/docker/buildx/issues/3169).
63+
> This will produce a slightly larger image as [`.dockerignore` is not supported with remote build contexts][build::dockerignore-remote-context].
6264
6365
---
6466

@@ -70,3 +72,11 @@ docker build \
7072
--file https://raw.githubusercontent.com/testssl/testssl.sh/3.2/Dockerfile.alpine \
7173
https://github.com/testssl/testssl.sh.git#3.2
7274
```
75+
76+
[docker-docs::cli::cp]: https://docs.docker.com/reference/cli/docker/container/cp/
77+
[image-registry::dockerhub]: https://hub.docker.com/r/drwetter/testssl.sh
78+
[image-registry::ghcr]: https://github.com/testssl/testssl.sh/pkgs/container/testssl.sh
79+
[testssl::v3p0-eol]: https://github.com/testssl/testssl.sh/tree/3.0#status
80+
[testssl::base-image-performance]: https://github.com/testssl/testssl.sh/issues/2422#issuecomment-2841822406
81+
[testssl::base-image-packages]: https://github.com/testssl/testssl.sh/issues/2422#issuecomment-2841822406
82+
[build::dockerignore-remote-context]: https://github.com/docker/buildx/issues/3169

0 commit comments

Comments
 (0)