GCLOUD_COMPUTE_ADDRESSES_CREATE(1)

NAME

gcloud compute addresses create - reserve IP addresses

SYNOPSIS

gcloud compute addresses create [NAME ...] [--addresses=ADDRESS,[ADDRESS,...]] [--description=DESCRIPTION] [--global | --region=REGION] [GCLOUD_WIDE_FLAG ...]

DESCRIPTION
gcloud compute addresses create is used to reserve one or more IP addresses. Once an IP address is reserved, it will be associated with the project until it is released using 'gcloud compute addresses delete'. Ephemeral IP addresses that are in use by resources in the project can be reserved using the --addresses flag.

POSITIONAL ARGUMENTS

    [NAME ...]
        The names of the addresses to create.

FLAGS

    --addresses=ADDRESS,[ADDRESS,...]
        Ephemeral IP addresses to promote to reserved status. Only addresses that are being used by resources in the project can be promoted. When providing this flag, a parallel list of names for the addresses can be provided. For example,
        $ gcloud compute addresses create ADDRESS-1 ADDRESS-2 \
          --addresses 162.222.181.197,162.222.181.198 \
          --region us-central1
    will result in 162.222.181.197 being reserved as 'ADDRESS-1' and 162.222.181.198 as 'ADDRESS-2'. If no names are given, server-generated names will be assigned to the IP addresses.

    --description=DESCRIPTION
        An optional textual description for the addresses.

At most one of these may be specified:

    --global
        If provided, it is assumed the addresses are global.

    --region=REGION
        The region of the addresses to create. Overrides the default compute/region property value for this command invocation.

GCLOUD WIDE FLAGS
These flags are available to all commands: --account, --configuration, --flatten, --format, --help, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity. Run $ gcloud help for details.

EXAMPLES
To reserve three IP addresses in the us-central1 region, run:
    $ gcloud compute addresses create ADDRESS-1 ADDRESS-2 ADDRESS-3 \
        --region us-central1
To reserve ephemeral IP addresses 162.222.181.198 and 23.251.146.189 which are being used by virtual machine instances in the us-central1 region, run:
    $ gcloud compute addresses create \
        --addresses 162.222.181.198,23.251.146.189 --region us-central1
In the above invocation, the two addresses will be assigned random names.