gcloud composer environments update

NAME
gcloud composer environments update - update properties of a Cloud Composer environment
SYNOPSIS
gcloud composer environments update (ENVIRONMENT : --location=LOCATION) (--cloud-sql-machine-type=CLOUD_SQL_MACHINE_TYPE     | --disable-high-resilience     | --disable-logs-in-cloud-logging-only     | --disable-private-environment     | --enable-high-resilience     | --enable-logs-in-cloud-logging-only     | --enable-private-environment     | --environment-size=ENVIRONMENT_SIZE     | --image-version=IMAGE_VERSION     | --node-count=NODE_COUNT     | --support-web-server-plugins     | --web-server-machine-type=WEB_SERVER_MACHINE_TYPE     | --clear-maintenance-window     | --maintenance-window-end=MAINTENANCE_WINDOW_END --maintenance-window-recurrence=MAINTENANCE_WINDOW_RECURRENCE --maintenance-window-start=MAINTENANCE_WINDOW_START     | --disable-cloud-data-lineage-integration     | --enable-cloud-data-lineage-integration     | --disable-master-authorized-networks --enable-master-authorized-networks --master-authorized-networks=[NETWORK,…]     | --disable-private-builds-only     | --enable-private-builds-only     | --disable-scheduled-snapshot-creation     | --enable-scheduled-snapshot-creation --snapshot-creation-schedule=SNAPSHOT_CREATION_SCHEDULE --snapshot-location=SNAPSHOT_LOCATION --snapshot-schedule-timezone=SNAPSHOT_SCHEDULE_TIMEZONE     | --disable-vpc-connectivity     | --network-attachment=NETWORK_ATTACHMENT     | [--network=NETWORK : --subnetwork=SUBNETWORK]     | --max-workers=MAX_WORKERS --min-workers=MIN_WORKERS --scheduler-count=SCHEDULER_COUNT --scheduler-cpu=SCHEDULER_CPU --scheduler-memory=SCHEDULER_MEMORY --scheduler-storage=SCHEDULER_STORAGE --web-server-cpu=WEB_SERVER_CPU --web-server-memory=WEB_SERVER_MEMORY --web-server-storage=WEB_SERVER_STORAGE --worker-cpu=WORKER_CPU --worker-memory=WORKER_MEMORY --worker-storage=WORKER_STORAGE --dag-processor-count=DAG_PROCESSOR_COUNT --dag-processor-cpu=DAG_PROCESSOR_CPU --dag-processor-memory=DAG_PROCESSOR_MEMORY --dag-processor-storage=DAG_PROCESSOR_STORAGE --disable-triggerer     | --enable-triggerer --triggerer-count=TRIGGERER_COUNT --triggerer-cpu=TRIGGERER_CPU --triggerer-memory=TRIGGERER_MEMORY     | --update-airflow-configs=[KEY=VALUE,…] --clear-airflow-configs     | --remove-airflow-configs=[KEY,…]     | --update-env-variables=[NAME=VALUE,…] --clear-env-variables     | --remove-env-variables=[NAME,…]     | --update-labels=[KEY=VALUE,…] --clear-labels     | --remove-labels=[KEY,…]     | --update-pypi-packages-from-file=UPDATE_PYPI_PACKAGES_FROM_FILE     | --update-pypi-package=PACKAGE[EXTRAS_LIST]VERSION_SPECIFIER --clear-pypi-packages     | --remove-pypi-packages=[PACKAGE,…]     | --update-web-server-allow-ip=[description=DESCRIPTION],[ip_range=IP_RANGE]     | --web-server-allow-all     | --web-server-deny-all) [--async] [GCLOUD_WIDE_FLAG]
DESCRIPTION
Update properties of a Cloud Composer environment.
EXAMPLES
To update the Cloud Composer environment named env-1 to have 8 Airflow workers, and not have the production label, run:
gcloud composer environments update env-1 --node-count=8 --remove-labels=production
POSITIONAL ARGUMENTS
Environment resource - The environment to update. 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 environment 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.

ENVIRONMENT
ID of the environment or fully qualified identifier for the environment.

To set the environment attribute:

  • provide the argument environment on the command line.

This positional argument must be specified if any of the other arguments in this group are specified.

--location=LOCATION
Region where Composer environment runs or in which to create the environment.

To set the location attribute:

  • provide the argument environment on the command line with a fully specified name;
  • provide the argument --location on the command line;
  • set the property composer/location.
REQUIRED FLAGS
The update type.

Exactly one of these must be specified:

