I am trying to build and deploy microservices images to a single-node Kubernetes cluster running on my development machine using minikube. I am using the cloud-native microservices demo application Online Boutique by Google to understand the use of technologies like Kubernetes, Istio etc.
Link to github repo: microservices-demo
While following the installation process, and on running command skaffold run
to build and deploy my application, I get some errors:
Step 10/11 : RUN apt-get -qq update && apt-get install -y --no-install-recommends curl
---> Running in 43d61232617c
W: GPG error: http://deb.debian.org/debian buster InRelease: At least one invalid signature was encountered.
E: The repository 'http://deb.debian.org/debian buster InRelease' is not signed.
W: GPG error: http://deb.debian.org/debian buster-updates InRelease: At least one invalid signature was encountered.
E: The repository 'http://deb.debian.org/debian buster-updates InRelease' is not signed.
W: GPG error: http://security.debian.org/debian-security buster/updates InRelease: At least one invalid signature was encountered.
E: The repository 'http://security.debian.org/debian-security buster/updates InRelease' is not signed.
failed to build: couldn't build "loadgenerator": unable to stream build output: The command '/bin/sh -c apt-get -qq update && apt-get install -y --no-install-recommends curl' returned a non-zero code: 100
I receive these errors when trying to build loadgenerator.
How can I resolve this issue?
12
Answers
There are a few reasons why you encounter these errors:
There might be an issue with the existing cache and/or disc space. In order to fix it you need to clear the APT cache by executing:
sudo apt-get clean
andsudo apt-get update
.The same goes with existing docker images. Execute:
docker image prune -f
anddocker container prune -f
in order to remove unused data and free disc space.If you don’t care about the security risks, you can try to run the
apt-get
command with the--allow-unauthenticated
or--allow-insecure-repositories
flag. According to the docs:Please let me know if that helped.
I think that is related to some LSM component of the docker official image (in this case armhf) and exec/capabilities permissions. In this simple case sid flavour is unable to handle time corectly. And this related to the certificate check, is the cause of invalid signature. It happends too in ubuntu focal.
The reason I usually see this is because docker has run out of disk space, which is frustrating because the error gives little indication that this is the problem. First try cleaning up images and containers you don’t need using the
prune
command https://docs.docker.com/config/pruning/.If you have a lot of images accumulated and want to remove all of them that aren’t associated with an existing container try:
Or you can remove only older images:
Finally, on MacOS, where Docker runs inside a dedicated VM, you may need to increase the disk available to Docker from the Docker Desktop application (Settings -> Resources -> Advanced -> Disk image size).
I had this same issue and none of the previous responses saying to prune images or containers worked. The reason was that my Docker Build Cache was taking up the bulk of the space. Running the below command fixed the issue:
You can then check to see if it worked by running:
UPDATE:
The above command will clear the whole Docker system. If you want to clear only the build cache, you can do it with the below command (credit to saraf.gahl):
Make your own sid image in x64
You can load later in the arm host with
The error suggests that one of the files in
/var/lib/apt/lists
consist at least one invalid/corrupted signature (could be the result ofapt-key
misuse or something else).Try to run Apt update with the debug messages:
which should point you to the corrupted file, e.g.
Edit the file, find and remove the corrupted parts, or remove the whole file, so it can be recreated.
None of these worked for me. This command did the trick though:
Literally had 249GB worth of volumes that I was able to reclaim.
@Jack Kawell got it right.
This command does the trick.
Beware of the command "docker system prune" as this would delete all your images (very destructive).
The builder prune only deletes the build cache that is where your have all your previous (cached) builds steps.
I tried a few of the above answers, and none of them worked for me. The real trigger was when I used
--allow-unauthenticated
and--allow-insecure-repositories
from @Wytrzymały Wiktor‘s answer, and I got a notification showingThis lead me down a route where I found this post which suggested that the issue may be where libseccomp2 was outdated.
The fix there was to do:
Note that this assumes that you’re using Raspbian and a version of docker after 19.04
I had the same problem. It looks like it was lack of space. I’ve removed old images and it started to work.
$ docker images
Select the ones you don’t care anymore (to delete).
$ docker rmi <image_id>
The following command filter the dangling images and remove those.
docker rmi $(docker images -q --filter "dangling=true")
@BoyArmy_89 solves my similar problem; I tried all the other solutions but only the following worked:
In my case I was trying to run a Docker
debian:stable
(bullseye at the moment) in a Raspberry PI with abuster
distribution of the OS.Changed to
debian:buster
and it workedHope this will help someone out there