Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ERROR: unsatisfiable constraints - while installing python using APK [duplicate]

I have a pipeline which deploys my container from GitLab. Last deployment was 5 days ago and went without any problems. Today I deploy it and get the following error:

$ apk add --no-cache curl python py-pip
 fetch http://dl-cdn.alpinelinux.org/alpine/v3.12/main/x86_64/APKINDEX.tar.gz
 fetch http://dl-cdn.alpinelinux.org/alpine/v3.12/community/x86_64/APKINDEX.tar.gz
 ERROR: unsatisfiable constraints:
   python (missing):
     required by: world[python]

My job definition is:

my-deploy:
  type: my-deploy
  image: docker:stable
  script:
    - apk update
    - apk add --no-cache curl python py-pip <-- Here the erorr happens
    ...
like image 777
AGoranov Avatar asked Nov 16 '22 10:11

AGoranov


1 Answers

From this issue on the Docker's repo:

This was "broken" while updating our base from alpine:3.11 to alpine:3.12.

In order to fix it you need to specify the version of Python directly, e.g.:

apk add python2
// or
apk add python3
like image 135
AGoranov Avatar answered Nov 23 '22 23:11

AGoranov