Cria contas de serviço do Google Cloud Platform (GCP) com papéis que permitem
que componentes individuais da Apigee híbrida façam chamadas de API autorizadas e façam o download
dos arquivos de chave da conta de serviço associados. É possível usar
os arquivos de chave da conta de serviço gerados por esse comando no arquivo de modificação da configuração.
A ferramenta create-service-account está localizada no
diretório hybrid_root_dir/tools.
Pré-requisitos
A ferramenta create-service-account requer que a CLI do gcloud esteja
instalada. Os usuários que invocam o utilitário precisam ter o papel Service Account Admin.
component_name: especifica o serviço híbrido que usa a conta de serviço. Os valores
válidos são:
apigee-cassandra
apigee-distributed-trace
apigee-logger
apigee-mart
apigee-metrics
apigee-synchronizer
apigee-udca
apigee-watcher
Observe que a ferramenta create-service-account não pode criar a
conta de serviço apigee-org-admin. Crie essas informações com as
APIs do GCP ou da gcloud, conforme descrito em Criar contas de serviço.
output_dir: o diretório de saída no qual armazenar a chave da conta de serviço
salva.
gcp_project_id: (opcional) especifica o ID do projeto do GCP que está vinculado
à sua organização habilitada para o ambiente híbrido. Se o ID do projeto do GCP não for fornecido, a ferramenta tentará
recuperá-lo a partir da configuração atual da gcloud.
Descrição detalhada
A ferramenta create-service-account:
Cria contas de serviço do GCP
usadas por componentes híbridos. A conta de serviço criada recebe o papel necessário para
que o componente específico opere.
Faz o download da chave da conta de serviço no seu sistema. Coloque as chaves da conta de serviço no
arquivo de modificação de configuração híbrida, conforme explicado nas
instruções de instalação híbridas.
A ferramenta cria contas de serviço para os seguintes componentes:
Componente*
Papel
Necessário para instalação básica?
Descrição
apigee-cassandra
Administrador de objetos do Storage
Permite backups do Cassandra para o Cloud Storage, conforme
descrito em Backup e recuperação.
apigee-logger
Gravador de registros
Permite a coleta de dados de geração de registros, conforme descrito em Geração de registros. Necessário apenas para instalações de clusters que não
sejam do GKE.
apigee-mart
Agente do Apigee Connect
Permite a autenticação do serviço MART. O papel de Apigee Connect Agent ajuda a se comunicar
com segurança com o processo do Apigee Connect, conforme descrito em Como
usar o Apigee Connect.
Permite que o sincronizador faça o download de pacotes de proxy e dados de configuração
do ambiente. Ativa também a operação do recurso de rastreamento.
apigee-udca
Agente de análise da Apigee
Permite a transferência de dados de status de rastreamento, análise e implantação para o plano de
gerenciamento.
apigee-watcher
Agente do ambiente de execução da Apigee
O Apigee Watcher extrai alterações virtuais dos hosts relacionados a uma organização no sincronizador e faz as
alterações necessárias para configurar a entrada istio.
* Esse nome é usado no nome de arquivo da chave da conta
de serviço salva.
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-08-28 UTC."],[[["\u003cp\u003eThe \u003ccode\u003ecreate-service-account\u003c/code\u003e tool generates Google Cloud Platform (GCP) service accounts with the necessary roles for Apigee hybrid components to make authorized API calls, and it also downloads the associated service account key files.\u003c/p\u003e\n"],["\u003cp\u003eThis tool is located in the \u003ccode\u003e<var>hybrid_root_dir</var>/tools\u003c/code\u003e directory and requires the \u003ccode\u003egcloud\u003c/code\u003e CLI to be installed with the user having the \u003ccode\u003eService Account Admin\u003c/code\u003e role.\u003c/p\u003e\n"],["\u003cp\u003eYou must use the appropriate syntax \u003ccode\u003ecreate-service-account component_name output_dir [gcp_project_id]\u003c/code\u003e to create a service account, specifying the component, output directory, and optionally the GCP project ID.\u003c/p\u003e\n"],["\u003cp\u003eThe tool cannot be used to create the \u003ccode\u003eapigee-org-admin\u003c/code\u003e service account; it must be created using either the GCP or gCloud APIs, which is fully documented.\u003c/p\u003e\n"],["\u003cp\u003eThe service accounts generated by the tool support various components, including \u003ccode\u003eapigee-cassandra\u003c/code\u003e, \u003ccode\u003eapigee-logger\u003c/code\u003e, \u003ccode\u003eapigee-mart\u003c/code\u003e, \u003ccode\u003eapigee-metrics\u003c/code\u003e, \u003ccode\u003eapigee-synchronizer\u003c/code\u003e, \u003ccode\u003eapigee-udca\u003c/code\u003e, and \u003ccode\u003eapigee-watcher\u003c/code\u003e, each with specific roles for their respective functions within the Apigee hybrid environment.\u003c/p\u003e\n"]]],[],null,["# create-service-account\n\n| You are currently viewing version 1.3 of the Apigee hybrid documentation. **This version is end of life.** You should upgrade to a newer version. For more information, see [Supported versions](/apigee/docs/hybrid/supported-platforms#supported-versions).\n\nCreates Google Cloud Platform (GCP) service accounts with roles that allow\nindividual Apigee hybrid components to make authorized API calls and downloads\nthe associated service account key files. You can use\nthe service account key files generated by this command in your configuration overrides file.\n\nThe `create-service-account` tool is located in\n\u003cvar translate=\"no\"\u003ehybrid_root_dir\u003c/var\u003e`/tools` directory.\n\nPrerequisites\n-------------\n\nThe `create-service-account` tool requires that the [gcloud](https://cloud.google.com/sdk/gcloud/) CLI be\ninstalled. Users invoking the utility should have the role `Service Account Admin`.\n\nTo get started, be sure your `gcloud` project\nconfiguration is set to the project you created in [Step 2: Create a Google Cloud project](/apigee/docs/hybrid/v1.3/precog-gcpproject): \n\n```\ngcloud config list project\n```\n\n\nIf you need to change the current project ID, use this command: \n\n```\ngcloud config set project gcp_project_id\n```\n\nWhere \u003cvar translate=\"no\"\u003egcp_project_id\u003c/var\u003e is the project created in [Step 2: Create a Google Cloud project](/apigee/docs/hybrid/v1.3/precog-gcpproject).\n\ncreate-service-account syntax\n-----------------------------\n\nThe `create-service-account` tool uses the following syntax: \n\n```\ncreate-service-account component_name output_dir [gcp_project_id]\n```\n\nWhere:\n\n- \u003cvar translate=\"no\"\u003ecomponent_name\u003c/var\u003e: Specifies the hybrid service that uses the service account. Valid values are:\n - `apigee-cassandra`\n - `apigee-distributed-trace`\n - `apigee-logger`\n - `apigee-mart`\n - `apigee-metrics`\n - `apigee-synchronizer`\n - `apigee-udca`\n - `apigee-watcher`\n\n Note that the `create-service-account` tool cannot create the\n `apigee-org-admin` service account. You must create that either with the\n GCP or gCloud APIs, as described in [Create service accounts](/apigee/docs/hybrid/v1.3/install-download-install#create-service-accounts).\n- \u003cvar translate=\"no\"\u003eoutput_dir\u003c/var\u003e: The output directory in which to store the downloaded service account key.\n- \u003cvar translate=\"no\"\u003egcp_project_id\u003c/var\u003e: (Optional) Specifies the GCP project ID of the project that is bound to your hybrid-enabled organization. If the GCP project ID is not provided, the tool attempts to retrieve it from the current gcloud configuration.\n\nDetailed description\n--------------------\n\nThe `create-service-account` tool:\n\n- Creates [GCP service accounts](https://cloud.google.com/iam/docs/service-accounts) used by hybrid components. The created service account is granted the role required by the specific component to operate.\n- Downloads the service account key to your system. You place the service account keys in your hybrid configuration overrides file, as explained in the hybrid [installation instructions](/apigee/docs/hybrid/v1.3/install-before-begin).\n\nThe tool creates service accounts for the following components:\n\nYou can also create service accounts in the GCP Console. See also\n[Creating\nand managing service accounts](https://cloud.google.com/iam/docs/creating-managing-service-accounts).\n\nExample\n-------\n\nThe following example creates a new service account for the `apigee-logger`\nservice and places the downloaded key in the `./service-accounts` directory. \n\n```\n./my-hybrid-root/tools/create-service-account apigee-logger ./service-accounts\n```"]]