Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Fail to install CF CLI on Ubuntu 24.04 due to "The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 172B5989FCD21EF8"

Aperta
#3,373 0 commenti 3 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
1/5
Tempo stimato
Meno di un'ora
Idoneità per principianti
55/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
ubuntu
Ambito
documentation

Direzione di ricerca

Inizia dalla sezione Debian e Ubuntu della V8 CLI Installation Guide collegata nell’issue e riproduci i comandi su Ubuntu 24.04. Controlla il comando del keyring e il passaggio suggerito per la modalità del file; il lavoro è completato quando l’installazione documentata termina senza l’errore NO_PUBKEY.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Please fill out the issue checklist below and provide ALL the requested information.

  • I reviewed open and closed github issues that may be related to my problem.
  • I tried updating to the latest version of the CF CLI to see if it fixed my problem.
  • I attempted to run the command with CF_TRACE=1 to help debug the issue. --> not applicable
  • I am reporting a bug that others will be able to reproduce.

Describe the bug and the command you saw an issue with

https://github.com/cloudfoundry/cli/wiki/V8-CLI-Installation-Guide#windows states under "Debian and Ubuntu" that

(apt update && apt install --yes curl gnupg) > /dev/null 2>&1

# Add the Cloud Foundry GPG key
curl -fsSL https://packages.cloudfoundry.org/debian/cli.cloudfoundry.org.key | gpg --dearmor -o /usr/share/keyrings/cloudfoundry-keyring.gpg

# Add the Cloud Foundry repository
echo "deb [signed-by=/usr/share/keyrings/cloudfoundry-keyring.gpg] https://packages.cloudfoundry.org/debian stable main" | tee /etc/apt/sources.list.d/cloudfoundry.list

apt update > /dev/null 2>&1

shall be executed.

What happened
The command apt update fails on Ubuntu 24.04 with the error message

Get:4 https://cf-cli-debian-repo.s3.amazonaws.com stable InRelease [4,368 B]
Err:4 https://cf-cli-debian-repo.s3.amazonaws.com stable InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 172B5989FCD21EF8
Reading package lists... Done
W: GPG error: https://cf-cli-debian-repo.s3.amazonaws.com stable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 172B5989FCD21EF8
E: The repository 'https://packages.cloudfoundry.org/debian stable InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

Expected behavior
The installation is possible based on the descriptions provided.

Exact Steps To Reproduce
See above.

Provide more context
Performed 2025-01-24 with fresh installation of Ubuntu 24.04

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 24.04.1 LTS
Release:        24.04
Codename:       noble

Suggested solution
It appears that simply

chmod 0644  /usr/share/keyrings/cloudfoundry-keyring.gpg

is missing in between.
As the file only contains the public key, it appears not to be security issue, relaxing the file modes.
Further details can also be found at https://stackoverflow.com/a/71384057.

Lingua principale
Go
Stelle
1.9k
Fork
990
Merge medio
1g 7h
PR unite (30g)
8

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di cloudfoundry/cli

Tutte le issue di cloudfoundry/cli

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.