mirror of
https://github.com/imjasonh/gcloud-help
synced 2026-07-15 09:25:44 +00:00
100 lines
3.5 KiB
Text
100 lines
3.5 KiB
Text
NAME
|
|
gcloud compute resource-policies create workload-policy - create a Compute
|
|
Engine workload resource policy
|
|
|
|
SYNOPSIS
|
|
gcloud compute resource-policies create workload-policy NAME --type=TYPE
|
|
[--description=DESCRIPTION] [--region=REGION]
|
|
[--accelerator-topology=ACCELERATOR_TOPOLOGY
|
|
| --max-topology-distance=MAX_TOPOLOGY_DISTANCE]
|
|
[GCLOUD_WIDE_FLAG ...]
|
|
|
|
DESCRIPTION
|
|
Create a Compute Engine workload resource policy.
|
|
|
|
EXAMPLES
|
|
To create a workload policy:
|
|
|
|
$ gcloud compute resource-policies create workload-policy NAME \
|
|
--type=TYPE
|
|
|
|
POSITIONAL ARGUMENTS
|
|
NAME
|
|
Name of the resource policy to operate on.
|
|
|
|
REQUIRED FLAGS
|
|
--type=TYPE
|
|
Type of the workload policy defining the high-level intent of the
|
|
cluster. TYPE must be one of:
|
|
|
|
HIGH_AVAILABILITY
|
|
For workloads that aim to be highly available. Common examples are
|
|
web / ML serving, or distributed database clusters. Compute Engine
|
|
spreads VMs at best-effort to improve reliability of the
|
|
distributed infrastructure.
|
|
HIGH_THROUGHPUT
|
|
For high throughput distributed workloads eg. HPC or ML training.
|
|
Compute Engine collocates VMs at best-effort to reduce network
|
|
latency between VMs.
|
|
|
|
OPTIONAL FLAGS
|
|
--description=DESCRIPTION
|
|
An optional, textual description for the backend.
|
|
|
|
--region=REGION
|
|
Region of the resource policy to operate on. If not specified, you
|
|
might be prompted to select a region (interactive mode only).
|
|
|
|
To avoid prompting when this flag is omitted, you can set the
|
|
compute/region property:
|
|
|
|
$ gcloud config set compute/region REGION
|
|
|
|
A list of regions can be fetched by running:
|
|
|
|
$ gcloud compute regions list
|
|
|
|
To unset the property, run:
|
|
|
|
$ gcloud config unset compute/region
|
|
|
|
Alternatively, the region can be stored in the environment variable
|
|
CLOUDSDK_COMPUTE_REGION.
|
|
|
|
At most one of these can be specified:
|
|
|
|
--accelerator-topology=ACCELERATOR_TOPOLOGY
|
|
Specifies the topology of placement and interconnection performance
|
|
required to create a slice of VMs with interconnected accelerators.
|
|
|
|
--max-topology-distance=MAX_TOPOLOGY_DISTANCE
|
|
Specifies the topology of placement and interconnection network
|
|
performance of the group of VMs (MIG / Multi-MIGs).
|
|
MAX_TOPOLOGY_DISTANCE must be one of:
|
|
|
|
BLOCK
|
|
VMs are placed within the same block of capacity with improved
|
|
latency compared to Cluster.
|
|
CLUSTER
|
|
VMs are placed within the same cluster of capacity with improved
|
|
latency between them.
|
|
SUBBLOCK
|
|
Tightest collocation of VMs that provides minimized network
|
|
latency. VMs are placed within the same rack of capacity with
|
|
improved latency compared to Block.
|
|
|
|
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 compute resource-policies create workload-policy
|
|
|
|
$ gcloud beta compute resource-policies create workload-policy
|
|
|