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-compose up fails in '/bin/sh -c apk add --no-cache git' #26

Open
fthommen opened this issue Feb 19, 2022 · 0 comments
Open

docker-compose up fails in '/bin/sh -c apk add --no-cache git' #26

fthommen opened this issue Feb 19, 2022 · 0 comments

Comments

@fthommen
Copy link

Hi,

when I run the docker-compose up command, I'm running into a final error

ERROR: compose.cli.main.main: Service 'client' failed to build: The command '/bin/sh -c apk add --no-cache git' returned a non-zero code: 1

Full output of GATEWAY_CERTS="$PWD/ssl_certs" docker-compose --verbose up -d can be found below. The Docker service has been configured to use our outgoing proxies and I have also set up a ~/.docker/config.json according to https://docs.docker.com/network/proxy/ to provide the proxy settings to the client.

Running docker run --rm -i -t alpine /bin/sh -c "apk add --no-cache git" doesn't return any error.

My working experience with Docker is very limited to say the least. I'm very grateful for any hints or pointers.

Cheers

Full output of GATEWAY_CERTS="$PWD/ssl_certs" docker-compose --verbose up -d

$ GATEWAY_CERTS="$PWD/ssl_certs" docker-compose --verbose  up -d
compose.config.config.find: Using configuration files: ./docker-compose.yml
docker.auth.find_config_file: Trying paths: ['/root/.docker/config.json', '/root/.dockercfg']
docker.auth.find_config_file: Found file at path: /root/.docker/config.json
docker.auth.load_config: Couldn't find 'auths' or 'HttpHeaders' sections
docker.auth.parse_auth: Auth data for {0} is absent. Client might be using a credentials store instead.
compose.cli.command.get_client: docker-compose version 1.18.0, build 8dd22a9
docker-py version: 2.6.1
CPython version: 3.6.8
OpenSSL version: OpenSSL 1.0.2k-fips  26 Jan 2017
compose.cli.command.get_client: Docker base_url: http+docker://localunixsocket
compose.cli.command.get_client: Docker version: Platform={'Name': 'Docker Engine - Community'}, Components=[{'Name': 'Engine', 'Version': '20.10.12', 'Details': {'ApiVersion': '1.41', 'Arch': 'amd64', 'BuildTime': '2021-12-13T11:44:05.000000000+00:00', 'Experimental': 'false', 'GitCommit': '459d0df', 'GoVersion': 'go1.16.12', 'KernelVersion': '3.10.0-1160.49.1.el7.x86_64', 'MinAPIVersion': '1.12', 'Os': 'linux'}}, {'Name': 'containerd', 'Version': '1.4.12', 'Details': {'GitCommit': '7b11cfaabd73bb80907dd23182b9347b4245eb5d'}}, {'Name': 'runc', 'Version': '1.0.2', 'Details': {'GitCommit': 'v1.0.2-0-g52b36a2'}}, {'Name': 'docker-init', 'Version': '0.19.0', 'Details': {'GitCommit': 'de40ad0'}}], Version=20.10.12, ApiVersion=1.41, MinAPIVersion=1.12, GitCommit=459d0df, GoVersion=go1.16.12, Os=linux, Arch=amd64, KernelVersion=3.10.0-1160.49.1.el7.x86_64, BuildTime=2021-12-13T11:44:05.000000000+00:00
compose.cli.verbose_proxy.proxy_callable: docker info <- ()
compose.cli.verbose_proxy.proxy_callable: docker info -> {'Architecture': 'x86_64',
 'BridgeNfIp6tables': True,
 'BridgeNfIptables': True,
 'CPUSet': True,
 'CPUShares': True,
 'CgroupDriver': 'cgroupfs',
 'CgroupVersion': '1',
 'ContainerdCommit': {'Expected': '7b11cfaabd73bb80907dd23182b9347b4245eb5d',
                      'ID': '7b11cfaabd73bb80907dd23182b9347b4245eb5d'},
 'Containers': 7,
...
compose.cli.verbose_proxy.proxy_callable: docker inspect_network <- ('infinibandradarweb_default')
compose.cli.verbose_proxy.proxy_callable: docker inspect_network -> {'Attachable': True,
 'ConfigFrom': {'Network': ''},
 'ConfigOnly': False,
 'Containers': {},
 'Created': '2022-02-17T22:26:32.952114446+01:00',
 'Driver': 'bridge',
 'EnableIPv6': False,
 'IPAM': {'Config': [{'Gateway': '172.18.0.1', 'Subnet': '172.18.0.0/16'}],
          'Driver': 'default',
          'Options': None},
...
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=False, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.service=client', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.service=influxdb', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.service=grafana', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.service=mongodb', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.service=api', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=infinibandradarweb', 'com.docker.compose.service=gateway', 'com.docker.compose.oneoff=False']})
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker inspect_image <- ('infinibandradarweb_client')
compose.service.build: Building client
compose.cli.verbose_proxy.proxy_callable: docker build <- (path='/opt/infiniband-radar-web', tag='infinibandradarweb_client', stream=True, rm=True, forcerm=False, pull=False, nocache=False, dockerfile='Dockerfile-client', cache_from=None, labels=None, buildargs={}, network_mode=None, target=None, shmsize=None, extra_hosts=None, container_limits={'memory': None})
docker.api.build._set_auth_headers: Looking for auth config
docker.api.build._set_auth_headers: Sending auth config ('proxies')
compose.cli.verbose_proxy.proxy_callable: docker build -> <generator object APIClient._stream_helper at 0x7fee458f5fc0>
Step 1/16 : FROM node:alpine as builder
 ---> c6a2764d974b
Step 2/16 : RUN apk add --no-cache git
 ---> Running in 7f6df0fad1c1
fetch https://dl-cdn.alpinelinux.org/alpine/v3.15/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.15/community/x86_64/APKINDEX.tar.gz
WARNING: Ignoring https://dl-cdn.alpinelinux.org/alpine/v3.15/main: network error (check Internet connection and firewall)
WARNING: Ignoring https://dl-cdn.alpinelinux.org/alpine/v3.15/community: network error (check Internet connection and firewall)
ERROR: unable to select packages:
  git (no such package):
    required by: world[git]
ERROR: compose.cli.main.main: Service 'client' failed to build: The command '/bin/sh -c apk add --no-cache git' returned a non-zero code: 1
$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant