Pular para o conteúdo
AggregaAggrega
Selecionar língua: Português (Portugal)
Esta página foi traduzida automaticamente. Ler o original em inglês.

aggrega registry

Gerir registos e a sua política de confiança de assinaturas

Sinopse

aggrega registry

Descrição

Manage the OCI registries Aggrega publishes to and resolves from, together with
the signature trust policy for each.
A registry entry records where to reach the registry and what to require of the
signatures on artifacts it serves — which identities are trusted, and whether a
signature is required at all. That policy is what "aggrega pull" enforces when
it verifies an artifact and what "aggrega push" honours when it decides whether
to sign.
"aggrega registry add" can fetch a registry's own advertised trust policy rather
than having you write it out. "aggrega registry update" builds the local
searchable index that "aggrega search" and "aggrega plugin add" read.
A registry entry is written to the global config shared across every workspace
on this machine, because a registry and the identities you trust on it are
usually the same wherever you work. That makes adding or removing one a
machine-wide change: every project on this machine resolves through the entry
you just wrote or dropped. Pass --workspace to write it to this project's config
file instead. Building the searchable index is the exception — that lands in
this workspace's own artifact cache and reaches no other project.

Subcomandos

ComandoDescrição
aggrega registry addRegistar um registo e a sua política de confiança de assinaturas
aggrega registry listListar os registos configurados e a sua postura de confiança
aggrega registry removeRemover um registo e a sua política de confiança de um ficheiro de configuração
aggrega registry updateConstruir o índice local pesquisável dos registos configurados

Descrição de aggrega registry add

Register a registry host and its signature trust policy.
The entry is keyed under the host exactly as written, and every lookup of it is
made in one spelling: a lowercase host name containing a dot, localhost, a single
name followed by a port (registry:5000), an IPv4 address, or an IPv6 address in
brackets, each with an optional :port. A reference may be given instead — its
scheme, path and credentials are dropped and the entry is keyed under the host it
names — but a host written in capitals, with the default HTTPS port, or as a
single name with no port is refused, naming the spelling to write where there is
one.
The entry is written to the global config shared across every workspace, since a
registry and the identities you trust on it are usually the same wherever you
work. Pass --workspace to write it to this project's config file instead; the two
flags are mutually exclusive.
By default the registry's advertised trust policy is fetched once from the
registry's own origin (https://<host>/.well-known/aggrega-trust) and pinned
locally — trust-on-first-use. Verification at pull time always runs against the
pinned local policy, never a live re-fetch. Pass --fetch-trust=false to skip the
fetch and pin only what the flags supply.
A trust policy can also be set by hand: keyless (one or more --identity entries,
each an "identity=issuer" pair) or keyed (--key pointing at a pinned public-key
PEM). Manual --identity / --key flags OVERRIDE the fetched set — when either is
supplied, the fetch is skipped and the policy is built from the flags alone.
Pass --trusted-root to pin a Sigstore trust-root bundle for air-gapped keyless
verification. Adding the official hub host with no policy flags pins the built-in
official baseline.
When the registry advertises no trust policy (a 404 or an unreachable endpoint),
the add does not fail: it writes the policy from the flags (or an empty policy)
and prints a notice suggesting manual --identity / --key pinning. The official
hub writes its built-in baseline instead, and the notice says the baseline was
pinned.
When the workspace is offline the advertised policy cannot be fetched, so the
registry is never asked. Adding a registry other than the official hub is then
refused unless --identity or --key supplies the policy, rather than writing an
entry that trusts nothing: register it once while online, or pin it by hand.
Adding the official hub offline pins its built-in baseline, with a notice saying
so, and a manual policy registers offline exactly as it does online.
Existing settings in the target config file are preserved.

Opções de aggrega registry add

