Enable project access to AlloyDB

This page describes how to enable access to AlloyDB in a new or existing Google Cloud project.

Console

  1. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  2. Make sure that billing is enabled for your Google Cloud project. Learn how to confirm that billing is enabled for your project.

  3. Enable the AlloyDB, Compute Engine, and Resource Manager APIs.

    Enable the APIs

  4. If you plan to configure network connectivity to AlloyDB using a VPC network that resides in the same Google Cloud project as AlloyDB, then enable the Service Networking API in the project.

    Enable the API

    If you plan to configure network connectivity to AlloyDB using a VPC network that resides in a different Google Cloud project, then confirm that the Compute Engine and Service Networking APIs in that project are enabled so that you can configure Shared VPC and private services access in that project.

    Check the project's enabled APIs

gcloud

  1. Create a Google Cloud project or use an existing project:

    gcloud projects create PROJECT_ID --set-as-default
    # For an existing project
    gcloud config set project PROJECT_ID
    

    Replace the following:

    • PROJECT_ID: the permanent identifier for the project.
  2. Make sure that billing is enabled for your Google Cloud project. Learn how to confirm that billing is enabled for your project.

  3. Enable the AlloyDB, Compute Engine, and Resource Manager APIs:

    gcloud services enable alloydb.googleapis.com
    gcloud services enable compute.googleapis.com
    gcloud services enable cloudresourcemanager.googleapis.com
    
  4. If you plan to configure network connectivity to AlloyDB using a VPC network that resides in the same Google Cloud project as AlloyDB, then enable the Service Networking API in the project.

    gcloud services enable servicenetworking.googleapis.com
    
  5. If you plan to configure network connectivity to AlloyDB using a VPC network that resides in a different Google Cloud project, then confirm that the Compute Engine and Service Networking API in that project are enabled so that you can configure Shared VPC and private services access in that project.

    gcloud services list