mirror of
https://github.com/imjasonh/gcloud-help
synced 2026-07-10 19:31:55 +00:00
473 lines
20 KiB
Text
473 lines
20 KiB
Text
NAME
|
|
gcloud datastream connection-profiles create - create a Datastream
|
|
connection profile
|
|
|
|
SYNOPSIS
|
|
gcloud datastream connection-profiles create
|
|
(CONNECTION_PROFILE : --location=LOCATION) --display-name=DISPLAY_NAME
|
|
--type=TYPE [--force] [--labels=[KEY=VALUE,...]]
|
|
[[--bucket=BUCKET : --root-path=ROOT_PATH]
|
|
| --database-service=DATABASE_SERVICE
|
|
--oracle-hostname=ORACLE_HOSTNAME --oracle-port=ORACLE_PORT
|
|
--oracle-username=ORACLE_USERNAME (--oracle-password=ORACLE_PASSWORD
|
|
| --oracle-prompt-for-password) | [--mysql-hostname=MYSQL_HOSTNAME
|
|
--mysql-port=MYSQL_PORT
|
|
--mysql-username=MYSQL_USERNAME (--mysql-password=MYSQL_PASSWORD
|
|
| --mysql-prompt-for-password) : --ca-certificate=CA_CERTIFICATE
|
|
--client-certificate=CLIENT_CERTIFICATE --client-key=CLIENT_KEY]
|
|
| [--postgresql-database=POSTGRESQL_DATABASE
|
|
--postgresql-hostname=POSTGRESQL_HOSTNAME
|
|
--postgresql-port=POSTGRESQL_PORT
|
|
--postgresql-username=POSTGRESQL_USERNAME
|
|
(--postgresql-password=POSTGRESQL_PASSWORD
|
|
| --postgresql-prompt-for-password)
|
|
: [--postgresql-ca-certificate=POSTGRESQL_CA_CERTIFICATE
|
|
: --postgresql-client-certificate=POSTGRESQL_CLIENT_CERTIFICATE
|
|
--postgresql-client-key=POSTGRESQL_CLIENT_KEY]]
|
|
| --salesforce-domain=SALESFORCE_DOMAIN
|
|
(--salesforce-oauth2-client-id=SALESFORCE_OAUTH2_CLIENT_ID
|
|
(--salesforce-oauth2-client-secret=SALESFORCE_OAUTH2_CLIENT_SECRET
|
|
| --salesforce-prompt-for-oauth2-client-secret
|
|
| --salesforce-secret-manager-stored-oauth2-client-secret=SALESFORCE_SECRET_MANAGER_STORED_OAUTH2_CLIENT_SECRET) | --salesforce-username=SALESFORCE_USERNAME (--salesforce-password=SALESFORCE_PASSWORD | --salesforce-prompt-for-password | --salesforce-secret-manager-stored-password=SALESFORCE_SECRET_MANAGER_STORED_PASSWORD) (--salesforce-prompt-for-security-token | --salesforce-secret-manager-stored-security-token=SALESFORCE_SECRET_MANAGER_STORED_SECURITY_TOKEN | --salesforce-security-token=SALESFORCE_SECURITY_TOKEN)) | --sqlserver-database=SQLSERVER_DATABASE --sqlserver-hostname=SQLSERVER_HOSTNAME --sqlserver-port=SQLSERVER_PORT --sqlserver-username=SQLSERVER_USERNAME (--sqlserver-password=SQLSERVER_PASSWORD | --sqlserver-prompt-for-password)]
|
|
[--private-connection=PRIVATE_CONNECTION | --static-ip-connectivity
|
|
| [--forward-ssh-hostname=FORWARD_SSH_HOSTNAME
|
|
--forward-ssh-username=FORWARD_SSH_USERNAME
|
|
(--forward-ssh-password=FORWARD_SSH_PASSWORD
|
|
| --forward-ssh-private-key=FORWARD_SSH_PRIVATE_KEY)
|
|
: --forward-ssh-port=FORWARD_SSH_PORT; default=22]]
|
|
[GCLOUD_WIDE_FLAG ...]
|
|
|
|
DESCRIPTION
|
|
Create a Datastream connection profile
|
|
|
|
EXAMPLES
|
|
To create a connection profile for Oracle:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=oracle \
|
|
--oracle-password=fakepassword --oracle-username=fakeuser \
|
|
--display-name=my-profile --oracle-hostname=35.188.150.50 \
|
|
--oracle-port=1521 --database-service=ORCL \
|
|
--static-ip-connectivity
|
|
|
|
To create a connection profile for MySQL:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=mysql \
|
|
--mysql-password=fakepassword --mysql-username=fakeuser \
|
|
--display-name=my-profile --mysql-hostname=35.188.150.50 \
|
|
--mysql-port=3306 --static-ip-connectivity
|
|
|
|
To create a connection profile for PostgreSQL:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=postgresql \
|
|
--postgresql-password=fakepassword \
|
|
--postgresql-username=fakeuser --display-name=my-profile \
|
|
--postgresql-hostname=35.188.150.50 --postgresql-port=5432 \
|
|
--postgresql-database=db --static-ip-connectivity
|
|
|
|
To create a connection profile for SQL Server:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=sqlserver \
|
|
--sqlserver-password=fakepassword \
|
|
--sqlserver-username=fakeuser --display-name=my-profile \
|
|
--sqlserver-hostname=35.188.150.50 --sqlserver-port=1433 \
|
|
--sqlserver-database=db --static-ip-connectivity
|
|
|
|
To create a connection profile for Salesforce using Username, Password and
|
|
Security Token:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=salesforce \
|
|
--salesforce-password=fakepassword \
|
|
--salesforce-username=fakeuser \
|
|
--salesforce-security-token=fakesecuritytoken \
|
|
--display-name=my-profile --salesforce-hostname=35.188.150.50 \
|
|
--salesforce-port=1433 --salesforce-database=db \
|
|
--static-ip-connectivity
|
|
|
|
To create a connection profile for Salesforce using OAuth:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=salesforce \
|
|
--salesforce-client-secret=fakesecret \
|
|
--salesforce-client-id=fake-client-id \
|
|
--display-name=my-profile \
|
|
--salesforce-domain=fakecompany.my.salesforce.com \
|
|
--static-ip-connectivity
|
|
|
|
To create a connection profile for Google Cloud Storage:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=google-cloud-storage \
|
|
--bucket=fake-bucket --root-path=/root/path \
|
|
--display-name=my-profile
|
|
|
|
To create a connection profile for BigQuery:
|
|
|
|
$ gcloud datastream connection-profiles create CONNECTION_PROFILE \
|
|
--location=us-central1 --type=bigquery --display-name=my-profile
|
|
|
|
POSITIONAL ARGUMENTS
|
|
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.
|
|
|
|
--location=LOCATION
|
|
The Cloud location for the connection_profile.
|
|
|
|
To set the location attribute:
|
|
▸ provide the argument connection_profile on the command line with
|
|
a fully specified name;
|
|
▸ provide the argument --location on the command line.
|
|
|
|
REQUIRED FLAGS
|
|
--display-name=DISPLAY_NAME
|
|
Friendly name for the connection profile.
|
|
|
|
--type=TYPE
|
|
Type can be MYSQL, ORACLE, POSTGRESQL, GOOGLE-CLOUD-STORAGE or BIGQUERY
|
|
|
|
OPTIONAL FLAGS
|
|
--force
|
|
Create the connection profile without validating it.
|
|
|
|
--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.
|
|
|
|
At most one of these can be specified:
|
|
|
|
--bucket=BUCKET
|
|
The full project and resource path for Cloud Storage bucket including
|
|
the name.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--root-path=ROOT_PATH
|
|
The root path inside the Cloud Storage bucket.
|
|
|
|
--database-service=DATABASE_SERVICE
|
|
Database service for the Oracle connection.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--oracle-hostname=ORACLE_HOSTNAME
|
|
IP or hostname of the oracle source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--oracle-port=ORACLE_PORT
|
|
Network port of the oracle source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--oracle-username=ORACLE_USERNAME
|
|
Username Datastream will use to connect to the database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--oracle-password=ORACLE_PASSWORD
|
|
Password for the user that Datastream will be using to connect to
|
|
the database. This field is not returned on request, and the value
|
|
is encrypted when stored in Datastream.
|
|
|
|
--oracle-prompt-for-password
|
|
Prompt for the password used to connect to the database.
|
|
|
|
--mysql-hostname=MYSQL_HOSTNAME
|
|
IP or hostname of the MySQL source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--mysql-port=MYSQL_PORT
|
|
Network port of the MySQL source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--mysql-username=MYSQL_USERNAME
|
|
Username Datastream will use to connect to the database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--mysql-password=MYSQL_PASSWORD
|
|
Password for the user that Datastream will be using to connect to
|
|
the database. This field is not returned on request, and the value
|
|
is encrypted when stored in Datastream.
|
|
|
|
--mysql-prompt-for-password
|
|
Prompt for the password used to connect to the database.
|
|
|
|
--ca-certificate=CA_CERTIFICATE
|
|
x509 PEM-encoded certificate of the CA that signed the source
|
|
database server's certificate. The replica will use this certificate
|
|
to verify it's connecting to the right host.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--client-certificate=CLIENT_CERTIFICATE
|
|
x509 PEM-encoded certificate that will be used by the replica to
|
|
authenticate against the source database server.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--client-key=CLIENT_KEY
|
|
Unencrypted PKCS#1 or PKCS#8 PEM-encoded private key associated with
|
|
the Client Certificate.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--postgresql-database=POSTGRESQL_DATABASE
|
|
Database service for the PostgreSQL connection.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--postgresql-hostname=POSTGRESQL_HOSTNAME
|
|
IP or hostname of the PostgreSQL source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--postgresql-port=POSTGRESQL_PORT
|
|
Network port of the PostgreSQL source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--postgresql-username=POSTGRESQL_USERNAME
|
|
Username Datastream will use to connect to the database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--postgresql-password=POSTGRESQL_PASSWORD
|
|
Password for the user that Datastream will be using to connect to
|
|
the database. This field is not returned on request, and the value
|
|
is encrypted when stored in Datastream.
|
|
|
|
--postgresql-prompt-for-password
|
|
Prompt for the password used to connect to the database.
|
|
|
|
--postgresql-ca-certificate=POSTGRESQL_CA_CERTIFICATE
|
|
x509 PEM-encoded certificate of the CA that signed the source
|
|
database server's certificate. The replica will use this certificate
|
|
to verify it's connecting to the right host.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--postgresql-client-certificate=POSTGRESQL_CLIENT_CERTIFICATE
|
|
x509 PEM-encoded certificate that will be used by the replica to
|
|
authenticate against the source database server.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--postgresql-client-key=POSTGRESQL_CLIENT_KEY
|
|
Unencrypted PKCS#1 or PKCS#8 PEM-encoded private key associated with
|
|
the Client Certificate.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--salesforce-domain=SALESFORCE_DOMAIN
|
|
Domain of the Salesforce organization. For example,
|
|
'myorg.my.salesforce.com'
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--salesforce-oauth2-client-id=SALESFORCE_OAUTH2_CLIENT_ID
|
|
OAuth 2.0 Client ID used to connect to Salesforce.
|
|
|
|
This flag argument must be specified if any of the other arguments
|
|
in this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--salesforce-oauth2-client-secret=SALESFORCE_OAUTH2_CLIENT_SECRET
|
|
OAuth 2.0 Client secret used to connect to Salesforce.
|
|
|
|
--salesforce-prompt-for-oauth2-client-secret
|
|
Prompt for the OAuth 2.0 Client secret used to connect to
|
|
Salesforce.
|
|
|
|
--salesforce-secret-manager-stored-oauth2-client-secret=SALESFORCE_SECRET_MANAGER_STORED_OAUTH2_CLIENT_SECRET
|
|
Path to secret manager, storing the OAuth 2.0 Client secret used
|
|
to connect to Salesforce.
|
|
|
|
--salesforce-username=SALESFORCE_USERNAME
|
|
Username Datastream will use to connect to the database.
|
|
|
|
This flag argument must be specified if any of the other arguments
|
|
in this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--salesforce-password=SALESFORCE_PASSWORD
|
|
Password for the user that Datastream will be using to connect to
|
|
Salesforce. This field is not returned on request, and the value
|
|
is encrypted when stored in Datastream.
|
|
|
|
--salesforce-prompt-for-password
|
|
Prompt for the password used to connect to Salesforce.
|
|
|
|
--salesforce-secret-manager-stored-password=SALESFORCE_SECRET_MANAGER_STORED_PASSWORD
|
|
Path to secret manager, storing the password used to connect to
|
|
Salesforce.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--salesforce-prompt-for-security-token
|
|
Prompt for the security token used to connect to Salesforce.
|
|
|
|
--salesforce-secret-manager-stored-security-token=SALESFORCE_SECRET_MANAGER_STORED_SECURITY_TOKEN
|
|
Path to secret manager, storing the security token used to
|
|
connect to Salesforce.
|
|
|
|
--salesforce-security-token=SALESFORCE_SECURITY_TOKEN
|
|
Security token for the user that Datastream will be using to
|
|
connect to Salesforce.
|
|
|
|
--sqlserver-database=SQLSERVER_DATABASE
|
|
Database service for the SQL Server connection.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--sqlserver-hostname=SQLSERVER_HOSTNAME
|
|
IP or hostname of the SQL Server source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--sqlserver-port=SQLSERVER_PORT
|
|
Network port of the SQL Server source database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--sqlserver-username=SQLSERVER_USERNAME
|
|
Username Datastream will use to connect to the database.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--sqlserver-password=SQLSERVER_PASSWORD
|
|
Password for the user that Datastream will be using to connect to
|
|
the database. This field is not returned on request, and the value
|
|
is encrypted when stored in Datastream.
|
|
|
|
--sqlserver-prompt-for-password
|
|
Prompt for the password used to connect to the database.
|
|
|
|
At most one of these can be specified:
|
|
|
|
Private connection resource - Resource ID of the private connection.
|
|
This represents a Cloud 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 --private-connection on the command line with
|
|
a fully specified name;
|
|
▸ provide the argument --project on the command line;
|
|
▸ set the property core/project.
|
|
|
|
To set the location attribute:
|
|
▸ provide the argument --private-connection on the command line with
|
|
a fully specified name;
|
|
▸ provide the argument --location on the command line.
|
|
|
|
--private-connection=PRIVATE_CONNECTION
|
|
ID of the private_connection or fully qualified identifier for the
|
|
private_connection.
|
|
|
|
To set the private_connection attribute:
|
|
▫ provide the argument --private-connection on the command line.
|
|
|
|
--static-ip-connectivity
|
|
use static ip connectivity
|
|
|
|
--forward-ssh-hostname=FORWARD_SSH_HOSTNAME
|
|
Hostname for the SSH tunnel.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--forward-ssh-username=FORWARD_SSH_USERNAME
|
|
Username for the SSH tunnel.
|
|
|
|
This flag argument must be specified if any of the other arguments in
|
|
this group are specified.
|
|
|
|
--forward-ssh-port=FORWARD_SSH_PORT; default=22
|
|
Port for the SSH tunnel, default value is 22.
|
|
|
|
Exactly one of these must be specified:
|
|
|
|
--forward-ssh-password=FORWARD_SSH_PASSWORD
|
|
SSH password.
|
|
|
|
--forward-ssh-private-key=FORWARD_SSH_PRIVATE_KEY
|
|
SSH private key..
|
|
|
|
GCLOUD WIDE FLAGS
|
|
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.
|
|
|
|
NOTES
|
|
This variant is also available:
|
|
|
|
$ gcloud beta datastream connection-profiles create
|
|
|