FlagPredefiniçãoDescrição
--advisoryfalseRebaixar as falhas de verificação deste registo para avisos em vez de parar
--fetch-trusttrueObter e fixar a política de confiança anunciada pelo registo na primeira utilização. Use —fetch-trust=false para saltar; —identity/—key manuais também saltam a obtenção.
--globalfalseEscrever a entrada na configuração global partilhada por todos os espaços de trabalho. Um registo vai para aqui por predefinição.
--identity[]Identidade keyless de confiança no formato identity=issuer, por exemplo dev@example.com=https://accounts.google.com (repetível; conjunto OU). Substitui a política de confiança obtida.
--key—Caminho para um PEM de chave pública fixada compatível com cosign, para verificação com chave. Substitui a política de confiança obtida.
--name—Alias amigável opcional para este registo. O anfitrião continua a ser a identidade; o alias resolve para ele onde quer que um registo seja nomeado (p. ex., —registry). Tem de ser único entre os registos.
--require-signaturesfalseExigir uma assinatura em todos os artefactos obtidos deste registo (e enviados para ele)
--trusted-root—Caminho para um pacote de raiz de confiança Sigstore fixado, para verificação keyless em ambiente isolado
--workspacefalseEscrever a entrada na configuração do espaço de trabalho deste projeto em vez da configuração global.

Descrição de aggrega registry list

List every registry configured in the effective merged config, one per line,
with its friendly alias (if any), a short trust-posture summary, and a marker on
the default registry.
This reads the resolved configuration and never contacts a registry. Registries
are listed in ascending host order.
With -o json the same set is emitted as one structured document per registry:
its host, its alias, whether it is the default, its trust posture as discrete
fields rather than the table's rendered sentence, and whether a credential for
that host is present in the shared credential store. The credential state reports
presence only — a credential is never read out, measured, or shown in any form,
and whether the registry would accept it is not asked, since that would take a
network round trip. Reading it consults the local credential store, which honors
a configured credential helper. The order is the same ascending host order the
table uses.

Opções de aggrega registry list

FlagPredefiniçãoDescrição
--output, -otableFormato de saída: table|json.

Descrição de aggrega registry remove

Remove a registry's trust-policy entry from a config file, addressed by its host
or its friendly alias.
By default the entry is removed from the global config shared across every
workspace; pass --workspace to remove it from this project's workspace config
instead. Setting both --global and --workspace is a usage error.
The default_registry pointer is left untouched — removing a registry's trust
policy reverts that host to default trust; it does not change which registry is
the default. Where default_registry names the removed entry by its alias, that
alias names nothing afterwards, and the configuration is refused until
default_registry is written as a host or as another entry's name.

Opções de aggrega registry remove

FlagPredefiniçãoDescrição
--globalfalseRemover a entrada da configuração global partilhada por todos os espaços de trabalho.
--workspacefalseRemover a entrada da configuração do espaço de trabalho deste projeto em vez da configuração global.

Descrição de aggrega registry update

