| Server IP : 35.236.43.222 / Your IP : 216.73.216.143 Web Server : Apache System : Linux order-form-vm-001 5.10.0-37-cloud-amd64 #1 SMP Debian 5.10.247-1 (2025-12-11) x86_64 User : deploy ( 1002) PHP Version : 8.1.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /usr/lib/google-cloud-sdk/lib/surface/firestore/databases/__pycache__/ |
Upload File : |
�
��z
� � � d Z ddlmZ ddlmZ ddlmZ ddlZddlmZ ddlm Z ddl
mZ dd l
mZ
dd
lmZ e j e j e j j e j j e j j � � G d� de j � � � � � � ZdS )
z/The gcloud Firestore databases restore command.� )�absolute_import)�division)�unicode_literalsN)� databases)�base)�flags)�util)�
propertiesc �4 � e Zd ZdZed� � � Zd� Zd� ZdS )�RestoreBetaaS Restores a Cloud Firestore database from a backup.
## EXAMPLES
To restore a database from a backup.
$ {command}
--source-backup=projects/PROJECT_ID/locations/LOCATION_ID/backups/BACKUP_ID
--destination-database=DATABASE_ID
To restore to a CMEK-enabled database.
$ {command}
--source-backup=projects/PROJECT_ID/locations/LOCATION_ID/backups/BACKUP_ID
--destination-database=DATABASE_ID
--encryption-type=customer-managed-encryption
--kms-key-name=projects/PROJECT_ID/locations/LOCATION_ID/keyRings/KEY_RING_ID/cryptoKeys/CRYPTO_KEY_ID
c �� � |� ddt dt j d� � �� � |� ddt dt j d� � �� � t j |d � � d S )
Nz--source-backup�
SOURCE_BACKUPTa The source backup to restore from.
For example, to restore from backup `cf9f748a-7980-4703-b1a1-d1ffff591db0` in us-east1:
$ {command} --source-backup=projects/PROJECT_ID/locations/us-east1/backups/cf9f748a-7980-4703-b1a1-d1ffff591db0
)�metavar�type�required�helpz--destination-database�DESTINATION_DATABASEa, Destination database to restore to. Destination database will be created in the same location as the source backup.
This value should be 4-63 characters. Valid characters are /[a-z][0-9]-/
with first character a letter and the last a letter or a number. Must
not be UUID-like /[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}/.
Using "(default)" database ID is also allowed.
For example, to restore to database `testdb`:
$ {command} --destination-database=testdb
�backup)�add_argument�str�textwrap�dedentr �AddEncryptionConfigGroup)�cls�parsers �*lib/surface/firestore/databases/restore.py�ArgszRestoreBeta.Args6 s� � �
�����
��
�_� � � � � � � � ��� �&�
��
�_� � � � � � � �&