Manage AI zone visibility

This page explains how to check if AI zones are visible for your Cloud de Confiance by S3NS project, and how to turn AI zone visibility on or off.

AI zones are specialized zones optimized for artificial intelligence (AI) and machine learning (ML) training and inference workloads. To help your team discover and use AI zones in your Cloud de Confiance by S3NS project, turn on AI zone visibility. AI zone visibility determines whether Cloud de Confiance displays AI zones in your project's zone listings and console interfaces. If you turn off AI zone visibility, then Cloud de Confiance hides AI zones from the following interfaces:

  • Cloud de Confiance console
  • Google Cloud CLI zone listing commands
  • REST API

If the parent region is active in your project, then turning off AI zone visibility doesn't restrict API endpoints or block regional platform settings in the background, such as compute.InstanceSettings. To prevent creation of resources in AI zones, see Restrict resource creation in AI zones.

To learn more about AI zones, read the AI zones documentation.

Before you begin

  • If you haven't already, set up authentication. Authentication verifies your identity for access to Cloud de Confiance by S3NS services and APIs. To run code or samples from a local development environment, you can authenticate to Compute Engine by selecting one of the following options:

    Select the tab for how you plan to use the samples on this page:

    Console

    When you use the Cloud de Confiance console to access Cloud de Confiance by S3NS services and APIs, you don't need to set up authentication.

    gcloud

    1. Install the Google Cloud CLI, and then sign in to the gcloud CLI with your federated identity. After signing in, initialize the Google Cloud CLI by running the following command:

      gcloud init
    2. Set a default region and zone.

    REST

    To use the REST API samples on this page in a local development environment, you use the credentials you provide to the gcloud CLI.

      Install the Google Cloud CLI, and then sign in to the gcloud CLI with your federated identity.

    For more information, see Authenticate for using REST in the Cloud de Confiance authentication documentation.

Required roles

To get the permissions that you need to turn on or turn off AI zone visibility, ask your administrator to grant you the Compute Admin (roles/compute.admin) IAM role on the project. For more information about granting roles, see Manage access to projects, folders, and organizations.

You might also be able to get the required permissions through custom roles or other predefined roles.

Check if AI zones are visible for a project

To check if AI zones are visible for your Cloud de Confiance by S3NS project, verify whether or not the feature ai-zones-visibility (Preview) is turned on for your Cloud de Confiance by S3NS project. For new Cloud de Confiance projects, AI zone visibility is turned off by default.

Google Cloud CLI

Use the gcloud compute preview-features list command. The response that you get indicates if the feature ai-zones-visibility is turned on or turned off.

gcloud compute preview-features list --filter="name=ai-zones-visibility"

REST

Make the following GET request to the previewFeatures.list method.

GET https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/global/previewFeatures/ai-zones-visibility

Replace PROJECT_ID with your project ID.

Make AI zones visible for a project

To make AI zones visible for your Cloud de Confiance project, turn on AI zone visibility for your project.

Google Cloud CLI

Use the gcloud compute preview-features command, setting the activation status as enabled and the rollout plan as fast-rollout.

gcloud compute preview-features update ai-zones-visibility \
    --activation-status=enabled \
    --rollout-plan=fast-rollout

REST

Make the following PATCH request to the previewFeatures.update method. In the request body, include the following fields:

  • The activation_status field, set to ENABLED.
  • The rollout_operation.predefined_rollout_plan field, set to ROLLOUT_PLAN_FAST_ROLLOUT.
PATCH https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/global/previewFeatures/ai-zones-visibility
{
  "activation_status": "ENABLED",
  "rollout_operation": {
    "rollout_input": {
      "predefined_rollout_plan": "ROLLOUT_PLAN_FAST_ROLLOUT"
    }
  }
}

Replace PROJECT_ID with your project ID.

Hide AI zones for your project

To hide AI zones from your Cloud de Confiance project's zone listings and console deployment interfaces, turn off AI zone visibility.

Google Cloud CLI

Use the gcloud compute preview-features command, setting the activation status as unspecified and the rollout plan as fast-rollout.

gcloud compute preview-features update ai-zones-visibility \
    --activation-status=unspecified \
    --rollout-plan=fast-rollout

REST

Make the following PATCH request to the previewFeatures.update method. In the request body, include the following fields:

  • The activation_status field, set to ACTIVATION_STATE_UNSPECIFIED.
  • The rollout_operation.predefined_rollout_plan field, set to ROLLOUT_PLAN_FAST_ROLLOUT.
PATCH https://compute.googleapis.com/compute/v1/projects/PROJECT_ID/global/previewFeatures/ai-zones-visibility
{
  "activation_status": "ACTIVATION_STATE_UNSPECIFIED",
  "rollout_operation": {
    "rollout_input": {
      "predefined_rollout_plan": "ROLLOUT_PLAN_FAST_ROLLOUT"
    }
  }
}

Replace PROJECT_ID with your project ID.

Restrict resource creation in AI zones

If your organization has data residency, compliance, or governance requirements mandating that no resources or system configurations exist in AI zones, use Organization Policy Service to restrict resource creation in AI zones. For more information, see Restrict resource locations.

What's next