Walk each configured registry's repositories, read the latest published version
of each, and write a deterministic local searchable index to the artifact cache.
With no argument, every configured registry is indexed. With a single registry
argument (a host or a friendly alias), only that registry is indexed.
This is the one registry command that reaches the network. The index it writes
lands in this workspace's own artifact cache, so refreshing it changes nothing
another project on this machine resolves through. Credentials are read from a
supplied or ambient source and never asked for: a registry that needs one you do
not have fails with a message naming what it wanted.
For each repository the highest strict-SemVer version is selected (pre-release
versions are skipped) and its catalog facets — kind, description, category,
labels, and, for plugins, socket type and capabilities — are recorded from the
published manifest. A repository with no conforming version is skipped; a
repository that cannot be read is skipped with a note, so one unreadable
repository does not abandon the whole index.
A registry that asks the walk to slow down — a 429 answer, or a 503 that says
how long to wait (Retry-After) — is left alone for as long as it asks, or ten
seconds where it does not say, and the walk reads fewer of its repositories at
once until it answers again, then returns to its usual pace; on a terminal the
wait is shown beside that registry's row. A registry that answers nothing but
"slow down" for five minutes is not indexed: it keeps the index it had before
the run, and the command names it, its last answer and how long it waited.
A read the registry fails or drops in passing — a 5xx answer, a connection
reset or timed out, an answer cut short — is asked again a few times, with a
growing wait between attempts. A repository with a read still
failing after that is not recorded from this run: it keeps the record the index
already holds for it, where that record was judged under the trust policy now in
force, and is otherwise left out of the index; either way it is named as a
repository that could not be read, as the walk goes and again in the closing
summary under its registry's row, with the kind of the read's last failure — the
status the registry answered, a timeout, a reset, an answer cut short — and the
read that failed. So a version is never recorded unsigned,
undated or without its deprecation marker because a read failed, with or without
--upgrade. Each registry's row in the closing summary also says how many reads
were asked again, whether or not they then succeeded — a read sent again after
the registry asked the walk to slow down among them — and says zero when none
was.
Every signature a registry's walk verifies against the public Sigstore trust root
is verified against the same copy of that root, fetched once for the walk rather
than once per signature; a registry whose trust policy pins a trust root of its
own is verified against that file.
A registry whose repository listing repeats itself — naming a repository it has
already named, or answering two pages in a row with no repository while still
pointing to a next page — is not followed round again. That registry is reported
as not indexed, with a message naming it and saying its repository listing
repeated itself; the other registries are still indexed, and the command exits
non-zero.
A registry that is not indexed keeps the index it had before the run, unchanged:
nothing is written for a registry whose walk failed, whose listing repeated
itself, or that was being walked when the command was interrupted. Registries
indexed earlier in the same run keep what this run wrote for them. A registry's
new index is written aside and put in place whole, so a command stopped while
writing one leaves that registry with a complete index — the one it had before
the run, or the new one — or with none, never with a partial one.
Every strict-SemVer version a recorded repository publishes is listed too, each
with the manifest digest its tag resolves to — the address of the exact bytes
published under that version. Where the registry's trust policy pins a public key
or trusted identities, and verification is not switched off, each version's own
signatures are verified against that policy and the signer is recorded when one
verifies; a version with no signature, or none that verifies, is recorded with no
signer. Where several verify, the signer recorded is the one the transparency log
recorded earliest, whatever order the registry lists them in, so signing a version
again never changes its recorded signer.
Each version's publication date is recorded too, with its source. Where one of the
version's keyless signatures verified, the date is the time the transparency log
recorded that earliest signature, as the verified log entry attests it (source
'transparency-log') — so signing a version again never moves its date. Otherwise
it is the date the publication itself stated beside what it published (source
'publisher'), the earliest where several are stated: the publishing machine's own
clock, which nothing attests, read from any registry whatever its trust policy.
A version with neither — published without stating a date, and not signed
keyless in a way this policy verifies — is recorded with no date.
Only manifests, signature attachments and publication-date attachments are read:
no entity's content is fetched. 'aggrega search -o json' reports these under each
record's 'published' field.
The per-repository records are byte-identical across two runs against the same
registry state; the freshness timestamp is written to a sibling file so it never
disturbs the records.
A refresh reads again only what changed, and finds every change a full re-read
would. For each repository it revalidates the tag listing with a conditional
request, resolves every version's tag to its manifest digest, and revalidates every
version's attachments — its signatures, publication-date statements and deprecation
markers — with one conditional request, plus one for the signatures of a
deprecation marker it judged before. A version whose digest or attachments changed
is read again in full, and its signatures and markers are verified again exactly as
a full re-read verifies them; everything else is kept as recorded. A change to this
registry's trust policy reads every version again under the policy now in force, and
so does a repository whose entry in the index records none of these checks. An
unchanged registry therefore costs one conditional request per repository and two
small requests per version (three where a deprecation marker was judged), with
nothing downloaded. A version is read again on the next refresh where it carries a
deprecation marker that was not honored, or where this run got no way to
revalidate its attachments — which, on a registry that offers none, is every
version.
Several repositories are read at a time. Everything the command records and prints
comes out in repository order, so the index and the output are the same as reading
one repository at a time would produce.
While it walks, a terminal shows the walk's progress on standard error, the way
build and pull show theirs: a row naming each registry, a spinner while that
registry's repository listing is read, then how many of its repositories the walk
has finished out of how many it lists, counted in repository order, and a bar for
the whole walk below the rows. On a terminal that cannot redraw in place, or with
--plain, each registry gets one plain line instead, written when its walk ends,
with the count it ended on and the time it took. When standard error is not a
terminal, no progress is shown. The progress changes nothing the command prints on
standard output.
Use --upgrade to read every repository in full, comparing nothing with the index
already written — to rebuild an index from the registry alone. It finds no change a
refresh without it would miss.
Each published version's deprecation markers are read as the walk goes, and the ones
whose own signature verifies are recorded into the index. Every marker read is
reported, whether or not it was recorded — a version kept as recorded is not read, so
its marker is not reported again — and each registry reports how many markers its
index now records, including when that number is zero. Where signature
verification is disabled for a registry, the walk reports that its markers were not
examined rather than a count, so a registry that published nothing is never confused
with one this run had no basis to judge.

