Restez organisé à l'aide des collections
Enregistrez et classez les contenus selon vos préférences.
Cette page explique comment configurer l'application de l'autorisation binaire dans votre environnement pour l'utiliser avec Google Kubernetes Engine (GKE). Vous pouvez configurer l'autorisation binaire à l'aide de Google Cloud Console ou de Google Cloud CLI.
Vous pouvez également effectuer certaines étapes de configuration à l'aide de l'API REST d'autorisation binaire.
L'activation de l'API d'autorisation binaire vous permet également d'afficher les problèmes liés à l'exécution d'images de conteneurs sur la page Stratégie de sécurité GKE dans la console Google Cloud, sans activer les fonctionnalités sur les clusters individuels.
Pour en savoir plus, consultez la page À propos du tableau de bord de stratégie de sécurité dans la documentation de GKE.
Facultatif : Si vous avez différents projets Google Cloud associés à votre stratégie ou à vos dépôts Container Registry, accordez les rôles IAM requis pour l'accès entre projets. Pour obtenir des instructions, consultez la page Configurer l'accès entre projets pour l'autorisation binaire dans GKE.
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2024/12/21 (UTC).
[[["Facile à comprendre","easyToUnderstand","thumb-up"],["J'ai pu résoudre mon problème","solvedMyProblem","thumb-up"],["Autre","otherUp","thumb-up"]],[["Difficile à comprendre","hardToUnderstand","thumb-down"],["Informations ou exemple de code incorrects","incorrectInformationOrSampleCode","thumb-down"],["Il n'y a pas l'information/les exemples dont j'ai besoin","missingTheInformationSamplesINeed","thumb-down"],["Problème de traduction","translationIssue","thumb-down"],["Autre","otherDown","thumb-down"]],["Dernière mise à jour le 2024/12/21 (UTC)."],[[["\u003cp\u003eThis guide explains how to set up Binary Authorization enforcement for Google Kubernetes Engine (GKE) using the Google Cloud console, Google Cloud CLI, or the Binary Authorization REST API.\u003c/p\u003e\n"],["\u003cp\u003eSetting up Binary Authorization involves enabling the service, creating or modifying a cluster, and configuring the Binary Authorization policy with options for default rules, cluster-specific rules, and exempt images.\u003c/p\u003e\n"],["\u003cp\u003eOptional configurations include granting cross-project access, using the \u003ccode\u003ebuilt-by-cloud-build\u003c/code\u003e attestor for Cloud Build images, and utilizing attestations.\u003c/p\u003e\n"],["\u003cp\u003eThe process includes steps for deploying container images and viewing events in Cloud Audit Logs.\u003c/p\u003e\n"],["\u003cp\u003eBinary Authorization does not enforce init containers.\u003c/p\u003e\n"]]],[],null,["# Set up for GKE\n\nThis page provides an overview of how to set up Binary Authorization enforcement in your\nenvironment for use with Google Kubernetes Engine (GKE). You can set up\nBinary Authorization by using the Google Cloud console or the Google Cloud CLI.\nYou can also perform some setup steps by using the Binary Authorization\n[REST API](/binary-authorization/docs/reference/rest).\n\nFor an end-to-end tutorial that includes the following setup steps, see\n[Get started using the Google Cloud CLI](/binary-authorization/docs/getting-started-cli)\nor\n[Get started using the Google Cloud console](/binary-authorization/docs/getting-started-console).\n\nTo set up Binary Authorization, perform the following steps:\n\n1. [Enable Binary Authorization](/binary-authorization/docs/enabling).\n\n2. [Create a cluster](/binary-authorization/docs/creating-cluster)\n with Binary Authorization enabled or\n [enable Binary Authorization on an existing cluster](/binary-authorization/docs/enable-cluster).\n\n | **Note:** Binary Authorization doesn't enforce init containers.\n3. Configure your Binary Authorization policy.\n\n | **Note:** Skip this step if you want to use attestations.\n\n You can configure the following features in your policy:\n - [Default rule](/binary-authorization/docs/configuring-policy-console#default-rule).\n - [Cluster-specific rules](/binary-authorization/docs/configuring-policy-console#set_cluster_specific_rules).\n - [Specific rules for your Kubernetes service identity or namespace](/binary-authorization/docs/configuring-policy-console#add-specific-rules-asm).\n - [Exempt images](/binary-authorization/docs/configuring-policy-console#exempt_images). [Learn more about exempt images](/binary-authorization/docs/key-concepts#exempt_images).\n4. Optional: If you have different Google Cloud projects that own your\n policy or your Container Registry repositories, grant the IAM\n roles required for cross-project access. For instructions, see\n [Configure cross-project access for Binary Authorization in GKE](/binary-authorization/docs/cross-project-access-gke).\n\n5. Optional: Use the `built-by-cloud-build` attestor to [deploy only images built by Cloud Build](/binary-authorization/docs/deploy-cloud-build).\n\n6. Optional: [Use attestations](/binary-authorization/docs/attestations).\n\n7. [Deploy container images](/binary-authorization/docs/deploying-containers).\n\n8. [View events in Cloud Audit Logs](/binary-authorization/docs/viewing-audit-logs)."]]