Public Key Is Not Available: No_Pubkey F76221572C52609D

public key is not available: NO_PUBKEY F76221572C52609D

There are several issues here:

1) W: GPG error: https://apt.dockerproject.org debian-jessie InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY F76221572C52609D
W: There is no public key available for the following key IDs:
AA8E81B4331F7F50

Solution:

Move the keyserver add actions to the place before RUN echo 'deb http://deb.debian.org/debian jessie-backports main' > /etc/apt/sources.list.d/jessie-backports.list, meanwhile add AA8E81B4331F7F50 also as next:

RUN apt-get install -y --no-install-recommends apt-transport-https ca-certificates
RUN apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
RUN apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys AA8E81B4331F7F50

2) W: Failed to fetch http://deb.debian.org/debian/dists/jessie-backports/main/binary-amd64/Packages 404 Not Found

E: Some index files failed to download. They have been ignored, or old ones used instead.

Solution:

microsoft/aspnetcore-build:1.0.1 base on debian8, and you want to use openjdk8 which was default not in apt repository. So you use deb http://deb.debian.org/debian jessie-backports main.

Unfortunately, if you check http://ftp.debian.org/debian/dists/, you will find jessie-backports had been removed. So you had to switch to archived url like next (Comment the old url, just use the url next):

#RUN echo 'deb http://deb.debian.org/debian jessie-backports main' > /etc/apt/sources.list.d/jessie-backports.list
RUN echo 'deb http://archive.debian.org/debian jessie-backports main' > /etc/apt/sources.list.d/jessie-backports.list

Meanwhile, you had to add next after doing above to resolve release-file-expired-problem:

RUN echo "Acquire::Check-Valid-Until \"false\";" > /etc/apt/apt.conf.d/100disablechecks

3) ENV JAVA_VERSION 8u111

ENV JAVA_DEBIAN_VERSION 8u111-b14-2~bpo8+1

Solution:

Not sure how you get this version, but in fact after change to archive jessie backports, what you could get is something like next:

root@2ecaeffec483:/etc/apt# apt-cache policy openjdk-8-jdk
openjdk-8-jdk:
Installed: (none)
Candidate: 8u171-b11-1~bpo8+1
Version table:
8u171-b11-1~bpo8+1 0
100 http://archive.debian.org/debian/ jessie-backports/main amd64 Packages

So, you had to change to next:

ENV JAVA_VERSION 8u171
ENV JAVA_DEBIAN_VERSION 8u171-b11-1~bpo8+1

Installing R from CRAN Ubuntu repository: No Public Key Error

Like @Ben Bolker commented (sorry I hijacked your commented, but the correct answer was not yet posted), in the description of the debian package repo there is a section secure apt which says:

SECURE APT

The Debian backports archives on CRAN are signed with the key of
"Johannes Ranke (CRAN Debian archive) " with key
ID 381BA480. You can fetch this with

gpg --keyserver subkeys.pgp.net --recv-key 381BA480 or
alternatively, using another key server,

gpg --keyserver pgp.mit.edu --recv-key 381BA480 If this doesn't
work, it might be due to a firewall blocking port 11371.
Alternatively, you can search for 0x381BA480 at
http://keyserver.noreply.org/ or http://pgp.mit.edu/ and copy the key block into a plain text
file, named, for instance, jranke_cran.asc.

If receiving the key with gpg did work, you need to export it to a
text file

gpg -a --export 381BA480 > jranke_cran.asc In both cases you need
to make the key known to the apt system by running

apt-key add jranke_cran.asc as root.

If you have not already done this, this will probably fix your issue.

Signatures couldn't be verified because the public key is not available error while installing docker

Got the solution, I was trying to install docker 1.5 on a 32-bit Ubuntu, whereas the documentation says it needs 64 bit Ubuntu.

check here in Prerequisites section

Ubuntu 18.4 install R language 3.5

Add the key before the adding the repo.

Also you need the && after every command to chain them all.
I prefer to use ; after set -uex for long chains so I can easily see which command output is coming from, particularly when it fails.

RUN set -uex; \
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9; \
add-apt-repository 'deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/'; \
apt-get update; \
apt-get install -y r-base; \
rm -rf /var/lib/apt/lists/*

The repository 'http://packages.cloud.google.com/apt gcsfuse-bionic InRelease' is not signed

This is a known issue. Read this for more info.

You can first add the correct repository GPG key using the following command.

curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -

Updated Dockerfile would be:

FROM gcr.io/deeplearning-platform-release/tf2-gpu.2-2
RUN curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
RUN apt-get update && \
apt-get install --no-install-recommends -y libsndfile-dev
ENTRYPOINT ["ls", "-l"]

Docker: How to solve the public key error in ubuntu while installing docker

EDIT: This apparently does not work any more.

Run this to add the correct key:

# Does not work any more
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -

Source: https://docs.docker.com/install/linux/docker-ce/ubuntu/



Related Topics



Leave a reply



Submit