Opções de aggrega registry update

FlagPredefiniçãoDescrição
--upgradefalseLê cada repositório na íntegra, sem comparar nada com o índice já escrito (uma atualização sem esta opção já volta a ler tudo o que mudou)

O que registry update reporta sobre os marcadores de descontinuação

Enquanto percorre um registo, aggrega registry update lê os marcadores de descontinuação de cada versão publicada e regista no índice local os que consegue autenticar. Reporta o resultado dessa análise em todos os casos, pelo que um registo que não publicou nenhum marcador se distingue de uma execução que não procurou nenhum.

Cada marcador que a varredura lê produz uma linha que indica o repositório, a versão e a severidade que o publicador registou — warning, error ou retracted — juntamente com a indicação de o marcador ter ou não sido registado. Uma versão cujos anexos não mudaram desde a última atualização é mantida tal como registada em vez de ser lida, pelo que o seu marcador não volta a ser reportado; a contagem abaixo continua a incluí-la. Um marcador só é registado quando a sua própria assinatura é verificada face aos signatários que a política de confiança do registry aceita. Um que está presente mas não é descodificado, ou presente mas não aceite, é reportado como tal e deixado fora do índice em vez de registado com base em provas que não puderam ser autenticadas — e o mesmo acontece com um que o registry responde que não tem. Um marcador cuja leitura falhou é um caso diferente: consulte-se Uma leitura que falha.

Cada registo reporta depois quantos marcadores o seu índice regista agora, incluindo quando esse número é zero. Onde a verificação de assinaturas está desligada — globalmente, ou para esse registo — o percurso reporta, em vez disso, que os marcadores não foram examinados para ele. São factos diferentes: o primeiro diz que o registo não publicou nada sobre o qual este espaço de trabalho possa agir, o segundo diz que esta execução não tinha nenhuma base de confiança para avaliar um marcador. Um registo cujos marcadores não foram examinados não contribui com nenhuma retirada para a seleção de versões, pelo que um autor que anexou um marcador e vê essa linha sabe porque não tem efeito.

A data de publicação que cada versão regista

