Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker image build fails #1042

Closed
Zorato opened this issue Aug 4, 2022 · 4 comments
Closed

Docker image build fails #1042

Zorato opened this issue Aug 4, 2022 · 4 comments
Assignees
Labels
help wanted Extra attention is needed

Comments

@Zorato
Copy link

Zorato commented Aug 4, 2022

System information

Geth version: 1.17
OS & Version: MacOS 12.4 & Docker Desktop 4.11.0 (83626)
Commit hash : f68965a (v1.1.12)

Expected behaviour

BNB Docker image built successfully

Actual behaviour

 > [stage-1  2/11] RUN apk add --no-cache ca-certificates~=20211220 jq~=1.6   bash~=5.1.16-r2 bind-tools~=9.16.29-r0 tini~=0.19.0   grep~=3.7 curl sed~=4.8-r0   && rm -rf /var/cache/apk/*   && addgroup -g 1000 bsc   && adduser -u 1000 -G bsc --shell /sbin/nologin --no-create-home -D bsc   && addgroup bsc tty   && sed -i -e "s/bin\/sh/bin\/bash/" /etc/passwd:                                                                                                                                
#6 0.267 fetch https://dl-cdn.alpinelinux.org/alpine/v3.16/main/x86_64/APKINDEX.tar.gz                                                                                                                                                              
#6 1.757 fetch https://dl-cdn.alpinelinux.org/alpine/v3.16/community/x86_64/APKINDEX.tar.gz                                                                                                                                                         
#6 3.963 ERROR: unable to select packages:                                                                                                                                                                                                          
#6 4.000   ca-certificates-20220614-r0:
#6 4.000     breaks: world[ca-certificates~20211220]
#6 4.000     satisfies: curl-7.83.1-r2[ca-certificates]
#6 4.000                libcurl-7.83.1-r2[ca-certificates]

Steps to reproduce the behaviour

$ git checkout v1.1.12 && docker build -t binance/geth-bnb:1.1.12 .

Backtrace

$ docker build --pull -t binance/geth-bnb:1.1.12 --no-cache .
[+] Building 2.1s (9/20)                                                                                                                                                                                                                            
 => [internal] load build definition from Dockerfile                                                                                                                                                                                           0.0s
 => => transferring dockerfile: 37B                                                                                                                                                                                                            0.0s
 => [internal] load .dockerignore                                                                                                                                                                                                              0.0s
 => => transferring context: 34B                                                                                                                                                                                                               0.0s
 => [internal] load metadata for docker.io/library/alpine:3.16.0                                                                                                                                                                               1.0s
 => [internal] load metadata for docker.io/library/golang:1.17-alpine                                                                                                                                                                          1.0s
 => CACHED [builder 1/4] FROM docker.io/library/golang:1.17-alpine@sha256:99ddec1bbfd6d6bca3f9804c02363daee8c8524dae50df7942e8e60788fd17c9                                                                                                     0.0s
 => [internal] load build context                                                                                                                                                                                                              0.1s
 => => transferring context: 155.21kB                                                                                                                                                                                                          0.1s
 => CACHED [stage-1  1/11] FROM docker.io/library/alpine:3.16.0@sha256:686d8c9dfa6f3ccfc8230bc3178d23f84eeaf7e457f36f271ab1acc53015037c                                                                                                        0.0s
 => CANCELED [builder 2/4] RUN apk add --no-cache make gcc musl-dev linux-headers git bash                                                                                                                                                     0.9s
 => ERROR [stage-1  2/11] RUN apk add --no-cache ca-certificates~=20211220 jq~=1.6   bash~=5.1.16-r2 bind-tools~=9.16.29-r0 tini~=0.19.0   grep~=3.7 curl==7.83.1-r2 sed~=4.8-r0   && rm -rf /var/cache/apk/*   && addgroup -g 1000 bsc   &&   0.9s
------                                                                                                                                                                                                                                              
 > [stage-1  2/11] RUN apk add --no-cache ca-certificates~=20211220 jq~=1.6   bash~=5.1.16-r2 bind-tools~=9.16.29-r0 tini~=0.19.0   grep~=3.7 curl==7.83.1-r2 sed~=4.8-r0   && rm -rf /var/cache/apk/*   && addgroup -g 1000 bsc   && adduser -u 1000 -G bsc --shell /sbin/nologin --no-create-home -D bsc   && addgroup bsc tty   && sed -i -e "s/bin\/sh/bin\/bash/" /etc/passwd:                                                                                                                     
#6 0.278 fetch https://dl-cdn.alpinelinux.org/alpine/v3.16/main/x86_64/APKINDEX.tar.gz
#6 0.448 fetch https://dl-cdn.alpinelinux.org/alpine/v3.16/community/x86_64/APKINDEX.tar.gz
#6 0.860 ERROR: unable to select packages:
#6 0.897   ca-certificates-20220614-r0:
#6 0.897     breaks: world[ca-certificates~20211220]
#6 0.897     satisfies: curl-7.83.1-r2[ca-certificates]
#6 0.897                libcurl-7.83.1-r2[ca-certificates]
------                                                                                                                                                                                                                                              
executor failed running [/bin/sh -c apk add --no-cache $PACKAGES   && rm -rf /var/cache/apk/*   && addgroup -g ${BSC_USER_GID} ${BSC_USER}   && adduser -u ${BSC_USER_UID} -G ${BSC_USER} --shell /sbin/nologin --no-create-home -D ${BSC_USER}   && addgroup ${BSC_USER} tty   && sed -i -e "s/bin\/sh/bin\/bash/" /etc/passwd]: exit code: 3

Seems that there is some conflict in package version resolution between cURL & ca-certificates.

@forcodedancing
Copy link
Contributor

@Zorato
Copy link
Author

Zorato commented Aug 4, 2022

Unfortunately we are using one slightly modified RPC method in our app, so we can't use vanilla image.

@forcodedancing forcodedancing self-assigned this Aug 5, 2022
@forcodedancing forcodedancing added the help wanted Extra attention is needed label Aug 5, 2022
@forcodedancing
Copy link
Contributor

@Zorato Can you refer to this pr #1038 ? thanks

@unclezoro
Copy link
Collaborator

It is been fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants