I have the below docker file, base image rundeckpro/runner:latest; it has no python installed. After the image is built, there are two versions of python: both python3.10 and python3.11, even though I requested only python3.11. Is there any reason for this, and can I avoid this?
ARG RUNNER_VERSION=latest
FROM rundeckpro/runner:${RUNNER_VERSION}
ARG PYTHON_VERSION=python3.11
ARG DEBIAN_FRONTEND=noninteractive
USER root
RUN apt-get update && \
apt-get install -y --no-install-recommends software-properties-common && \
apt-get install -y --no-install-recommends gpg-agent && \
add-apt-repository -y ppa:deadsnakes/ppa && \
apt-get install -y --no-install-recommends $PYTHON_VERSION && \
apt-get install -y --no-install-recommends $PYTHON_VERSION-venv && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1
USER runner