# Use a base Debian image FROM debian:latest # Define an argument for the repository URL ARG REPO_URL=http://localhost:9221 # Backup the original sources.list, then modify it RUN cp /etc/apt/sources.list /etc/apt/sources.list.bak \ && sed -i "s|http://deb.debian.org/debian|${REPO_URL}/debian|g" /etc/apt/sources.list \ && sed -i "s|http://security.debian.org/debian-security|${REPO_URL}/debian-security|g" /etc/apt/sources.list \ && sed -i '/debian-security/d' /etc/apt/sources.list # Install RUN apt-get update \ && apt-get install -yqq \ curl \ vim \ wget \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* # Restore RUN cp /etc/apt/sources.list.bak /etc/apt/sources.list \ && rm /etc/apt/sources.list.bak