--cloud-sql-machine-type=CLOUD_SQL_MACHINE_TYPE
Cloud SQL machine type used by the Airflow database. The list of available machine types is available here: https://cloud.google.com/composer/pricing#db-machine-types.
--disable-high-resilience
Disable high resilience, supported for Composer 2 Environments.
--disable-logs-in-cloud-logging-only
Disable logs in cloud logging only, supported for Composer 2 Environments.
--disable-private-environment
Enable internet connection from any Composer component, supported in Composer 3 environments or greater.
--enable-high-resilience
Enable high resilience, supported for Composer 2 Environments.
--enable-logs-in-cloud-logging-only
Enable logs in cloud logging only, supported for Composer 2 Environments.
--enable-private-environment
Disable internet connection from any Composer component, supported in Composer 3 environments or greater.
--environment-size=ENVIRONMENT_SIZE
Size of the environment. Unspecified means that the default option will be chosen. ENVIRONMENT_SIZE must be one of: large, medium, small, unspecified.
Group of arguments for performing in-place environment upgrades.
--image-version=IMAGE_VERSION
Upgrade the environment to a later version in-place.

The image version encapsulates the versions of both Cloud Composer and Apache Airflow. Must be of the form composer-A[.B.C[-D.E]]-airflow-X[.Y[.Z]], where [] denotes optional fragments.

Examples: composer-2-airflow-2, composer-2-airflow-2.2, composer-2.1.2-airflow-2.3.4.

The Cloud Composer portion of the image version is a semantic version or an alias in the form of major version number or latest, resolved to the current Cloud Composer version. The Apache Airflow portion of the image version is a semantic version or an alias in the form of major or major.minor version numbers, resolved to the latest matching Apache Airflow version supported in the given Cloud Composer version. The resolved versions are stored in the upgraded environment.

--node-count=NODE_COUNT
The new number of nodes running the environment. Must be >= 3.
--support-web-server-plugins
Enable the support for web server plugins, supported in Composer 3 or greater.
--web-server-machine-type=WEB_SERVER_MACHINE_TYPE
machine type used by the Airflow web server. The list of available machine types is available here: https://cloud.google.com/composer/pricing.
Group of arguments for setting the maintenance window value during update.

At most one of these can be specified:

--clear-maintenance-window
Clears the maintenance window settings. Can be specified for Composer 3 or greater.
Group of arguments for setting the maintenance window value.
--maintenance-window-end=MAINTENANCE_WINDOW_END
End time of the mantenance window in the form of the full date. Only the time of the day is used as a reference for an ending time of the window with a provided recurrence. Specified date must take place after the one specified as a start date, the difference between will be used as a length of a single maintenance window. See $ gcloud topic datetimes for information on time formats.

This flag argument must be specified if any of the other arguments in this group are specified.

--maintenance-window-recurrence=MAINTENANCE_WINDOW_RECURRENCE
An RFC 5545 RRULE, specifying how the maintenance window will recur. The minimum requirement for the length of the maintenance window is 12 hours a week. Only FREQ=DAILY and FREQ=WEEKLY rules are supported.

This flag argument must be specified if any of the other arguments in this group are specified.

--maintenance-window-start=MAINTENANCE_WINDOW_START
Start time of the mantenance window in the form of the full date. Only the time of the day is used as a reference for a starting time of the window with a provided recurrence. See $ gcloud topic datetimes for information on time formats.

This flag argument must be specified if any of the other arguments in this group are specified.

