gcloud database-migration connection-profiles create alloydb - create a Database Migration Service connection profile for AlloyDB
gcloud database-migration connection-profiles create alloydb (CONNECTION_PROFILE : --region=REGION) --cpu-count=CPU_COUNT --password=PASSWORD --primary-id=PRIMARY_ID [--no-async] [--cluster-labels=[KEY=VALUE,...]] [--database-flags=[FLAG=VALUE,...]] [--display-name=DISPLAY_NAME] [--labels=[KEY=VALUE,...]] [--network=NETWORK] [--primary-labels=[KEY=VALUE,...]] [GCLOUD_WIDE_FLAG ...]
Create a Database Migration Service destination connection profile for AlloyDB. This will create an AlloyDB cluster and primary instance.
To create a connection profile for AlloyDB:
$ gcloud database-migration connection-profiles create alloydb \ my-profile --region=us-central1 --password=my_password \ --primary-id=my-primary --cpu-count=2
- Connection profile resource - The connection profile to create. The arguments
in this group can be used to specify the attributes of this resource. (NOTE) Some attributes are not given arguments in this group but can be set in other ways. To set the project attribute:
- —
provide the argument connection_profile on the command line with a fully specified name;
- —
provide the argument --project on the command line;
- —
set the property core/project.
This must be specified.
- CONNECTION_PROFILE
ID of the connection_profile or fully qualified identifier for the connection_profile. To set the connection_profile attribute:
provide the argument connection_profile on the command line.
This positional argument must be specified if any of the other arguments in this group are specified.
- --region=REGION
The Cloud region for the connection_profile. To set the region attribute:
provide the argument connection_profile on the command line with a fully specified name;
provide the argument --region on the command line.
- --cpu-count=CPU_COUNT
Whole number value indicating how many vCPUs the machine should contain. Each vCPU count corresponds to a N2 high-mem machine: https://cloud.google.com/compute/docs/general-purpose-machines#n2_machines. CPU_COUNT must be one of: 2, 4, 8, 16, 32, 64.
- --password=PASSWORD
Initial password for the 'postgres' user.
- --primary-id=PRIMARY_ID
The ID of the primary instance for this AlloyDB cluster.
- --no-async
Waits for the operation in progress to complete before returning.
- --cluster-labels=[KEY=VALUE,...]
The resource labels for an AlloyDB cluster. An object containing a list of "key": "value" pairs.
- --database-flags=[FLAG=VALUE,...]
Comma-separated list of database flags to set on the AlloyDB primary instance. Use an equals sign to separate the flag name and value. Flags without values, like skip_grant_tables, can be written out without a value, e.g., skip_grant_tables=. Use on/off values for booleans. View AlloyDB's documentation for allowed flags (e.g., --database-flags max_allowed_packet=55555,skip_grant_tables=,log_output=1).
- --display-name=DISPLAY_NAME
A user-friendly name for the connection profile. The display name can include letters, numbers, spaces, and hyphens, and must start with a letter.
- --labels=[KEY=VALUE,...]
List of label KEY=VALUE pairs to add.
Keys must start with a lowercase character and contain only hyphens (-), underscores (_), lowercase characters, and numbers. Values must contain only hyphens (-), underscores (_), lowercase characters, and numbers.
- --network=NETWORK
The VPC network from which the AlloyDB instance is accessible via private IP. For example, projects/myProject/global/networks/default. This setting cannot be updated after it is set.
- --primary-labels=[KEY=VALUE,...]
The resource labels for an AlloyDB primary instance. An object containing a list of "key": "value" pairs.
These flags are available to all commands: --access-token-file, --account, --billing-project, --configuration, --flags-file, --flatten, --format, --help, --impersonate-service-account, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity.
Run $ gcloud help for details.