A hora de criação de um manifesto publicado é fixada, pelo que o seu digest depende apenas do que é publicado e nunca de quando. A data em que uma versão foi publicada é, por isso, lida de junto do manifesto, e aggrega registry update regista-a para cada versão com a fonte de onde veio:

  • transparency-log — onde a assinatura da versão é keyless e é verificada em relação à política de confiança do registo, a hora a que o registo de transparência registou essa assinatura, que a promessa assinada do registo atesta. Onde várias das assinaturas da versão são verificadas, é a mais antiga das suas horas, e o signatário registado para a versão é o dessa mesma assinatura — seja qual for a ordem em que o registo lista as assinaturas — pelo que uma versão assinada de novo mantém a sua data e o seu signatário. Para uma versão assinada ao ser publicada, essa é a sua publicação; para uma assinada pela primeira vez depois com aggrega sign, é quando foi assinada. Esta fonte prevalece onde quer que exista.
  • publisher — caso contrário, a hora que a publicação indicou junto do que publicou: um pequeno anexo published-at que aggrega push e aggrega push-artifact escrevem com o próprio relógio da máquina que publica, que nada atesta. É lido de qualquer registo, seja qual for a sua política de confiança, porque é a declaração do publicador e não uma decisão de confiança. Onde estão anexados vários, é usado o mais antigo.

Uma versão sem nenhuma das duas não regista nenhuma data. É uma publicação que não indicou nenhuma, onde a sua assinatura não é uma keyless que esta política verifique — por exemplo, uma publicação keyless lida sob uma política que não confia em nenhuma identidade keyless, já que uma publicação keyless não indica nenhuma data própria. aggrega search -o json reporta a data sob cada versão em published.

O que uma atualização volta a ler

Uma atualização compara o que o registry serve agora com o que o índice registou, e volta a ler tudo o que mudou — a mesma resposta que uma releitura completa dá. Para cada repositório:

  • revalida a listagem de tags, pelo que uma versão publicada ou eliminada entretanto é detetada;
  • resolve a tag de cada versão para o manifesto que ela indica, pelo que uma versão mais antiga publicada de novo sob a sua tag existente volta a ser lida;
  • revalida os anexos de cada versão — as suas assinaturas, as suas declarações de data de publicação e os seus marcadores de descontinuação — pelo que uma assinatura, uma data ou um marcador anexado entretanto a uma versão é lido e verificado, e faz o mesmo com as assinaturas de um marcador de descontinuação que já avaliou antes;
  • compara a política de confiança do registry com aquela sob a qual o índice foi construído, pelo que uma alteração da política faz voltar a ler cada versão sob a nova.

Um marcador de descontinuação, uma assinatura e uma data de publicação são cada um anexados a uma versão publicada como um objeto separado que aponta de volta para ela — que é o que permite a um publicador descontinuar ou assinar uma versão sem a voltar a publicar — pelo que nenhum deles acrescenta uma tag nem altera o próprio manifesto da versão. Alteram os anexos da versão, e é isso que a terceira verificação revalida. A exclusão de versões e aggrega inspect leem ambos este índice, pelo que uma versão retirada desde a última atualização é excluída da seleção, e apresentada, assim que a atualização seguinte tiver corrido.

Cada verificação é um pequeno pedido — a resolução do digest de um manifesto, ou um pedido condicional a que o registry responde como inalterado sem enviar nada — pelo que a atualização de um registry inalterado não descarrega nada. Uma versão que contenha um marcador de descontinuação que não foi aceite, ou cujos anexos esta execução não teve forma de revalidar, volta a ser lida na atualização seguinte. Um registry que não consegue dizer se os anexos de uma versão mudaram faz com que cada versão volte a ser lida em cada atualização: a resposta é a mesma, e o custo de uma releitura completa também.

--upgrade lê cada repositório na íntegra, sem comparar nada com o índice já escrito. Pode usar-se para reconstruir um índice apenas a partir do registry; não deteta nada que uma atualização deixe escapar.

Um registo que pede para abrandar