Group of arguments for setting Cloud Data Lineage integration configuration in Composer 2.
At most one of these can be specified:
--disable-cloud-data-lineage-integration
Disable Cloud Data Lineage integration, supported for Composer 2 Environments.
--enable-cloud-data-lineage-integration
Enable Cloud Data Lineage integration, supported for Composer 2 Environments.
Group of arguments for setting master authorized networks configuration.
--disable-master-authorized-networks
Disable Master Authorized Networks feature (https://cloud.google.com/kubernetes-engine/docs/how-to/authorized-networks/) in the Composer Environment's GKE cluster.
--enable-master-authorized-networks
Enable Master Authorized Networks feature (https://cloud.google.com/kubernetes-engine/docs/how-to/authorized-networks/) in the Composer Environment's GKE cluster.
--master-authorized-networks=[NETWORK,…]
Comma separated Master Authorized Networks specified in CIDR notation.

Cannot be specified unless --enable-master-authorized-networks is also specified.

At most one of these can be specified:
--disable-private-builds-only
Builds performed during operations that install Python packages have an access to the internet, supported in Composer 3 or greater.
--enable-private-builds-only
Builds performed during operations that install Python packages have only private connectivity to Google services, supported in Composer 3 or greater.
Group of arguments used during update of scheduled snapshots settings in Composer 2.0.32 or greater.

At most one of these can be specified:

--disable-scheduled-snapshot-creation
Disables automated snapshots creation. Can be specified for Composer 2.0.32 or greater.
Group of arguments for setting scheduled snapshots settings in Composer 2.0.32 or greater.
--enable-scheduled-snapshot-creation
When specified, snapshots of the environment will be created according to a schedule. Can be specified for Composer 2.0.32 or greater.

This flag argument must be specified if any of the other arguments in this group are specified.

--snapshot-creation-schedule=SNAPSHOT_CREATION_SCHEDULE
Cron expression specifying when snapshots of the environment should be created. Can be specified for Composer 2.0.32 or greater.

This flag argument must be specified if any of the other arguments in this group are specified.

--snapshot-location=SNAPSHOT_LOCATION
The Cloud Storage location for storing automatically created snapshots. Can be specified for Composer 2.0.32 or greater.

This flag argument must be specified if any of the other arguments in this group are specified.

--snapshot-schedule-timezone=SNAPSHOT_SCHEDULE_TIMEZONE
Timezone that sets the context to interpret snapshot_creation_schedule. Can be specified for Composer 2.0.32 or greater.

This flag argument must be specified if any of the other arguments in this group are specified.

At most one of these can be specified:
--disable-vpc-connectivity
Disable connectivity with a user's VPC network, supported in Composer 3 environments or greater.
--network-attachment=NETWORK_ATTACHMENT
Cloud Composer Network Attachment, which provides connectivity with a user's VPC network, supported in Composer 3 environments or greater.
Virtual Private Cloud networking
--network=NETWORK
The Compute Engine Network to which the environment will be connected. If a 'Custom Subnet Network' is provided, --subnetwork must be specified as well.

This flag argument must be specified if any of the other arguments in this group are specified.

--subnetwork=SUBNETWORK
The Compute Engine Subnetwork (https://cloud.google.com/compute/docs/subnetworks) to which the environment will be connected.
Group of arguments for setting workloads configuration in Composer 2.X or greater (--scheduler-count flag is available for Composer 1.X as well).
--max-workers=MAX_WORKERS
Maximum number of workers in the Environment.
--min-workers=MIN_WORKERS
Minimum number of workers in the Environment.
--scheduler-count=SCHEDULER_COUNT
Number of schedulers, supported in the Environments with Airflow 2.0.1 and later.
--scheduler-cpu=SCHEDULER_CPU
CPU allocated to Airflow scheduler.
--scheduler-memory=SCHEDULER_MEMORY
Memory allocated to Airflow scheduler, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB.
--scheduler-storage=SCHEDULER_STORAGE
Storage allocated to Airflow scheduler, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB.
--web-server-cpu=WEB_SERVER_CPU
CPU allocated to each Airflow web server
--web-server-memory=WEB_SERVER_MEMORY
Memory allocated to Airflow web server, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB.
--web-server-storage=WEB_SERVER_STORAGE
Storage allocated to Airflow web server, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB.
--worker-cpu=WORKER_CPU
CPU allocated to each Airflow worker
--worker-memory=WORKER_MEMORY
Memory allocated to Airflow worker, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB.
--worker-storage=WORKER_STORAGE
Storage allocated to Airflow worker, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB.
Group of arguments for setting dag processor settings in Composer 3 or greater.
--dag-processor-count=DAG_PROCESSOR_COUNT
Number of dag processors, supported in Composer 3 environments or greater.
--dag-processor-cpu=DAG_PROCESSOR_CPU
CPU allocated to Airflow dag processor, supported in Composer 3 environments or greater.
--dag-processor-memory=DAG_PROCESSOR_MEMORY
Memory allocated to Airflow dag processor, ex. 1GB, 3GB, 2. If units are not provided, defaults to GB, supported in Composer 3 environments or greater.
--dag-processor-storage=DAG_PROCESSOR_STORAGE
Storage allocated to Airflow dag processor, ex. 600MB, 3GB, 2. If units are not provided, defaults to GB, supported in Composer 3 environments or greater.
Group of arguments for setting triggerer settings in Composer 2.0.31 or greater.

At most one of these can be specified:

--disable-triggerer
(DEPRECATED) Disable a triggerer, supported in the Environments with Composer 2.0.31 and Airflow 2.2.5 and greater.

This flag is deprecated. Use --triggerer-count 0 instead.

Group of arguments for setting triggerer settings during update in Composer 2.0.31 or greater.
--enable-triggerer
(DEPRECATED) Enable use of a triggerer, supported in the Environments with Composer 2.0.31 and Airflow 2.2.5 and greater.

This flag is deprecated. Use --triggerer-count instead.

--triggerer-count=TRIGGERER_COUNT
Number of triggerers, supported in the Environments with Composer 2.0.31 and Airflow 2.2.5 and greater.
--triggerer-cpu=TRIGGERER_CPU
CPU allocated to Airflow triggerer. Supported in the Environments with Composer 2.0.31 and Airflow 2.2.5 and greater.
--triggerer-memory=TRIGGERER_MEMORY
Memory allocated to Airflow triggerer, ex. 512MB, 3GB, 2. If units are not provided, defaults to GB. Supported in the Environments with Composer 2.0.31 and Airflow 2.2.5 and greater.
Group of arguments for modifying the Airflow configuration.
--update-airflow-configs=[KEY=VALUE,…]
A list of Airflow config override KEY=VALUE pairs to set. If a config override exists, its value is updated; otherwise, a new config override is created.

KEYs should specify the configuration section and property name, separated by a hyphen, for example core-print_stats_interval. The section may not contain a closing square brace or period. The property name must be non-empty and may not contain an equals sign, semicolon, or period. By convention, property names are spelled with snake_case. VALUEs may contain any character.

Arguments available for item removal.

At most one of these can be specified:

--clear-airflow-configs
Removes all Airflow config overrides from the environment.
--remove-airflow-configs=[KEY,…]
A list of Airflow config override keys to remove.
Group of arguments for modifying environment variables.
--update-env-variables=[NAME=VALUE,…]
A list of environment variable NAME=VALUE pairs to set and provide to the Airflow scheduler, worker, and webserver processes. If an environment variable exists, its value is updated; otherwise, a new environment variable is created.

NAMEs are the environment variable names and may contain upper and lowercase letters, digits, and underscores; they must not begin with a digit.

User-specified environment variables should not be used to set Airflow configuration properties. Instead use the --update-airflow-configs flag.

Arguments available for item removal.

At most one of these can be specified:

--clear-env-variables
Removes all environment variables from the environment.

Environment variables that have system-provided defaults cannot be unset with the --remove-env-variables or --clear-env-variables flags; only the user-supplied overrides will be removed.

--remove-env-variables=[NAME,…]
A list of environment variables to remove.

Environment variables that have system-provided defaults cannot be unset with the --remove-env-variables or --clear-env-variables flags; only the user-supplied overrides will be removed.

Group of arguments for modifying environment labels.
--update-labels=[KEY=VALUE,…]
List of label KEY=VALUE pairs to update. If a label exists, its value is modified. Otherwise, a new label is created.

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:
--clear-labels
Remove all labels. If --update-labels is also specified then --clear-labels is applied first.

For example, to remove all labels:

gcloud composer environments update --clear-labels

To remove all existing labels and create two new labels, foo and baz:

gcloud composer environments update --clear-labels --update-labels foo=bar,baz=qux
--remove-labels=[KEY,…]
List of label keys to remove. If a label does not exist it is silently ignored. If --update-labels is also specified then --update-labels is applied first.
Group of arguments for modifying the PyPI package configuration.

At most one of these can be specified:

--update-pypi-packages-from-file=UPDATE_PYPI_PACKAGES_FROM_FILE
The path to a file containing a list of PyPI packages to install in the environment. Each line in the file should contain a package specification in the format of the update-pypi-package argument defined above. The path can be a local file path or a Google Cloud Storage file path (Cloud Storage file path starts with 'gs://').
--update-pypi-package=PACKAGE[EXTRAS_LIST]VERSION_SPECIFIER
A PyPI package to add to the environment. If a package exists, its value is updated; otherwise, a new package is installed.

The value takes the form of: PACKAGE[EXTRAS_LIST]VERSION_SPECIFIER, as one would specify in a pip requirements file.

PACKAGE is specified as a package name, such as numpy. EXTRAS_LIST is a comma-delimited list of PEP 508 distribution extras that may be empty, in which case the enclosing square brackets may be omitted. VERSION_SPECIFIER is an optional PEP 440 version specifier. If both EXTRAS_LIST and VERSION_SPECIFIER are omitted, the = and everything to the right may be left empty.

This is a repeated argument that can be specified multiple times to update multiple packages. If PACKAGE appears more than once, the last value will be used.

Arguments available for item removal.

At most one of these can be specified:

--clear-pypi-packages
Removes all PyPI packages from the environment.

PyPI packages that are required by the environment's core software cannot be uninstalled with the --remove-pypi-packages or --clear-pypi-packages flags.

--remove-pypi-packages=[PACKAGE,…]
A list of PyPI package names to remove.

PyPI packages that are required by the environment's core software cannot be uninstalled with the --remove-pypi-packages or --clear-pypi-packages flags.

At most one of these can be specified:
--update-web-server-allow-ip=[description=DESCRIPTION],[ip_range=IP_RANGE]
Specifies a list of IPv4 or IPv6 ranges that will be allowed to access the Airflow web server. By default, all IPs are allowed to access the web server.
ip_range
IPv4 or IPv6 range of addresses allowed to access the Airflow web server.
description
An optional description of the IP range.
--web-server-allow-all
Allows all IP addresses to access the Airflow web server.
--web-server-deny-all
Denies all incoming traffic to the Airflow web server.
OPTIONAL FLAGS
--async
Return immediately, without waiting for the operation in progress to complete.
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
These variants are also available:
gcloud alpha composer environments update
gcloud beta composer environments update