I want to use python 3.x
and pip3
to install some python libraries in docker. I used following commands to do it, but they were not installed.
FROM alpine:latest
RUN apk add python3 py3-pip3 && \
pip3 install --upgrade pip3 && \
pip3 install wget &&\
pip3 install sys &&\
pip3 install threading &&\
pip3 install time &&\
pip3 install requests &&\
pip3 install paho-mqtt &&\
pip3 install logging &&\
rm -rf /var/cache/apk/*
COPY NumSide.py /home/mehdi/Download/NumSide.py
CMD ["python3","/home/mehdi/Download/NumSide.py"]
Below, the error I got:
ERROR: unsatisfiable constraints: py3-pip3 (missing): required by: world[py3-pip3] The command '/bin/sh -c apk add python3 py3-pip3 && pip3 install --upgrade pip3 && pip3 install wget &&pip3 install sys &&pip3 install threading &&pip3 install time &&pip3 install requests &&pip3 install paho.mqtt.client &&pip3 install logging &&rm -rf /var/cache/apk/*' returned a non-zero code: 1
The package name is py3-pip
not py3-pip3