Sign inSign up

ja3600/tiny-iperf3

By ja3600

Updated about 1 month ago

Linux container specifically for running iperf3 network bandwidth testing.

Image
Networking
Monitoring & observability
0

42

ja3600/tiny-iperf3 repository overview

iperf3 Image Builder

Tools utilized

  • MacBook Air with Apple M2 cpu, 8 GB ram
  • OrbStack Version 2.2.3 (20963)
  • Visual Studio Code
  • Trivy Version: 0.74.0

Highlevel Build Step

MacBook M2 (ARM64)
   ↓
Orb VM (ARM64 Ubuntu)
   ↓
Docker Buildx + QEMU
   ↓
Build ARMv7 container for CM8100

Building Linux machine used to create the iperf images

orb create ubuntu --arch arm64 my_ubuntu
orb shell -m my_ubuntu
Once your at the shell prompt of the host, begin to setup the build environment
sudo apt update
sudo apt upgrade  (optional)
sudo apt install file
file /usr/bin/sed 
expected output
$ file /usr/bin/sed
/usr/bin/sed: ELF 64-bit LSB pie executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, BuildID[sha1]=98012f335f8de11e91847580db2f4a73ebed1531, for GNU/Linux 3.7.0, stripped
$ 
Install Docker
sudo apt install -y docker.io
sudo systemctl enable docker
sudo systemctl start docker
docker --version
confirm this still works and output is the same
file /usr/bin/sed
Run more commands
sudo docker run --rm --privileged multiarch/qemu-user-static --platform=linux/arm64/ --reset -p yes
uname -m
sudo apt install docker-buildx
sudo docker buildx create --use
sudo docker images
create a 'Dockerfile' which is the instructions used to build the container image
FROM alpine:latest

ARG IPERF3_VERSION="3.21-r0"

RUN apk --no-cache upgrade && \
  apk add --no-cache -X https://dl-cdn.alpinelinux.org/alpine/edge/main iperf3=${IPERF3_VERSION} && \
  adduser -D iperf

USER iperf
WORKDIR /home/iperf

EXPOSE 5201/tcp 5201/udp

ENTRYPOINT ["iperf3"]

make sure you are in the folder where the Docker file exists
sudo docker buildx build --platform linux/arm/v7 -t tiny-iperf3 --load .
check for the new image and test run it
sudo docker images
expected output
john@macbook ~ % docker images
                                                                                                    i Info →   U  In Use
IMAGE                               ID             DISK USAGE   CONTENT SIZE   EXTRA
ja3600/tiny-iperf3:latest           ccaa5c45e222       11.1MB         3.52MB    U   
Test run image
sudo docker run --rm -d --name my-iperf3-server -p 5201:5201 tiny-iperf3:latest -s
sudo docker ps
expected output
john@macbook ~ % docker ps   
CONTAINER ID   IMAGE                COMMAND       CREATED         STATUS         PORTS                                                                                      NAMES
ed0acff3e2f6   ja3600/tiny-iperf3   "iperf3 -s"   8 seconds ago   Up 8 seconds   0.0.0.0:5201->5201/tcp, 0.0.0.0:5201->5201/udp, [::]:5201->5201/tcp, [::]:5201->5201/udp   iperf3-server
john@macbook ~ %                                               buildx_buildkit_dreamy_swanson0
optional, export image to a tarball to keep a local image
sudo docker save tiny-iperf3:latest -o tiny-iperf3.tar
Push image to dockerhub
tag the image

docker push ja3600/tiny-iperf3:tagname

