Context
I had a dockerfile based on postgres:11-alpine that was working in the past (probably a few months since it was last built) with the following definition:
FROM postgres:11-alpine
RUN apk update
# install aws cli
# taken from: https://github.com/anigeo/docker-awscli/blob/master/Dockerfile
RUN \
apk -Uuv add groff less python py-pip && \
pip install awscli && \
apk --purge -v del py-pip && \
rm /var/cache/apk/*
I recently tried to rebuild it before upgrading to postgres 12, but the image build failed with:
ERROR: unsatisfiable constraints:
python (missing):
required by: world[python]
I guess the python package is gone now because YOLO? Whatever, I tried to upgrade to python3 by changing the docker file to:
RUN \
apk -Uuv add groff less python3 py-pip && \
pip install awscli && \
apk --purge -v del py-pip && \
rm /var/cache/apk/*
This looked like it worked, but then when running the aws command it failed with error:
ModuleNotFoundError: No module named 'six'
Question
How to fix this so the awscli will not give the error No module named 'six'?