A general utility image built on Ubuntu:latest, with a focus on network troubleshooting tools.
245
# Stage 1: Build stage with all utilities
FROM ubuntu:latest as builder
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y --no-install-recommends \
apt-utils \
bind9-dnsutils \
ca-certificates \
curl \
dnsutils \
gnupg \
iperf3 \
iproute2 \
iptables \
iputils-ping \
lsof \
mailutils \
mtr \
net-tools \
netcat-openbsd \
nmap \
openssh-client \
python3 \
python3-dnspython \
python3-scapy \
rsync \
socat \
swaks \
tcpdump \
telnet \
traceroute \
vim \
wget \
whois \
ca-certificates \
&& apt-get clean && \
rm -rf /var/lib/apt/lists/*
# Stage 2: Minimal runtime image
FROM ubuntu:latest
LABEL maintainer="[email protected]"
LABEL description="Ubuntu-based image with network debugging and utility tools"
ENV DEBIAN_FRONTEND=noninteractive
# Create a directory to hold binaries
RUN mkdir -p /tools
# Copy binaries from the builder
COPY --from=builder /usr/bin /usr/bin
COPY --from=builder /bin /bin
COPY --from=builder /usr/sbin /usr/sbin
COPY --from=builder /sbin /sbin
COPY --from=builder /usr/lib /usr/lib
COPY --from=builder /usr/share /usr/share
COPY --from=builder /lib /lib
COPY --from=builder /lib64 /lib64
COPY --from=builder /etc/alternatives /etc/alternatives
COPY --from=builder /etc/ssl /etc/ssl
COPY --from=builder /etc/ca-certificates /etc/ca-certificates
COPY --from=builder /etc/nsswitch.conf /etc/nsswitch.conf
COPY --from=builder /etc/resolv.conf /etc/resolv.conf
COPY --from=builder /etc/hosts /etc/hosts
# Basic setup
RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates && apt-get clean && rm -rf /var/lib/apt/lists/*
WORKDIR /root
CMD ["/bin/bash"]
Content type
Image
Digest
sha256:430400266…
Size
291.4 MB
Last updated
over 1 year ago
docker pull kfiresmith/ubuntu-utility-py:0.3