helium / cargo-elixir

Apache License 2.0
15 stars 6 forks source link

Error with docker-compose version #47

Open alexcorvis84 opened 1 year ago

alexcorvis84 commented 1 year ago

Hi, I'm getting below error when trying to deploy the project with docker-compose version:

How can I fix the issue? Many thanks in advance!

time="2023-05-21T11:08:24+02:00" level=warning msg="The \"SECRET_KEY_BASE\" variable is not set. Defaulting to a blank string."
[+] Building 2.8s (6/23)
 => [internal] load .dockerignore                                                                                                                                                       0.0s 
 => => transferring context: 2B                                                                                                                                                         0.0s 
 => [internal] load build definition from Dockerfile                                                                                                                                    0.1s 
 => => transferring dockerfile: 784B                                                                                                                                                    0.0s 
 => [internal] load metadata for docker.io/library/elixir:1.9-alpine                                                                                                                    0.7s 
 => [internal] load build context                                                                                                                                                       0.1s 
 => => transferring context: 4.36kB                                                                                                                                                     0.0s 
 => CACHED [ 1/19] FROM docker.io/library/elixir:1.9-alpine@sha256:4fb83dba35436dfa0c7af1f7d82f571c6571b2a7f59b49ce37dfa5308d97ca54                                                     0.0s 
 => ERROR [ 2/19] RUN apk add --update git build-base nodejs npm yarn python bash openssl postgresql-client                                                                             2.1s 
------
 > [ 2/19] RUN apk add --update git build-base nodejs npm yarn python bash openssl postgresql-client:
#0 0.540 fetch https://dl-cdn.alpinelinux.org/alpine/v3.16/main/x86_64/APKINDEX.tar.gz
#0 0.891 fetch https://dl-cdn.alpinelinux.org/alpine/v3.16/community/x86_64/APKINDEX.tar.gz
#0 1.429 ERROR: unable to select packages:
#0 1.476   python (no such package):
#0 1.476     required by: world[python]
------
failed to solve: process "/bin/sh -c apk add --update git build-base nodejs npm yarn python bash openssl postgresql-client" did not complete successfully: exit code: 1
alexcorvis84 commented 1 year ago

Update: it can be solved with mentioning de Python version as commented here.

So I changed the Dockerfile to RUN apk add --update git build-base nodejs npm yarn python3 bash openssl postgresql-client and run ok.