ProtectionContainerArgs

data class ProtectionContainerArgs(val containerName: Output<String>? = null, val eTag: Output<String>? = null, val fabricName: Output<String>? = null, val location: Output<String>? = null, val properties: Output<Any>? = null, val resourceGroupName: Output<String>? = null, val tags: Output<Map<String, String>>? = null, val vaultName: Output<String>? = null) : ConvertibleToJava<ProtectionContainerArgs>

Base class for container with backup items. Containers with specific workloads are derived from this class. Uses Azure REST API version 2024-10-01. In version 2.x of the Azure Native provider, it used API version 2023-04-01. Other available API versions: 2023-02-01, 2023-04-01, 2023-06-01, 2023-08-01, 2024-01-01, 2024-02-01, 2024-04-01, 2024-04-30-preview, 2024-07-30-preview, 2024-11-01-preview. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native recoveryservices [ApiVersion]. See the ../../../version-guide/#accessing-any-api-version-via-local-packages for details.

Example Usage

RegisterAzure Storage ProtectionContainers

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var protectionContainer = new AzureNative.RecoveryServices.ProtectionContainer("protectionContainer", new()
{
ContainerName = "StorageContainer;Storage;SwaggerTestRg;swaggertestsa",
FabricName = "Azure",
Properties = new AzureNative.RecoveryServices.Inputs.AzureStorageContainerArgs
{
AcquireStorageAccountLock = AzureNative.RecoveryServices.AcquireStorageAccountLock.Acquire,
BackupManagementType = AzureNative.RecoveryServices.BackupManagementType.AzureStorage,
ContainerType = "StorageContainer",
FriendlyName = "swaggertestsa",
SourceResourceId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/SwaggerTestRg/providers/Microsoft.Storage/storageAccounts/swaggertestsa",
},
ResourceGroupName = "SwaggerTestRg",
VaultName = "swaggertestvault",
});
});
package main
import (
recoveryservices "github.com/pulumi/pulumi-azure-native-sdk/recoveryservices/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := recoveryservices.NewProtectionContainer(ctx, "protectionContainer", &recoveryservices.ProtectionContainerArgs{
ContainerName: pulumi.String("StorageContainer;Storage;SwaggerTestRg;swaggertestsa"),
FabricName: pulumi.String("Azure"),
Properties: &recoveryservices.AzureStorageContainerArgs{
AcquireStorageAccountLock: pulumi.String(recoveryservices.AcquireStorageAccountLockAcquire),
BackupManagementType: pulumi.String(recoveryservices.BackupManagementTypeAzureStorage),
ContainerType: pulumi.String("StorageContainer"),
FriendlyName: pulumi.String("swaggertestsa"),
SourceResourceId: pulumi.String("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/SwaggerTestRg/providers/Microsoft.Storage/storageAccounts/swaggertestsa"),
},
ResourceGroupName: pulumi.String("SwaggerTestRg"),
VaultName: pulumi.String("swaggertestvault"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.recoveryservices.ProtectionContainer;
import com.pulumi.azurenative.recoveryservices.ProtectionContainerArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var protectionContainer = new ProtectionContainer("protectionContainer", ProtectionContainerArgs.builder()
.containerName("StorageContainer;Storage;SwaggerTestRg;swaggertestsa")
.fabricName("Azure")
.properties(AzureStorageContainerArgs.builder()
.acquireStorageAccountLock("Acquire")
.backupManagementType("AzureStorage")
.containerType("StorageContainer")
.friendlyName("swaggertestsa")
.sourceResourceId("/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/SwaggerTestRg/providers/Microsoft.Storage/storageAccounts/swaggertestsa")
.build())
.resourceGroupName("SwaggerTestRg")
.vaultName("swaggertestvault")
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:recoveryservices:ProtectionContainer StorageContainer;Storage;SwaggerTestRg;swaggertestsa /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RecoveryServices/vaults/{vaultName}/backupFabrics/{fabricName}/protectionContainers/{containerName}

Constructors

Link copied to clipboard
constructor(containerName: Output<String>? = null, eTag: Output<String>? = null, fabricName: Output<String>? = null, location: Output<String>? = null, properties: Output<Any>? = null, resourceGroupName: Output<String>? = null, tags: Output<Map<String, String>>? = null, vaultName: Output<String>? = null)

Properties

Link copied to clipboard
val containerName: Output<String>? = null

Name of the container to be registered.

Link copied to clipboard
val eTag: Output<String>? = null

Optional ETag.

Link copied to clipboard
val fabricName: Output<String>? = null

Fabric name associated with the container.

Link copied to clipboard
val location: Output<String>? = null

Resource location.

Link copied to clipboard
val properties: Output<Any>? = null

ProtectionContainerResource properties

Link copied to clipboard
val resourceGroupName: Output<String>? = null

The name of the resource group where the recovery services vault is present.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

Resource tags.

Link copied to clipboard
val vaultName: Output<String>? = null

The name of the recovery services vault.

Functions

Link copied to clipboard
open override fun toJava(): ProtectionContainerArgs