docker tag tiny-iperf3:latest ja3600/tiny-iperf3:latest
docker push ja3600/tiny-iperf3:latest
Scan the image using Trivy
john@macbook iperf3 % trivy --scanners vuln,secret,misconfig image ja3600/tiny-iperf3:latest
2026-08-16T09:52:45-05:00	INFO	[vulndb] Need to update DB
2026-08-16T09:52:45-05:00	INFO	[vulndb] Downloading vulnerability DB...
2026-08-16T09:52:45-05:00	INFO	[vulndb] Downloading artifact...	repo="mirror.gcr.io/aquasec/trivy-db:2"
107.68 MiB / 107.68 MiB [-------------------------------------------------------------------] 100.00% 27.55 MiB p/s 4.1s
2026-08-16T09:52:51-05:00	INFO	[vulndb] Artifact successfully downloaded	repo="mirror.gcr.io/aquasec/trivy-db:2"
2026-08-16T09:52:51-05:00	INFO	[vuln] Vulnerability scanning is enabled
2026-08-16T09:52:51-05:00	INFO	[misconfig] Misconfiguration scanning is enabled
2026-08-16T09:52:51-05:00	INFO	[checks-client] Using existing checks from cache	path="/Users/john/Library/Caches/trivy/policy/content"
2026-08-16T09:52:52-05:00	INFO	[secret] Secret scanning is enabled
2026-08-16T09:52:52-05:00	INFO	[secret] If your scanning is slow, please try '--scanners vuln,misconfig' to disable secret scanning
2026-08-16T09:52:52-05:00	INFO	[secret] Please see https://trivy.dev/docs/v0.74/guide/scanner/secret#recommendation for faster secret detection
2026-08-16T09:52:52-05:00	INFO	Detected OS	family="alpine" version="3.24.1"
2026-08-16T09:52:52-05:00	WARN	This OS version is not on the EOL list	family="alpine" version="3.24"
2026-08-16T09:52:52-05:00	INFO	[alpine] Detecting vulnerabilities...	os_version="3.24" repository="3.24" pkg_num=17
2026-08-16T09:52:52-05:00	INFO	Number of language-specific files	num=0
2026-08-16T09:52:52-05:00	INFO	Detected config files	num=0

Report Summary

┌───────────────────────────────────────────┬────────┬─────────────────┬─────────┬───────────────────┐
│                  Target                   │  Type  │ Vulnerabilities │ Secrets │ Misconfigurations │
├───────────────────────────────────────────┼────────┼─────────────────┼─────────┼───────────────────┤
│ ja3600/tiny-iperf3:latest (alpine 3.24.1) │ alpine │        0        │    -    │         -         │
└───────────────────────────────────────────┴────────┴─────────────────┴─────────┴───────────────────┘
Legend:
- '-': Not scanned
- '0': Clean (no security findings detected)


Running Iperf

Running a TCP test
# On server
docker run -d --name iperf3-server -p 5201:5201 -p 5201:5201/udp ja3600/tiny-iperf3 -s

# On client
docker run --rm ja3600/tiny-iperf3 -c <server-ip> -t 30

Running a UDP test
# On server
docker run -d --name iperf3-server -p 5201:5201/udp ja3600/tiny-iperf3 -s

# On client
docker run --rm ja3600/tiny-iperf3 -c <server-ip> -u -b 100M

OrbStack Terminal Debugging
NEW: OrbStack Debug Shell provides useful commands & tools, making it easy to debug any container (even minimal/distroless).
It also allows installing over 80,000 packages.

To use Debug Shell, get a Pro license: https://orbstack.dev/pricing

Learn more: https://orb.cx/debug

~ $
~ $
~ $
~ $ whoami
iperf
~ $
~ $
~ $
~ $ ps ax
PID   USER     TIME  COMMAND
    1 iperf     0:00 {iperf3} [qemu-arm] /usr/bin/iperf3 iperf3 -s
    7 iperf     0:00 {sh} [qemu-arm] /bin/sh sh
   17 iperf     0:00 ps ax
~ $
~ $
Inspiration

Tag summary

Content type

Image

Digest

sha256:ccaa5c45e

Size

3.4 MB

Last updated

about 1 month ago

docker pull ja3600/tiny-iperf3