O hub oficial, hub.aggrega.ai, limita quantos pedidos podem vir de um mesmo endereço num curto intervalo, pelo que as máquinas que partilham um endereço partilham essa quota, e qualquer registo pode limitar os seus clientes da mesma forma. Um registo que ultrapassou o seu limite responde 429 Too Many Requests, ou 503 Service Unavailable com um cabeçalho Retry-After que indica quanto tempo esperar. Cada pedido que a linha de comandos faz a um registo, seja qual for o comando, reage a essa resposta da mesma forma: espera o tempo que o registo pediu, ou dez segundos quando a resposta não o diz, mais até um segundo adicional aleatório, e depois pede de novo, sem um número fixo de tentativas. Cada pedido a esse registo espera com ele, não apenas o recusado, e são-lhe enviados menos pedidos em simultâneo — metade de cada vez que o pede, até chegar a um —, número que volta a subir um a um após cada série de pedidos que serve sem falhar, até ao número habitual do comando. A espera é mostrada nos mesmos termos que o resto do progresso do comando, como uma linha do tipo hub.aggrega.ai asked to slow down; waiting 11 s: aggrega build, aggrega pull e aggrega registry update mostram-na ao lado do passo em curso, os outros comandos que mostram aquilo de que estão à espera mostram-na como um passo próprio — exceto aggrega sign --jobs a assinar várias referências em simultâneo, que mostra essas esperas como um único passo — e nada é mostrado quando o erro padrão não é um terminal, a menos que o --progress do comando o peça. Um registo que durante cinco minutos não responde mais nada além de «abrande» é recusado com E0378, indicando o registo, a sua última resposta e há quanto tempo não respondia outra coisa; os cinco minutos são fixos, e nenhuma definição os altera. aggrega registry update indica então esse registo em Not indexed: no resumo final, e o registo mantém o índice que tinha antes da execução.

Uma leitura que falha

Uma varredura lê muitos objetos pequenos de um registry, e algumas leituras falham pontualmente: o registry responde que falhou ou está indisponível (um estado 5xx, exceto um 503 que indica quanto tempo esperar) ou que o pedido excedeu o tempo limite (um 408), a ligação é reposta ou excede o tempo limite, ou uma resposta termina antes de estar completa. Cada uma dessas leituras é pedida de novo algumas vezes, com uma espera crescente entre tentativas. Um registry que pede à varredura para abrandar não está a fazer falhar uma leitura: a leitura espera e é pedida de novo como descreve Um registo que pede para abrandar, e um registry que continua a pedi-lo durante cinco minutos termina a varredura desse registry, e não a de um único repositório.

Uma leitura que continua a falhar nunca é tomada como resposta. Uma assinatura que não pôde ser lida não é uma versão sem assinatura, e um marcador de descontinuação que não pôde ser lido não é uma versão que nunca foi retirada, pelo que a varredura não regista nada sobre esse repositório nesta execução. O repositório mantém o registo que o índice já tem para ele, quando esse registo foi avaliado sob a política de confiança do registry agora em vigor, e caso contrário é deixado fora do índice. Em qualquer dos casos, a varredura indica o repositório nos seus comentários durante a execução, dizendo qual dos dois casos aconteceu e que leitura falhou, e volta a indicá-lo no seu resumo final, numa linha própria sob a linha do seu registry, entre os repositórios que não puderam ser lidos:

Indexed 1 registry.
registry.example.com: 41 entities, 1 repository could not be read, 4 reads retried
component/core/web: the registry answered 503 Service Unavailable: …

A linha do registry indica também quantas leituras foram pedidas de novo, contando cada leitura uma única vez, independentemente de quantas tentativas exigiu e de ter ou não tido êxito depois, e indica 0 reads retried quando nenhuma o foi. Uma varredura cujas leituras acabaram todas por ter êxito não mostra nenhum repositório na sua linha, pelo que é esta contagem que diz quão perto esteve de deixar um de fora.

