update
******


Description
===========

Updates the specified public IP. You must specify the object's OCID.
Use this operation if you want to:

* Assign a reserved public IP in your pool to a private IP. * Move a
  reserved public IP to a different private IP. * Unassign a reserved
  public IP from a private IP (which returns it to your pool of
  reserved public IPs). * Change the display name for a public IP
  (either ephemeral or reserved).

Assigning, moving, and unassigning a reserved public IP are
asynchronous operations. Poll the public IP's *lifecycleState* to
determine if the operation succeeded.

**Note:** When moving a reserved public IP, the target private IP must
not already have a public IP with *lifecycleState* = ASSIGNING or
ASSIGNED. If it does, an error is returned. Also, the initial
unassignment from the original private IP always succeeds, but the
assignment to the target private IP is asynchronous and could fail
silently (for example, if the target private IP is deleted or has a
different public IP assigned to it in the interim). If that occurs,
the public IP remains unassigned and its *lifecycleState* switches to
AVAILABLE (it is not reassigned to its original private IP). You must
poll the public IP's *lifecycleState* to determine if the move
succeeded.

Regarding ephemeral public IPs:

* If you want to assign an ephemeral public IP to a primary private
  IP, use CreatePublicIp. * You can't move an ephemeral public IP to a
  different private IP. * If you want to unassign an ephemeral public
  IP from its private IP, use DeletePublicIp, which unassigns and
  deletes the ephemeral public IP.

**Note:** If a public IP (either ephemeral or reserved) is assigned to
a secondary private IP (see PrivateIp), and you move that secondary
private IP to another VNIC, the public IP moves with it.

**Note:** There's a limit to the number of public IPs a VNIC or
instance can have. If you try to move a reserved public IP to a VNIC
or instance that has already reached its public IP limit, an error is
returned. For information about the public IP limits, see Public IP
Addresses.


Usage
=====

   oci network public-ip update [OPTIONS]


Options
=======


--public-ip-id [text]
---------------------

The OCID of the public IP. [required]


--display-name [text]
---------------------

A user-friendly name. Does not have to be unique, and it's changeable.
Avoid entering confidential information.


--private-ip-id [text]
----------------------

The OCID of the private IP to assign the public IP to. * If the public
IP is already assigned to a different private IP, it will be
unassigned and then reassigned to the specified private IP. * If you
set this field to an empty string, the public IP will be unassigned
from the private IP it is currently assigned to.


--if-match [text]
-----------------

For optimistic concurrency control. In the PUT or DELETE call for a
resource, set the *if-match* parameter to the value of the etag from a
previous GET or POST response for that resource.  The resource will be
updated or deleted only if the etag you provide matches the resource's
current etag value.


--wait-for-state [PROVISIONING|AVAILABLE|ASSIGNING|ASSIGNED|UNASSIGNING|UNASSIGNED|TERMINATING|TERMINATED]
----------------------------------------------------------------------------------------------------------

This operation creates, modifies or deletes a resource that has a
defined lifecycle state. Specify this option to perform the action and
then wait until the resource reaches a given lifecycle state.


--max-wait-seconds [integer]
----------------------------

The maximum time to wait for the resource to reach the lifecycle state
defined by --wait-for-state. Defaults to 1200 seconds.


--wait-interval-seconds [integer]
---------------------------------

Check every --wait-interval-seconds to see whether the resource to see
if it has reached the lifecycle state defined by --wait-for-state.
Defaults to 30 seconds.


--from-json [text]
------------------

Provide input to this command as a JSON document from a file.

Options can still be provided on the command line. If an option exists
in both the JSON document and the command line then the command line
specified value will be used


-?, -h, --help
--------------

Show this message and exit.
