運行命令後sudo apt-get update
我收到以下錯誤:
W: GPG error: https://deb.nodesource.com/node_7.x xenial InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 1655A0AB68576280
W: The repository 'https://deb.nodesource.com/node_7.x xenial InRelease' is not signed.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://ppa.launchpad.net/chris-lea/node.js/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch http://ppa.launchpad.net/chris-lea/node.js/ubuntu/dists/xenial/main/binary-amd64/Packages 404 Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.
我怎樣才能解決這個問題?
答案1
您使用的儲存庫存在安全憑證問題。在儲存庫維護人員修復此問題之前,完成更新的唯一方法是停用該儲存庫。如果只有兩者,那應該不是什麼大問題,而且問題應該是暫時的——每次回購未通過安全檢查時,都應該通知回購維護者。
答案2
您可以從'curl -s 取得金鑰http://nsolid-deb.nodesource.com/gpgkey/NODESOURCE-NSOLID-GPG-SIGNING-KEY'
要修復該錯誤,您必須匯入您正在使用的儲存庫的金鑰。若要匯入儲存庫的金鑰,請執行下列命令
curl -s http://nsolid-deb.nodesource.com/gpgkey/NODESOURCE-NSOLID-GPG-SIGNING-KEY | sudo apt-key add -