Cada uma dessas linhas começa pelo tipo da última falha da leitura — o estado com que o registry respondeu, uma leitura que excedeu o tempo limite, uma ligação que foi reposta ou uma resposta interrompida — seguido da própria falha, que diz que leitura era. Uma falha que não é de nenhum desses tipos, como uma raiz de confiança que não pôde ser obtida para verificar uma assinatura com ela, é indicada apenas pela falha. O método aggrega/registryUpdate de aggrega serve responde com os mesmos repositórios sob skipped de cada host, cada um com o mesmo reason, e com a contagem de leituras pedidas de novo como readsRetried. O mesmo se aplica a uma atualização e a --upgrade, e a varredura seguinte parte do que o índice contiver nessa altura, como acontece com qualquer repositório.

A chave pública que uma política com chave fixa

Uma política de confiança com chave fixa a chave pública do registo inline, como a public_key da entrada: aggrega registry add --key <file> copia para lá o conteúdo do ficheiro, e o mesmo faz a fixação de uma política que o registo anuncia com uma chave. O valor é um bloco PEM de chave pública — o texto desde uma linha -----BEGIN PUBLIC KEY-----, ou -----BEGIN RSA PUBLIC KEY-----, até à linha -----END correspondente — e qualquer texto acima do bloco é ignorado.

Um valor sem nenhuma linha -----BEGIN … PUBLIC KEY----- é recusado quando o ficheiro de configuração é carregado, nomeando o ficheiro e a entrada. registry add faz a mesma verificação antes de escrever, pelo que um ficheiro --key que contenha outra coisa — uma chave privada, um certificado ou uma chave noutra codificação — é recusado e o ficheiro de configuração fica como estava. Só essa linha é verificada: se o bloco descodifica para uma chave utilizável descobre-se quando uma assinatura do registo é verificada em relação a ele.

Offline

aggrega registry update é o único comando deste grupo cujo trabalho todo é um percurso pelos registos, e sob a postura offline — a chave de nível superior offline num ficheiro de configuração, AGGREGA_OFFLINE, ou --offline — recusa antes de percorrer o que quer que seja. A recusa nomeia qual dos três definiu a postura.

Não há nenhuma forma parcial a que recorrer, porque o índice regista o que cada registo serve atualmente e isso não pode ser sabido sem perguntar a um. O que um espaço de trabalho offline pode fazer é ler o índice que já tem: aggrega search e o aviso de descontinuação em aggrega inspect leem ambos o instantâneo local e não precisam de rede nenhuma, pelo que uma atualização é a única coisa que a postura retira. Para atualizar numa execução a partir de um espaço de trabalho offline, passe --offline=false.

aggrega registry add acede à rede uma vez, para a política de confiança que o registo anuncia, a menos que --fetch-trust=false, --identity ou --key indiquem que não se deve obter. Sob a postura offline, essa obtenção é recusada antes de qualquer ligação, pelo que o registo nunca é consultado. Acrescentar um registo que não seja o hub oficial é então recusado — acrescentar um registo é o único momento em que a sua confiança é fixada, e uma entrada escrita sem a política não confiaria em nada enquanto todos os pulls posteriores vinculariam o registo a ela. A recusa tem o código curto E0310 e nomeia ambos os caminhos possíveis: registá-lo uma vez com ligação, o que --offline=false permite para uma execução, ou fixar a política manualmente com --identity ou --key, que registam exatamente o que é fornecido e não fazem nenhuma obtenção. O hub oficial é acrescentado com a sua base incorporada, com um aviso que diz que não foi pedida ao hub a sua política de confiança porque o espaço de trabalho está offline e que é usada a base em seu lugar, e --fetch-trust=false regista a entrada a partir das suas opções exatamente como online. O mesmo registo feito através de aggrega serve ou aggrega mcp comporta-se da mesma forma: a mesma recusa nas mesmas palavras e, de resto, a mesma entrada. A registry is added offline with no trust policy to pin (Um registo é acrescentado offline sem política de confiança para fixar) cita a recusa.

list e remove alteram ou leem a configuração local e não são afetados.