Docker Community Forums

Share and learn in the Docker community.

Can not use apk install package in vm


(Slene) #1
moby:~# apk update
fetch http://dl-cdn.alpinelinux.org/alpine/v3.3/main/x86_64/APKINDEX.tar.gz
ERROR: http://dl-cdn.alpinelinux.org/alpine/v3.3/main: Bad file descriptor
WARNING: Ignoring APKINDEX.5a59b88b.tar.gz: Bad file descriptor
1 errors; 65 distinct packages available
moby:~# apk add nginx
WARNING: Ignoring APKINDEX.5a59b88b.tar.gz: Bad file descriptor
ERROR: unsatisfiable constraints:
  nginx (missing):
    required by: world[nginx]

(Alexandre) #2

What’s your base image? Have you checked your network and did some basic checks from within the container to make sure it reaches the Internet?

APK is totally usable inside a container.


(Slene) #3

Sorry, it’s not run in a container.

screen ~/Library/Containers/com.docker.docker/Data/com.docker.driver.amd64-linux/tty
... run apk command

(Alexandre) #4

@slene:
can you try to run “setup-apkcache” and try apk update again?