Google Cloud Native is in preview. Google Cloud Classic is fully supported.
google-native.file/v1.Backup
Explore with Pulumi AI
Google Cloud Native is in preview. Google Cloud Classic is fully supported.
Creates a backup. Auto-naming is currently not supported for this resource.
Create Backup Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Backup(name: string, args: BackupArgs, opts?: CustomResourceOptions);
@overload
def Backup(resource_name: str,
args: BackupArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Backup(resource_name: str,
opts: Optional[ResourceOptions] = None,
backup_id: Optional[str] = None,
description: Optional[str] = None,
kms_key: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
location: Optional[str] = None,
project: Optional[str] = None,
source_file_share: Optional[str] = None,
source_instance: Optional[str] = None)
func NewBackup(ctx *Context, name string, args BackupArgs, opts ...ResourceOption) (*Backup, error)
public Backup(string name, BackupArgs args, CustomResourceOptions? opts = null)
public Backup(String name, BackupArgs args)
public Backup(String name, BackupArgs args, CustomResourceOptions options)
type: google-native:file/v1:Backup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args BackupArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args BackupArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args BackupArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args BackupArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args BackupArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var examplebackupResourceResourceFromFilev1 = new GoogleNative.File.V1.Backup("examplebackupResourceResourceFromFilev1", new()
{
BackupId = "string",
Description = "string",
KmsKey = "string",
Labels =
{
{ "string", "string" },
},
Location = "string",
Project = "string",
SourceFileShare = "string",
SourceInstance = "string",
});
example, err := file.NewBackup(ctx, "examplebackupResourceResourceFromFilev1", &file.BackupArgs{
BackupId: pulumi.String("string"),
Description: pulumi.String("string"),
KmsKey: pulumi.String("string"),
Labels: pulumi.StringMap{
"string": pulumi.String("string"),
},
Location: pulumi.String("string"),
Project: pulumi.String("string"),
SourceFileShare: pulumi.String("string"),
SourceInstance: pulumi.String("string"),
})
var examplebackupResourceResourceFromFilev1 = new Backup("examplebackupResourceResourceFromFilev1", BackupArgs.builder()
.backupId("string")
.description("string")
.kmsKey("string")
.labels(Map.of("string", "string"))
.location("string")
.project("string")
.sourceFileShare("string")
.sourceInstance("string")
.build());
examplebackup_resource_resource_from_filev1 = google_native.file.v1.Backup("examplebackupResourceResourceFromFilev1",
backup_id="string",
description="string",
kms_key="string",
labels={
"string": "string",
},
location="string",
project="string",
source_file_share="string",
source_instance="string")
const examplebackupResourceResourceFromFilev1 = new google_native.file.v1.Backup("examplebackupResourceResourceFromFilev1", {
backupId: "string",
description: "string",
kmsKey: "string",
labels: {
string: "string",
},
location: "string",
project: "string",
sourceFileShare: "string",
sourceInstance: "string",
});
type: google-native:file/v1:Backup
properties:
backupId: string
description: string
kmsKey: string
labels:
string: string
location: string
project: string
sourceFileShare: string
sourceInstance: string
Backup Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Backup resource accepts the following input properties:
- Backup
Id string - Required. The ID to use for the backup. The ID must be unique within the specified project and location. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. Values that do not match this pattern will trigger an INVALID_ARGUMENT error.
- Description string
- A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected.
- Kms
Key string - Immutable. KMS key name used for data encryption.
- Labels Dictionary<string, string>
- Resource labels to represent user provided metadata.
- Location string
- Project string
- string
- Name of the file share in the source Filestore instance that the backup is created from.
- Source
Instance string - The resource name of the source Filestore instance, in the format
projects/{project_number}/locations/{location_id}/instances/{instance_id}
, used to create this backup.
- Backup
Id string - Required. The ID to use for the backup. The ID must be unique within the specified project and location. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. Values that do not match this pattern will trigger an INVALID_ARGUMENT error.
- Description string
- A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected.
- Kms
Key string - Immutable. KMS key name used for data encryption.
- Labels map[string]string
- Resource labels to represent user provided metadata.
- Location string
- Project string
- string
- Name of the file share in the source Filestore instance that the backup is created from.
- Source
Instance string - The resource name of the source Filestore instance, in the format
projects/{project_number}/locations/{location_id}/instances/{instance_id}
, used to create this backup.
- backup
Id String - Required. The ID to use for the backup. The ID must be unique within the specified project and location. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. Values that do not match this pattern will trigger an INVALID_ARGUMENT error.
- description String
- A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected.
- kms
Key String - Immutable. KMS key name used for data encryption.
- labels Map<String,String>
- Resource labels to represent user provided metadata.
- location String
- project String
- String
- Name of the file share in the source Filestore instance that the backup is created from.
- source
Instance String - The resource name of the source Filestore instance, in the format
projects/{project_number}/locations/{location_id}/instances/{instance_id}
, used to create this backup.
- backup
Id string - Required. The ID to use for the backup. The ID must be unique within the specified project and location. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. Values that do not match this pattern will trigger an INVALID_ARGUMENT error.
- description string
- A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected.
- kms
Key string - Immutable. KMS key name used for data encryption.
- labels {[key: string]: string}
- Resource labels to represent user provided metadata.
- location string
- project string
- string
- Name of the file share in the source Filestore instance that the backup is created from.
- source
Instance string - The resource name of the source Filestore instance, in the format
projects/{project_number}/locations/{location_id}/instances/{instance_id}
, used to create this backup.
- backup_
id str - Required. The ID to use for the backup. The ID must be unique within the specified project and location. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. Values that do not match this pattern will trigger an INVALID_ARGUMENT error.
- description str
- A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected.
- kms_
key str - Immutable. KMS key name used for data encryption.
- labels Mapping[str, str]
- Resource labels to represent user provided metadata.
- location str
- project str
- str
- Name of the file share in the source Filestore instance that the backup is created from.
- source_
instance str - The resource name of the source Filestore instance, in the format
projects/{project_number}/locations/{location_id}/instances/{instance_id}
, used to create this backup.
- backup
Id String - Required. The ID to use for the backup. The ID must be unique within the specified project and location. This value must start with a lowercase letter followed by up to 62 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. Values that do not match this pattern will trigger an INVALID_ARGUMENT error.
- description String
- A description of the backup with 2048 characters or less. Requests with longer descriptions will be rejected.
- kms
Key String - Immutable. KMS key name used for data encryption.
- labels Map<String>
- Resource labels to represent user provided metadata.
- location String
- project String
- String
- Name of the file share in the source Filestore instance that the backup is created from.
- source
Instance String - The resource name of the source Filestore instance, in the format
projects/{project_number}/locations/{location_id}/instances/{instance_id}
, used to create this backup.
Outputs
All input properties are implicitly available as output properties. Additionally, the Backup resource produces the following output properties:
- Capacity
Gb string - Capacity of the source file share when the backup was created.
- Create
Time string - The time when the backup was created.
- Download
Bytes string - Amount of bytes that will be downloaded if the backup is restored. This may be different than storage bytes, since sequential backups of the same disk will share storage.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The resource name of the backup, in the format
projects/{project_number}/locations/{location_id}/backups/{backup_id}
. - Satisfies
Pzs bool - Reserved for future use.
- Source
Instance stringTier - The service tier of the source Filestore instance that this backup is created from.
- State string
- The backup state.
- Storage
Bytes string - The size of the storage used by the backup. As backups share storage, this number is expected to change with backup creation/deletion.
- Capacity
Gb string - Capacity of the source file share when the backup was created.
- Create
Time string - The time when the backup was created.
- Download
Bytes string - Amount of bytes that will be downloaded if the backup is restored. This may be different than storage bytes, since sequential backups of the same disk will share storage.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The resource name of the backup, in the format
projects/{project_number}/locations/{location_id}/backups/{backup_id}
. - Satisfies
Pzs bool - Reserved for future use.
- Source
Instance stringTier - The service tier of the source Filestore instance that this backup is created from.
- State string
- The backup state.
- Storage
Bytes string - The size of the storage used by the backup. As backups share storage, this number is expected to change with backup creation/deletion.
- capacity
Gb String - Capacity of the source file share when the backup was created.
- create
Time String - The time when the backup was created.
- download
Bytes String - Amount of bytes that will be downloaded if the backup is restored. This may be different than storage bytes, since sequential backups of the same disk will share storage.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The resource name of the backup, in the format
projects/{project_number}/locations/{location_id}/backups/{backup_id}
. - satisfies
Pzs Boolean - Reserved for future use.
- source
Instance StringTier - The service tier of the source Filestore instance that this backup is created from.
- state String
- The backup state.
- storage
Bytes String - The size of the storage used by the backup. As backups share storage, this number is expected to change with backup creation/deletion.
- capacity
Gb string - Capacity of the source file share when the backup was created.
- create
Time string - The time when the backup was created.
- download
Bytes string - Amount of bytes that will be downloaded if the backup is restored. This may be different than storage bytes, since sequential backups of the same disk will share storage.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- The resource name of the backup, in the format
projects/{project_number}/locations/{location_id}/backups/{backup_id}
. - satisfies
Pzs boolean - Reserved for future use.
- source
Instance stringTier - The service tier of the source Filestore instance that this backup is created from.
- state string
- The backup state.
- storage
Bytes string - The size of the storage used by the backup. As backups share storage, this number is expected to change with backup creation/deletion.
- capacity_
gb str - Capacity of the source file share when the backup was created.
- create_
time str - The time when the backup was created.
- download_
bytes str - Amount of bytes that will be downloaded if the backup is restored. This may be different than storage bytes, since sequential backups of the same disk will share storage.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- The resource name of the backup, in the format
projects/{project_number}/locations/{location_id}/backups/{backup_id}
. - satisfies_
pzs bool - Reserved for future use.
- source_
instance_ strtier - The service tier of the source Filestore instance that this backup is created from.
- state str
- The backup state.
- storage_
bytes str - The size of the storage used by the backup. As backups share storage, this number is expected to change with backup creation/deletion.
- capacity
Gb String - Capacity of the source file share when the backup was created.
- create
Time String - The time when the backup was created.
- download
Bytes String - Amount of bytes that will be downloaded if the backup is restored. This may be different than storage bytes, since sequential backups of the same disk will share storage.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The resource name of the backup, in the format
projects/{project_number}/locations/{location_id}/backups/{backup_id}
. - satisfies
Pzs Boolean - Reserved for future use.
- source
Instance StringTier - The service tier of the source Filestore instance that this backup is created from.
- state String
- The backup state.
- storage
Bytes String - The size of the storage used by the backup. As backups share storage, this number is expected to change with backup creation/deletion.
Package Details
- Repository
- Google Cloud Native pulumi/pulumi-google-native
- License
- Apache-2.0
Google Cloud Native is in preview. Google Cloud Classic is fully supported.