container · docker · linux · macos · x86_64

ubuntu: Err:1 https://dl.yarnpkg.com/debian stable InRelease

I was updating the docker image I use to do Linux stuff within a macOS Mojave and during the update, this error message appeared:


root@rpsene-docker:/# apt-get update
Err:1 https://dl.yarnpkg.com/debian stable InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23E7166788B63E1E
Hit:2 http://security.ubuntu.com/ubuntu xenial-security InRelease
Hit:3 http://archive.ubuntu.com/ubuntu xenial InRelease
Hit:4 http://ppa.launchpad.net/brightbox/ruby-ng/ubuntu xenial InRelease
Hit:5 http://archive.ubuntu.com/ubuntu xenial-updates InRelease
Hit:6 http://archive.ubuntu.com/ubuntu xenial-backports InRelease
Reading package lists... Done
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://dl.yarnpkg.com/debian stable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23E7166788B63E1E
W: Failed to fetch https://dl.yarnpkg.com/debian/dists/stable/InRelease The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23E7166788B63E1E
W: Some index files failed to download. They have been ignored, or old ones used instead.

To fix it, I had to import the the public key for that repository:


root@rpsene-docker:/# curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -
OK

With that, everything worked as expected:


root@rpsene-docker:/# apt-get update
Hit:2 http://security.ubuntu.com/ubuntu xenial-security InRelease
Get:3 https://dl.yarnpkg.com/debian stable/main amd64 Packages [8346 B]
Hit:4 http://ppa.launchpad.net/brightbox/ruby-ng/ubuntu xenial InRelease
Hit:5 http://archive.ubuntu.com/ubuntu xenial InRelease
Get:6 https://dl.yarnpkg.com/debian stable/main all Packages [8346 B]
Hit:7 http://archive.ubuntu.com/ubuntu xenial-updates InRelease
Hit:8 http://archive.ubuntu.com/ubuntu xenial-backports InRelease
Fetched 16.7 kB in 1s (16.3 kB/s)
Reading package lists... Done

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s