gcp.gkebackup.BackupPlan
Explore with Pulumi AI
Represents a Backup Plan instance.
To get more information about BackupPlan, see:
- API documentation
- How-to Guides
Example Usage
Gkebackup Backupplan Basic
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "basic-cluster",
location: "us-central1",
initialNodeCount: 1,
workloadIdentityConfig: {
workloadPool: "my-project-name.svc.id.goog",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const basic = new gcp.gkebackup.BackupPlan("basic", {
name: "basic-plan",
cluster: primary.id,
location: "us-central1",
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
allNamespaces: true,
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="basic-cluster",
location="us-central1",
initial_node_count=1,
workload_identity_config=gcp.container.ClusterWorkloadIdentityConfigArgs(
workload_pool="my-project-name.svc.id.goog",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
basic = gcp.gkebackup.BackupPlan("basic",
name="basic-plan",
cluster=primary.id,
location="us-central1",
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
all_namespaces=True,
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("basic-cluster"),
Location: pulumi.String("us-central1"),
InitialNodeCount: pulumi.Int(1),
WorkloadIdentityConfig: &container.ClusterWorkloadIdentityConfigArgs{
WorkloadPool: pulumi.String("my-project-name.svc.id.goog"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "basic", &gkebackup.BackupPlanArgs{
Name: pulumi.String("basic-plan"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
AllNamespaces: pulumi.Bool(true),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "basic-cluster",
Location = "us-central1",
InitialNodeCount = 1,
WorkloadIdentityConfig = new Gcp.Container.Inputs.ClusterWorkloadIdentityConfigArgs
{
WorkloadPool = "my-project-name.svc.id.goog",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var basic = new Gcp.GkeBackup.BackupPlan("basic", new()
{
Name = "basic-plan",
Cluster = primary.Id,
Location = "us-central1",
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
AllNamespaces = true,
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterWorkloadIdentityConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("basic-cluster")
.location("us-central1")
.initialNodeCount(1)
.workloadIdentityConfig(ClusterWorkloadIdentityConfigArgs.builder()
.workloadPool("my-project-name.svc.id.goog")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var basic = new BackupPlan("basic", BackupPlanArgs.builder()
.name("basic-plan")
.cluster(primary.id())
.location("us-central1")
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.allNamespaces(true)
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: basic-cluster
location: us-central1
initialNodeCount: 1
workloadIdentityConfig:
workloadPool: my-project-name.svc.id.goog
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
basic:
type: gcp:gkebackup:BackupPlan
properties:
name: basic-plan
cluster: ${primary.id}
location: us-central1
backupConfig:
includeVolumeData: true
includeSecrets: true
allNamespaces: true
Gkebackup Backupplan Autopilot
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "autopilot-cluster",
location: "us-central1",
enableAutopilot: true,
ipAllocationPolicy: {},
releaseChannel: {
channel: "RAPID",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const autopilot = new gcp.gkebackup.BackupPlan("autopilot", {
name: "autopilot-plan",
cluster: primary.id,
location: "us-central1",
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
allNamespaces: true,
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="autopilot-cluster",
location="us-central1",
enable_autopilot=True,
ip_allocation_policy=gcp.container.ClusterIpAllocationPolicyArgs(),
release_channel=gcp.container.ClusterReleaseChannelArgs(
channel="RAPID",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
autopilot = gcp.gkebackup.BackupPlan("autopilot",
name="autopilot-plan",
cluster=primary.id,
location="us-central1",
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
all_namespaces=True,
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("autopilot-cluster"),
Location: pulumi.String("us-central1"),
EnableAutopilot: pulumi.Bool(true),
IpAllocationPolicy: nil,
ReleaseChannel: &container.ClusterReleaseChannelArgs{
Channel: pulumi.String("RAPID"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "autopilot", &gkebackup.BackupPlanArgs{
Name: pulumi.String("autopilot-plan"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
AllNamespaces: pulumi.Bool(true),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "autopilot-cluster",
Location = "us-central1",
EnableAutopilot = true,
IpAllocationPolicy = null,
ReleaseChannel = new Gcp.Container.Inputs.ClusterReleaseChannelArgs
{
Channel = "RAPID",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var autopilot = new Gcp.GkeBackup.BackupPlan("autopilot", new()
{
Name = "autopilot-plan",
Cluster = primary.Id,
Location = "us-central1",
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
AllNamespaces = true,
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterIpAllocationPolicyArgs;
import com.pulumi.gcp.container.inputs.ClusterReleaseChannelArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("autopilot-cluster")
.location("us-central1")
.enableAutopilot(true)
.ipAllocationPolicy()
.releaseChannel(ClusterReleaseChannelArgs.builder()
.channel("RAPID")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var autopilot = new BackupPlan("autopilot", BackupPlanArgs.builder()
.name("autopilot-plan")
.cluster(primary.id())
.location("us-central1")
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.allNamespaces(true)
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: autopilot-cluster
location: us-central1
enableAutopilot: true
ipAllocationPolicy: {}
releaseChannel:
channel: RAPID
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
autopilot:
type: gcp:gkebackup:BackupPlan
properties:
name: autopilot-plan
cluster: ${primary.id}
location: us-central1
backupConfig:
includeVolumeData: true
includeSecrets: true
allNamespaces: true
Gkebackup Backupplan Cmek
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "cmek-cluster",
location: "us-central1",
initialNodeCount: 1,
workloadIdentityConfig: {
workloadPool: "my-project-name.svc.id.goog",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const keyRing = new gcp.kms.KeyRing("key_ring", {
name: "backup-key",
location: "us-central1",
});
const cryptoKey = new gcp.kms.CryptoKey("crypto_key", {
name: "backup-key",
keyRing: keyRing.id,
});
const cmek = new gcp.gkebackup.BackupPlan("cmek", {
name: "cmek-plan",
cluster: primary.id,
location: "us-central1",
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
selectedNamespaces: {
namespaces: [
"default",
"test",
],
},
encryptionKey: {
gcpKmsEncryptionKey: cryptoKey.id,
},
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="cmek-cluster",
location="us-central1",
initial_node_count=1,
workload_identity_config=gcp.container.ClusterWorkloadIdentityConfigArgs(
workload_pool="my-project-name.svc.id.goog",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
key_ring = gcp.kms.KeyRing("key_ring",
name="backup-key",
location="us-central1")
crypto_key = gcp.kms.CryptoKey("crypto_key",
name="backup-key",
key_ring=key_ring.id)
cmek = gcp.gkebackup.BackupPlan("cmek",
name="cmek-plan",
cluster=primary.id,
location="us-central1",
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
selected_namespaces=gcp.gkebackup.BackupPlanBackupConfigSelectedNamespacesArgs(
namespaces=[
"default",
"test",
],
),
encryption_key=gcp.gkebackup.BackupPlanBackupConfigEncryptionKeyArgs(
gcp_kms_encryption_key=crypto_key.id,
),
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/kms"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("cmek-cluster"),
Location: pulumi.String("us-central1"),
InitialNodeCount: pulumi.Int(1),
WorkloadIdentityConfig: &container.ClusterWorkloadIdentityConfigArgs{
WorkloadPool: pulumi.String("my-project-name.svc.id.goog"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
keyRing, err := kms.NewKeyRing(ctx, "key_ring", &kms.KeyRingArgs{
Name: pulumi.String("backup-key"),
Location: pulumi.String("us-central1"),
})
if err != nil {
return err
}
cryptoKey, err := kms.NewCryptoKey(ctx, "crypto_key", &kms.CryptoKeyArgs{
Name: pulumi.String("backup-key"),
KeyRing: keyRing.ID(),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "cmek", &gkebackup.BackupPlanArgs{
Name: pulumi.String("cmek-plan"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
SelectedNamespaces: &gkebackup.BackupPlanBackupConfigSelectedNamespacesArgs{
Namespaces: pulumi.StringArray{
pulumi.String("default"),
pulumi.String("test"),
},
},
EncryptionKey: &gkebackup.BackupPlanBackupConfigEncryptionKeyArgs{
GcpKmsEncryptionKey: cryptoKey.ID(),
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "cmek-cluster",
Location = "us-central1",
InitialNodeCount = 1,
WorkloadIdentityConfig = new Gcp.Container.Inputs.ClusterWorkloadIdentityConfigArgs
{
WorkloadPool = "my-project-name.svc.id.goog",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var keyRing = new Gcp.Kms.KeyRing("key_ring", new()
{
Name = "backup-key",
Location = "us-central1",
});
var cryptoKey = new Gcp.Kms.CryptoKey("crypto_key", new()
{
Name = "backup-key",
KeyRing = keyRing.Id,
});
var cmek = new Gcp.GkeBackup.BackupPlan("cmek", new()
{
Name = "cmek-plan",
Cluster = primary.Id,
Location = "us-central1",
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
SelectedNamespaces = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedNamespacesArgs
{
Namespaces = new[]
{
"default",
"test",
},
},
EncryptionKey = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigEncryptionKeyArgs
{
GcpKmsEncryptionKey = cryptoKey.Id,
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterWorkloadIdentityConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.kms.KeyRing;
import com.pulumi.gcp.kms.KeyRingArgs;
import com.pulumi.gcp.kms.CryptoKey;
import com.pulumi.gcp.kms.CryptoKeyArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigSelectedNamespacesArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigEncryptionKeyArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("cmek-cluster")
.location("us-central1")
.initialNodeCount(1)
.workloadIdentityConfig(ClusterWorkloadIdentityConfigArgs.builder()
.workloadPool("my-project-name.svc.id.goog")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var keyRing = new KeyRing("keyRing", KeyRingArgs.builder()
.name("backup-key")
.location("us-central1")
.build());
var cryptoKey = new CryptoKey("cryptoKey", CryptoKeyArgs.builder()
.name("backup-key")
.keyRing(keyRing.id())
.build());
var cmek = new BackupPlan("cmek", BackupPlanArgs.builder()
.name("cmek-plan")
.cluster(primary.id())
.location("us-central1")
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.selectedNamespaces(BackupPlanBackupConfigSelectedNamespacesArgs.builder()
.namespaces(
"default",
"test")
.build())
.encryptionKey(BackupPlanBackupConfigEncryptionKeyArgs.builder()
.gcpKmsEncryptionKey(cryptoKey.id())
.build())
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: cmek-cluster
location: us-central1
initialNodeCount: 1
workloadIdentityConfig:
workloadPool: my-project-name.svc.id.goog
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
cmek:
type: gcp:gkebackup:BackupPlan
properties:
name: cmek-plan
cluster: ${primary.id}
location: us-central1
backupConfig:
includeVolumeData: true
includeSecrets: true
selectedNamespaces:
namespaces:
- default
- test
encryptionKey:
gcpKmsEncryptionKey: ${cryptoKey.id}
cryptoKey:
type: gcp:kms:CryptoKey
name: crypto_key
properties:
name: backup-key
keyRing: ${keyRing.id}
keyRing:
type: gcp:kms:KeyRing
name: key_ring
properties:
name: backup-key
location: us-central1
Gkebackup Backupplan Full
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "full-cluster",
location: "us-central1",
initialNodeCount: 1,
workloadIdentityConfig: {
workloadPool: "my-project-name.svc.id.goog",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const full = new gcp.gkebackup.BackupPlan("full", {
name: "full-plan",
cluster: primary.id,
location: "us-central1",
retentionPolicy: {
backupDeleteLockDays: 30,
backupRetainDays: 180,
},
backupSchedule: {
cronSchedule: "0 9 * * 1",
},
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
selectedApplications: {
namespacedNames: [
{
name: "app1",
namespace: "ns1",
},
{
name: "app2",
namespace: "ns2",
},
],
},
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="full-cluster",
location="us-central1",
initial_node_count=1,
workload_identity_config=gcp.container.ClusterWorkloadIdentityConfigArgs(
workload_pool="my-project-name.svc.id.goog",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
full = gcp.gkebackup.BackupPlan("full",
name="full-plan",
cluster=primary.id,
location="us-central1",
retention_policy=gcp.gkebackup.BackupPlanRetentionPolicyArgs(
backup_delete_lock_days=30,
backup_retain_days=180,
),
backup_schedule=gcp.gkebackup.BackupPlanBackupScheduleArgs(
cron_schedule="0 9 * * 1",
),
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
selected_applications=gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsArgs(
namespaced_names=[
gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs(
name="app1",
namespace="ns1",
),
gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs(
name="app2",
namespace="ns2",
),
],
),
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("full-cluster"),
Location: pulumi.String("us-central1"),
InitialNodeCount: pulumi.Int(1),
WorkloadIdentityConfig: &container.ClusterWorkloadIdentityConfigArgs{
WorkloadPool: pulumi.String("my-project-name.svc.id.goog"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "full", &gkebackup.BackupPlanArgs{
Name: pulumi.String("full-plan"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
RetentionPolicy: &gkebackup.BackupPlanRetentionPolicyArgs{
BackupDeleteLockDays: pulumi.Int(30),
BackupRetainDays: pulumi.Int(180),
},
BackupSchedule: &gkebackup.BackupPlanBackupScheduleArgs{
CronSchedule: pulumi.String("0 9 * * 1"),
},
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
SelectedApplications: &gkebackup.BackupPlanBackupConfigSelectedApplicationsArgs{
NamespacedNames: gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArray{
&gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs{
Name: pulumi.String("app1"),
Namespace: pulumi.String("ns1"),
},
&gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs{
Name: pulumi.String("app2"),
Namespace: pulumi.String("ns2"),
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "full-cluster",
Location = "us-central1",
InitialNodeCount = 1,
WorkloadIdentityConfig = new Gcp.Container.Inputs.ClusterWorkloadIdentityConfigArgs
{
WorkloadPool = "my-project-name.svc.id.goog",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var full = new Gcp.GkeBackup.BackupPlan("full", new()
{
Name = "full-plan",
Cluster = primary.Id,
Location = "us-central1",
RetentionPolicy = new Gcp.GkeBackup.Inputs.BackupPlanRetentionPolicyArgs
{
BackupDeleteLockDays = 30,
BackupRetainDays = 180,
},
BackupSchedule = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleArgs
{
CronSchedule = "0 9 * * 1",
},
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
SelectedApplications = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsArgs
{
NamespacedNames = new[]
{
new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs
{
Name = "app1",
Namespace = "ns1",
},
new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs
{
Name = "app2",
Namespace = "ns2",
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterWorkloadIdentityConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanRetentionPolicyArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupScheduleArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigSelectedApplicationsArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("full-cluster")
.location("us-central1")
.initialNodeCount(1)
.workloadIdentityConfig(ClusterWorkloadIdentityConfigArgs.builder()
.workloadPool("my-project-name.svc.id.goog")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var full = new BackupPlan("full", BackupPlanArgs.builder()
.name("full-plan")
.cluster(primary.id())
.location("us-central1")
.retentionPolicy(BackupPlanRetentionPolicyArgs.builder()
.backupDeleteLockDays(30)
.backupRetainDays(180)
.build())
.backupSchedule(BackupPlanBackupScheduleArgs.builder()
.cronSchedule("0 9 * * 1")
.build())
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.selectedApplications(BackupPlanBackupConfigSelectedApplicationsArgs.builder()
.namespacedNames(
BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs.builder()
.name("app1")
.namespace("ns1")
.build(),
BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs.builder()
.name("app2")
.namespace("ns2")
.build())
.build())
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: full-cluster
location: us-central1
initialNodeCount: 1
workloadIdentityConfig:
workloadPool: my-project-name.svc.id.goog
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
full:
type: gcp:gkebackup:BackupPlan
properties:
name: full-plan
cluster: ${primary.id}
location: us-central1
retentionPolicy:
backupDeleteLockDays: 30
backupRetainDays: 180
backupSchedule:
cronSchedule: 0 9 * * 1
backupConfig:
includeVolumeData: true
includeSecrets: true
selectedApplications:
namespacedNames:
- name: app1
namespace: ns1
- name: app2
namespace: ns2
Gkebackup Backupplan Permissive
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "permissive-cluster",
location: "us-central1",
initialNodeCount: 1,
workloadIdentityConfig: {
workloadPool: "my-project-name.svc.id.goog",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const permissive = new gcp.gkebackup.BackupPlan("permissive", {
name: "permissive-plan",
cluster: primary.id,
location: "us-central1",
retentionPolicy: {
backupDeleteLockDays: 30,
backupRetainDays: 180,
},
backupSchedule: {
cronSchedule: "0 9 * * 1",
},
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
permissiveMode: true,
selectedApplications: {
namespacedNames: [
{
name: "app1",
namespace: "ns1",
},
{
name: "app2",
namespace: "ns2",
},
],
},
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="permissive-cluster",
location="us-central1",
initial_node_count=1,
workload_identity_config=gcp.container.ClusterWorkloadIdentityConfigArgs(
workload_pool="my-project-name.svc.id.goog",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
permissive = gcp.gkebackup.BackupPlan("permissive",
name="permissive-plan",
cluster=primary.id,
location="us-central1",
retention_policy=gcp.gkebackup.BackupPlanRetentionPolicyArgs(
backup_delete_lock_days=30,
backup_retain_days=180,
),
backup_schedule=gcp.gkebackup.BackupPlanBackupScheduleArgs(
cron_schedule="0 9 * * 1",
),
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
permissive_mode=True,
selected_applications=gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsArgs(
namespaced_names=[
gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs(
name="app1",
namespace="ns1",
),
gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs(
name="app2",
namespace="ns2",
),
],
),
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("permissive-cluster"),
Location: pulumi.String("us-central1"),
InitialNodeCount: pulumi.Int(1),
WorkloadIdentityConfig: &container.ClusterWorkloadIdentityConfigArgs{
WorkloadPool: pulumi.String("my-project-name.svc.id.goog"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "permissive", &gkebackup.BackupPlanArgs{
Name: pulumi.String("permissive-plan"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
RetentionPolicy: &gkebackup.BackupPlanRetentionPolicyArgs{
BackupDeleteLockDays: pulumi.Int(30),
BackupRetainDays: pulumi.Int(180),
},
BackupSchedule: &gkebackup.BackupPlanBackupScheduleArgs{
CronSchedule: pulumi.String("0 9 * * 1"),
},
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
PermissiveMode: pulumi.Bool(true),
SelectedApplications: &gkebackup.BackupPlanBackupConfigSelectedApplicationsArgs{
NamespacedNames: gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArray{
&gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs{
Name: pulumi.String("app1"),
Namespace: pulumi.String("ns1"),
},
&gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs{
Name: pulumi.String("app2"),
Namespace: pulumi.String("ns2"),
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "permissive-cluster",
Location = "us-central1",
InitialNodeCount = 1,
WorkloadIdentityConfig = new Gcp.Container.Inputs.ClusterWorkloadIdentityConfigArgs
{
WorkloadPool = "my-project-name.svc.id.goog",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var permissive = new Gcp.GkeBackup.BackupPlan("permissive", new()
{
Name = "permissive-plan",
Cluster = primary.Id,
Location = "us-central1",
RetentionPolicy = new Gcp.GkeBackup.Inputs.BackupPlanRetentionPolicyArgs
{
BackupDeleteLockDays = 30,
BackupRetainDays = 180,
},
BackupSchedule = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleArgs
{
CronSchedule = "0 9 * * 1",
},
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
PermissiveMode = true,
SelectedApplications = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsArgs
{
NamespacedNames = new[]
{
new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs
{
Name = "app1",
Namespace = "ns1",
},
new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs
{
Name = "app2",
Namespace = "ns2",
},
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterWorkloadIdentityConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanRetentionPolicyArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupScheduleArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigSelectedApplicationsArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("permissive-cluster")
.location("us-central1")
.initialNodeCount(1)
.workloadIdentityConfig(ClusterWorkloadIdentityConfigArgs.builder()
.workloadPool("my-project-name.svc.id.goog")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var permissive = new BackupPlan("permissive", BackupPlanArgs.builder()
.name("permissive-plan")
.cluster(primary.id())
.location("us-central1")
.retentionPolicy(BackupPlanRetentionPolicyArgs.builder()
.backupDeleteLockDays(30)
.backupRetainDays(180)
.build())
.backupSchedule(BackupPlanBackupScheduleArgs.builder()
.cronSchedule("0 9 * * 1")
.build())
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.permissiveMode(true)
.selectedApplications(BackupPlanBackupConfigSelectedApplicationsArgs.builder()
.namespacedNames(
BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs.builder()
.name("app1")
.namespace("ns1")
.build(),
BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs.builder()
.name("app2")
.namespace("ns2")
.build())
.build())
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: permissive-cluster
location: us-central1
initialNodeCount: 1
workloadIdentityConfig:
workloadPool: my-project-name.svc.id.goog
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
permissive:
type: gcp:gkebackup:BackupPlan
properties:
name: permissive-plan
cluster: ${primary.id}
location: us-central1
retentionPolicy:
backupDeleteLockDays: 30
backupRetainDays: 180
backupSchedule:
cronSchedule: 0 9 * * 1
backupConfig:
includeVolumeData: true
includeSecrets: true
permissiveMode: true
selectedApplications:
namespacedNames:
- name: app1
namespace: ns1
- name: app2
namespace: ns2
Gkebackup Backupplan Rpo Daily Window
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "rpo-daily-cluster",
location: "us-central1",
initialNodeCount: 1,
workloadIdentityConfig: {
workloadPool: "my-project-name.svc.id.goog",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const rpoDailyWindow = new gcp.gkebackup.BackupPlan("rpo_daily_window", {
name: "rpo-daily-window",
cluster: primary.id,
location: "us-central1",
retentionPolicy: {
backupDeleteLockDays: 30,
backupRetainDays: 180,
},
backupSchedule: {
paused: true,
rpoConfig: {
targetRpoMinutes: 1440,
exclusionWindows: [
{
startTime: {
hours: 12,
},
duration: "7200s",
daily: true,
},
{
startTime: {
hours: 8,
minutes: 40,
seconds: 1,
nanos: 100,
},
duration: "3600s",
singleOccurrenceDate: {
year: 2024,
month: 3,
day: 16,
},
},
],
},
},
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
allNamespaces: true,
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="rpo-daily-cluster",
location="us-central1",
initial_node_count=1,
workload_identity_config=gcp.container.ClusterWorkloadIdentityConfigArgs(
workload_pool="my-project-name.svc.id.goog",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
rpo_daily_window = gcp.gkebackup.BackupPlan("rpo_daily_window",
name="rpo-daily-window",
cluster=primary.id,
location="us-central1",
retention_policy=gcp.gkebackup.BackupPlanRetentionPolicyArgs(
backup_delete_lock_days=30,
backup_retain_days=180,
),
backup_schedule=gcp.gkebackup.BackupPlanBackupScheduleArgs(
paused=True,
rpo_config=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigArgs(
target_rpo_minutes=1440,
exclusion_windows=[
gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs(
start_time=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs(
hours=12,
),
duration="7200s",
daily=True,
),
gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs(
start_time=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs(
hours=8,
minutes=40,
seconds=1,
nanos=100,
),
duration="3600s",
single_occurrence_date=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs(
year=2024,
month=3,
day=16,
),
),
],
),
),
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
all_namespaces=True,
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("rpo-daily-cluster"),
Location: pulumi.String("us-central1"),
InitialNodeCount: pulumi.Int(1),
WorkloadIdentityConfig: &container.ClusterWorkloadIdentityConfigArgs{
WorkloadPool: pulumi.String("my-project-name.svc.id.goog"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "rpo_daily_window", &gkebackup.BackupPlanArgs{
Name: pulumi.String("rpo-daily-window"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
RetentionPolicy: &gkebackup.BackupPlanRetentionPolicyArgs{
BackupDeleteLockDays: pulumi.Int(30),
BackupRetainDays: pulumi.Int(180),
},
BackupSchedule: &gkebackup.BackupPlanBackupScheduleArgs{
Paused: pulumi.Bool(true),
RpoConfig: &gkebackup.BackupPlanBackupScheduleRpoConfigArgs{
TargetRpoMinutes: pulumi.Int(1440),
ExclusionWindows: gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArray{
&gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs{
StartTime: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs{
Hours: pulumi.Int(12),
},
Duration: pulumi.String("7200s"),
Daily: pulumi.Bool(true),
},
&gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs{
StartTime: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs{
Hours: pulumi.Int(8),
Minutes: pulumi.Int(40),
Seconds: pulumi.Int(1),
Nanos: pulumi.Int(100),
},
Duration: pulumi.String("3600s"),
SingleOccurrenceDate: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs{
Year: pulumi.Int(2024),
Month: pulumi.Int(3),
Day: pulumi.Int(16),
},
},
},
},
},
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
AllNamespaces: pulumi.Bool(true),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "rpo-daily-cluster",
Location = "us-central1",
InitialNodeCount = 1,
WorkloadIdentityConfig = new Gcp.Container.Inputs.ClusterWorkloadIdentityConfigArgs
{
WorkloadPool = "my-project-name.svc.id.goog",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var rpoDailyWindow = new Gcp.GkeBackup.BackupPlan("rpo_daily_window", new()
{
Name = "rpo-daily-window",
Cluster = primary.Id,
Location = "us-central1",
RetentionPolicy = new Gcp.GkeBackup.Inputs.BackupPlanRetentionPolicyArgs
{
BackupDeleteLockDays = 30,
BackupRetainDays = 180,
},
BackupSchedule = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleArgs
{
Paused = true,
RpoConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigArgs
{
TargetRpoMinutes = 1440,
ExclusionWindows = new[]
{
new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
{
StartTime = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
{
Hours = 12,
},
Duration = "7200s",
Daily = true,
},
new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
{
StartTime = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
{
Hours = 8,
Minutes = 40,
Seconds = 1,
Nanos = 100,
},
Duration = "3600s",
SingleOccurrenceDate = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs
{
Year = 2024,
Month = 3,
Day = 16,
},
},
},
},
},
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
AllNamespaces = true,
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterWorkloadIdentityConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanRetentionPolicyArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupScheduleArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupScheduleRpoConfigArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("rpo-daily-cluster")
.location("us-central1")
.initialNodeCount(1)
.workloadIdentityConfig(ClusterWorkloadIdentityConfigArgs.builder()
.workloadPool("my-project-name.svc.id.goog")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var rpoDailyWindow = new BackupPlan("rpoDailyWindow", BackupPlanArgs.builder()
.name("rpo-daily-window")
.cluster(primary.id())
.location("us-central1")
.retentionPolicy(BackupPlanRetentionPolicyArgs.builder()
.backupDeleteLockDays(30)
.backupRetainDays(180)
.build())
.backupSchedule(BackupPlanBackupScheduleArgs.builder()
.paused(true)
.rpoConfig(BackupPlanBackupScheduleRpoConfigArgs.builder()
.targetRpoMinutes(1440)
.exclusionWindows(
BackupPlanBackupScheduleRpoConfigExclusionWindowArgs.builder()
.startTime(BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs.builder()
.hours(12)
.build())
.duration("7200s")
.daily(true)
.build(),
BackupPlanBackupScheduleRpoConfigExclusionWindowArgs.builder()
.startTime(BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs.builder()
.hours(8)
.minutes(40)
.seconds(1)
.nanos(100)
.build())
.duration("3600s")
.singleOccurrenceDate(BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs.builder()
.year(2024)
.month(3)
.day(16)
.build())
.build())
.build())
.build())
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.allNamespaces(true)
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: rpo-daily-cluster
location: us-central1
initialNodeCount: 1
workloadIdentityConfig:
workloadPool: my-project-name.svc.id.goog
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
rpoDailyWindow:
type: gcp:gkebackup:BackupPlan
name: rpo_daily_window
properties:
name: rpo-daily-window
cluster: ${primary.id}
location: us-central1
retentionPolicy:
backupDeleteLockDays: 30
backupRetainDays: 180
backupSchedule:
paused: true
rpoConfig:
targetRpoMinutes: 1440
exclusionWindows:
- startTime:
hours: 12
duration: 7200s
daily: true
- startTime:
hours: 8
minutes: 40
seconds: 1
nanos: 100
duration: 3600s
singleOccurrenceDate:
year: 2024
month: 3
day: 16
backupConfig:
includeVolumeData: true
includeSecrets: true
allNamespaces: true
Gkebackup Backupplan Rpo Weekly Window
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const primary = new gcp.container.Cluster("primary", {
name: "rpo-weekly-cluster",
location: "us-central1",
initialNodeCount: 1,
workloadIdentityConfig: {
workloadPool: "my-project-name.svc.id.goog",
},
addonsConfig: {
gkeBackupAgentConfig: {
enabled: true,
},
},
deletionProtection: true,
network: "default",
subnetwork: "default",
});
const rpoWeeklyWindow = new gcp.gkebackup.BackupPlan("rpo_weekly_window", {
name: "rpo-weekly-window",
cluster: primary.id,
location: "us-central1",
retentionPolicy: {
backupDeleteLockDays: 30,
backupRetainDays: 180,
},
backupSchedule: {
paused: true,
rpoConfig: {
targetRpoMinutes: 1440,
exclusionWindows: [
{
startTime: {
hours: 1,
minutes: 23,
},
duration: "1800s",
daysOfWeek: {
daysOfWeeks: [
"MONDAY",
"THURSDAY",
],
},
},
{
startTime: {
hours: 12,
},
duration: "3600s",
singleOccurrenceDate: {
year: 2024,
month: 3,
day: 17,
},
},
{
startTime: {
hours: 8,
minutes: 40,
},
duration: "600s",
singleOccurrenceDate: {
year: 2024,
month: 3,
day: 18,
},
},
],
},
},
backupConfig: {
includeVolumeData: true,
includeSecrets: true,
allNamespaces: true,
},
});
import pulumi
import pulumi_gcp as gcp
primary = gcp.container.Cluster("primary",
name="rpo-weekly-cluster",
location="us-central1",
initial_node_count=1,
workload_identity_config=gcp.container.ClusterWorkloadIdentityConfigArgs(
workload_pool="my-project-name.svc.id.goog",
),
addons_config=gcp.container.ClusterAddonsConfigArgs(
gke_backup_agent_config=gcp.container.ClusterAddonsConfigGkeBackupAgentConfigArgs(
enabled=True,
),
),
deletion_protection=True,
network="default",
subnetwork="default")
rpo_weekly_window = gcp.gkebackup.BackupPlan("rpo_weekly_window",
name="rpo-weekly-window",
cluster=primary.id,
location="us-central1",
retention_policy=gcp.gkebackup.BackupPlanRetentionPolicyArgs(
backup_delete_lock_days=30,
backup_retain_days=180,
),
backup_schedule=gcp.gkebackup.BackupPlanBackupScheduleArgs(
paused=True,
rpo_config=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigArgs(
target_rpo_minutes=1440,
exclusion_windows=[
gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs(
start_time=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs(
hours=1,
minutes=23,
),
duration="1800s",
days_of_week=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs(
days_of_weeks=[
"MONDAY",
"THURSDAY",
],
),
),
gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs(
start_time=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs(
hours=12,
),
duration="3600s",
single_occurrence_date=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs(
year=2024,
month=3,
day=17,
),
),
gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs(
start_time=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs(
hours=8,
minutes=40,
),
duration="600s",
single_occurrence_date=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs(
year=2024,
month=3,
day=18,
),
),
],
),
),
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
include_volume_data=True,
include_secrets=True,
all_namespaces=True,
))
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/container"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/gkebackup"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
primary, err := container.NewCluster(ctx, "primary", &container.ClusterArgs{
Name: pulumi.String("rpo-weekly-cluster"),
Location: pulumi.String("us-central1"),
InitialNodeCount: pulumi.Int(1),
WorkloadIdentityConfig: &container.ClusterWorkloadIdentityConfigArgs{
WorkloadPool: pulumi.String("my-project-name.svc.id.goog"),
},
AddonsConfig: &container.ClusterAddonsConfigArgs{
GkeBackupAgentConfig: &container.ClusterAddonsConfigGkeBackupAgentConfigArgs{
Enabled: pulumi.Bool(true),
},
},
DeletionProtection: pulumi.Bool(true),
Network: pulumi.String("default"),
Subnetwork: pulumi.String("default"),
})
if err != nil {
return err
}
_, err = gkebackup.NewBackupPlan(ctx, "rpo_weekly_window", &gkebackup.BackupPlanArgs{
Name: pulumi.String("rpo-weekly-window"),
Cluster: primary.ID(),
Location: pulumi.String("us-central1"),
RetentionPolicy: &gkebackup.BackupPlanRetentionPolicyArgs{
BackupDeleteLockDays: pulumi.Int(30),
BackupRetainDays: pulumi.Int(180),
},
BackupSchedule: &gkebackup.BackupPlanBackupScheduleArgs{
Paused: pulumi.Bool(true),
RpoConfig: &gkebackup.BackupPlanBackupScheduleRpoConfigArgs{
TargetRpoMinutes: pulumi.Int(1440),
ExclusionWindows: gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArray{
&gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs{
StartTime: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs{
Hours: pulumi.Int(1),
Minutes: pulumi.Int(23),
},
Duration: pulumi.String("1800s"),
DaysOfWeek: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs{
DaysOfWeeks: pulumi.StringArray{
pulumi.String("MONDAY"),
pulumi.String("THURSDAY"),
},
},
},
&gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs{
StartTime: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs{
Hours: pulumi.Int(12),
},
Duration: pulumi.String("3600s"),
SingleOccurrenceDate: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs{
Year: pulumi.Int(2024),
Month: pulumi.Int(3),
Day: pulumi.Int(17),
},
},
&gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs{
StartTime: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs{
Hours: pulumi.Int(8),
Minutes: pulumi.Int(40),
},
Duration: pulumi.String("600s"),
SingleOccurrenceDate: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs{
Year: pulumi.Int(2024),
Month: pulumi.Int(3),
Day: pulumi.Int(18),
},
},
},
},
},
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
IncludeVolumeData: pulumi.Bool(true),
IncludeSecrets: pulumi.Bool(true),
AllNamespaces: pulumi.Bool(true),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var primary = new Gcp.Container.Cluster("primary", new()
{
Name = "rpo-weekly-cluster",
Location = "us-central1",
InitialNodeCount = 1,
WorkloadIdentityConfig = new Gcp.Container.Inputs.ClusterWorkloadIdentityConfigArgs
{
WorkloadPool = "my-project-name.svc.id.goog",
},
AddonsConfig = new Gcp.Container.Inputs.ClusterAddonsConfigArgs
{
GkeBackupAgentConfig = new Gcp.Container.Inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs
{
Enabled = true,
},
},
DeletionProtection = true,
Network = "default",
Subnetwork = "default",
});
var rpoWeeklyWindow = new Gcp.GkeBackup.BackupPlan("rpo_weekly_window", new()
{
Name = "rpo-weekly-window",
Cluster = primary.Id,
Location = "us-central1",
RetentionPolicy = new Gcp.GkeBackup.Inputs.BackupPlanRetentionPolicyArgs
{
BackupDeleteLockDays = 30,
BackupRetainDays = 180,
},
BackupSchedule = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleArgs
{
Paused = true,
RpoConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigArgs
{
TargetRpoMinutes = 1440,
ExclusionWindows = new[]
{
new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
{
StartTime = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
{
Hours = 1,
Minutes = 23,
},
Duration = "1800s",
DaysOfWeek = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs
{
DaysOfWeeks = new[]
{
"MONDAY",
"THURSDAY",
},
},
},
new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
{
StartTime = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
{
Hours = 12,
},
Duration = "3600s",
SingleOccurrenceDate = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs
{
Year = 2024,
Month = 3,
Day = 17,
},
},
new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
{
StartTime = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
{
Hours = 8,
Minutes = 40,
},
Duration = "600s",
SingleOccurrenceDate = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs
{
Year = 2024,
Month = 3,
Day = 18,
},
},
},
},
},
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
IncludeVolumeData = true,
IncludeSecrets = true,
AllNamespaces = true,
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.Cluster;
import com.pulumi.gcp.container.ClusterArgs;
import com.pulumi.gcp.container.inputs.ClusterWorkloadIdentityConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigArgs;
import com.pulumi.gcp.container.inputs.ClusterAddonsConfigGkeBackupAgentConfigArgs;
import com.pulumi.gcp.gkebackup.BackupPlan;
import com.pulumi.gcp.gkebackup.BackupPlanArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanRetentionPolicyArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupScheduleArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupScheduleRpoConfigArgs;
import com.pulumi.gcp.gkebackup.inputs.BackupPlanBackupConfigArgs;
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 primary = new Cluster("primary", ClusterArgs.builder()
.name("rpo-weekly-cluster")
.location("us-central1")
.initialNodeCount(1)
.workloadIdentityConfig(ClusterWorkloadIdentityConfigArgs.builder()
.workloadPool("my-project-name.svc.id.goog")
.build())
.addonsConfig(ClusterAddonsConfigArgs.builder()
.gkeBackupAgentConfig(ClusterAddonsConfigGkeBackupAgentConfigArgs.builder()
.enabled(true)
.build())
.build())
.deletionProtection("true")
.network("default")
.subnetwork("default")
.build());
var rpoWeeklyWindow = new BackupPlan("rpoWeeklyWindow", BackupPlanArgs.builder()
.name("rpo-weekly-window")
.cluster(primary.id())
.location("us-central1")
.retentionPolicy(BackupPlanRetentionPolicyArgs.builder()
.backupDeleteLockDays(30)
.backupRetainDays(180)
.build())
.backupSchedule(BackupPlanBackupScheduleArgs.builder()
.paused(true)
.rpoConfig(BackupPlanBackupScheduleRpoConfigArgs.builder()
.targetRpoMinutes(1440)
.exclusionWindows(
BackupPlanBackupScheduleRpoConfigExclusionWindowArgs.builder()
.startTime(BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs.builder()
.hours(1)
.minutes(23)
.build())
.duration("1800s")
.daysOfWeek(BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs.builder()
.daysOfWeeks(
"MONDAY",
"THURSDAY")
.build())
.build(),
BackupPlanBackupScheduleRpoConfigExclusionWindowArgs.builder()
.startTime(BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs.builder()
.hours(12)
.build())
.duration("3600s")
.singleOccurrenceDate(BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs.builder()
.year(2024)
.month(3)
.day(17)
.build())
.build(),
BackupPlanBackupScheduleRpoConfigExclusionWindowArgs.builder()
.startTime(BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs.builder()
.hours(8)
.minutes(40)
.build())
.duration("600s")
.singleOccurrenceDate(BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs.builder()
.year(2024)
.month(3)
.day(18)
.build())
.build())
.build())
.build())
.backupConfig(BackupPlanBackupConfigArgs.builder()
.includeVolumeData(true)
.includeSecrets(true)
.allNamespaces(true)
.build())
.build());
}
}
resources:
primary:
type: gcp:container:Cluster
properties:
name: rpo-weekly-cluster
location: us-central1
initialNodeCount: 1
workloadIdentityConfig:
workloadPool: my-project-name.svc.id.goog
addonsConfig:
gkeBackupAgentConfig:
enabled: true
deletionProtection: 'true'
network: default
subnetwork: default
rpoWeeklyWindow:
type: gcp:gkebackup:BackupPlan
name: rpo_weekly_window
properties:
name: rpo-weekly-window
cluster: ${primary.id}
location: us-central1
retentionPolicy:
backupDeleteLockDays: 30
backupRetainDays: 180
backupSchedule:
paused: true
rpoConfig:
targetRpoMinutes: 1440
exclusionWindows:
- startTime:
hours: 1
minutes: 23
duration: 1800s
daysOfWeek:
daysOfWeeks:
- MONDAY
- THURSDAY
- startTime:
hours: 12
duration: 3600s
singleOccurrenceDate:
year: 2024
month: 3
day: 17
- startTime:
hours: 8
minutes: 40
duration: 600s
singleOccurrenceDate:
year: 2024
month: 3
day: 18
backupConfig:
includeVolumeData: true
includeSecrets: true
allNamespaces: true
Create BackupPlan Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new BackupPlan(name: string, args: BackupPlanArgs, opts?: CustomResourceOptions);
@overload
def BackupPlan(resource_name: str,
args: BackupPlanArgs,
opts: Optional[ResourceOptions] = None)
@overload
def BackupPlan(resource_name: str,
opts: Optional[ResourceOptions] = None,
cluster: Optional[str] = None,
location: Optional[str] = None,
backup_config: Optional[BackupPlanBackupConfigArgs] = None,
backup_schedule: Optional[BackupPlanBackupScheduleArgs] = None,
deactivated: Optional[bool] = None,
description: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
name: Optional[str] = None,
project: Optional[str] = None,
retention_policy: Optional[BackupPlanRetentionPolicyArgs] = None)
func NewBackupPlan(ctx *Context, name string, args BackupPlanArgs, opts ...ResourceOption) (*BackupPlan, error)
public BackupPlan(string name, BackupPlanArgs args, CustomResourceOptions? opts = null)
public BackupPlan(String name, BackupPlanArgs args)
public BackupPlan(String name, BackupPlanArgs args, CustomResourceOptions options)
type: gcp:gkebackup:BackupPlan
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 BackupPlanArgs
- 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 BackupPlanArgs
- 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 BackupPlanArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args BackupPlanArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args BackupPlanArgs
- 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 backupPlanResource = new Gcp.GkeBackup.BackupPlan("backupPlanResource", new()
{
Cluster = "string",
Location = "string",
BackupConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigArgs
{
AllNamespaces = false,
EncryptionKey = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigEncryptionKeyArgs
{
GcpKmsEncryptionKey = "string",
},
IncludeSecrets = false,
IncludeVolumeData = false,
PermissiveMode = false,
SelectedApplications = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsArgs
{
NamespacedNames = new[]
{
new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs
{
Name = "string",
Namespace = "string",
},
},
},
SelectedNamespaces = new Gcp.GkeBackup.Inputs.BackupPlanBackupConfigSelectedNamespacesArgs
{
Namespaces = new[]
{
"string",
},
},
},
BackupSchedule = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleArgs
{
CronSchedule = "string",
Paused = false,
RpoConfig = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigArgs
{
TargetRpoMinutes = 0,
ExclusionWindows = new[]
{
new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
{
Duration = "string",
StartTime = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
{
Hours = 0,
Minutes = 0,
Nanos = 0,
Seconds = 0,
},
Daily = false,
DaysOfWeek = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs
{
DaysOfWeeks = new[]
{
"string",
},
},
SingleOccurrenceDate = new Gcp.GkeBackup.Inputs.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs
{
Day = 0,
Month = 0,
Year = 0,
},
},
},
},
},
Deactivated = false,
Description = "string",
Labels =
{
{ "string", "string" },
},
Name = "string",
Project = "string",
RetentionPolicy = new Gcp.GkeBackup.Inputs.BackupPlanRetentionPolicyArgs
{
BackupDeleteLockDays = 0,
BackupRetainDays = 0,
Locked = false,
},
});
example, err := gkebackup.NewBackupPlan(ctx, "backupPlanResource", &gkebackup.BackupPlanArgs{
Cluster: pulumi.String("string"),
Location: pulumi.String("string"),
BackupConfig: &gkebackup.BackupPlanBackupConfigArgs{
AllNamespaces: pulumi.Bool(false),
EncryptionKey: &gkebackup.BackupPlanBackupConfigEncryptionKeyArgs{
GcpKmsEncryptionKey: pulumi.String("string"),
},
IncludeSecrets: pulumi.Bool(false),
IncludeVolumeData: pulumi.Bool(false),
PermissiveMode: pulumi.Bool(false),
SelectedApplications: &gkebackup.BackupPlanBackupConfigSelectedApplicationsArgs{
NamespacedNames: gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArray{
&gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs{
Name: pulumi.String("string"),
Namespace: pulumi.String("string"),
},
},
},
SelectedNamespaces: &gkebackup.BackupPlanBackupConfigSelectedNamespacesArgs{
Namespaces: pulumi.StringArray{
pulumi.String("string"),
},
},
},
BackupSchedule: &gkebackup.BackupPlanBackupScheduleArgs{
CronSchedule: pulumi.String("string"),
Paused: pulumi.Bool(false),
RpoConfig: &gkebackup.BackupPlanBackupScheduleRpoConfigArgs{
TargetRpoMinutes: pulumi.Int(0),
ExclusionWindows: gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArray{
&gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs{
Duration: pulumi.String("string"),
StartTime: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs{
Hours: pulumi.Int(0),
Minutes: pulumi.Int(0),
Nanos: pulumi.Int(0),
Seconds: pulumi.Int(0),
},
Daily: pulumi.Bool(false),
DaysOfWeek: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs{
DaysOfWeeks: pulumi.StringArray{
pulumi.String("string"),
},
},
SingleOccurrenceDate: &gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs{
Day: pulumi.Int(0),
Month: pulumi.Int(0),
Year: pulumi.Int(0),
},
},
},
},
},
Deactivated: pulumi.Bool(false),
Description: pulumi.String("string"),
Labels: pulumi.StringMap{
"string": pulumi.String("string"),
},
Name: pulumi.String("string"),
Project: pulumi.String("string"),
RetentionPolicy: &gkebackup.BackupPlanRetentionPolicyArgs{
BackupDeleteLockDays: pulumi.Int(0),
BackupRetainDays: pulumi.Int(0),
Locked: pulumi.Bool(false),
},
})
var backupPlanResource = new BackupPlan("backupPlanResource", BackupPlanArgs.builder()
.cluster("string")
.location("string")
.backupConfig(BackupPlanBackupConfigArgs.builder()
.allNamespaces(false)
.encryptionKey(BackupPlanBackupConfigEncryptionKeyArgs.builder()
.gcpKmsEncryptionKey("string")
.build())
.includeSecrets(false)
.includeVolumeData(false)
.permissiveMode(false)
.selectedApplications(BackupPlanBackupConfigSelectedApplicationsArgs.builder()
.namespacedNames(BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs.builder()
.name("string")
.namespace("string")
.build())
.build())
.selectedNamespaces(BackupPlanBackupConfigSelectedNamespacesArgs.builder()
.namespaces("string")
.build())
.build())
.backupSchedule(BackupPlanBackupScheduleArgs.builder()
.cronSchedule("string")
.paused(false)
.rpoConfig(BackupPlanBackupScheduleRpoConfigArgs.builder()
.targetRpoMinutes(0)
.exclusionWindows(BackupPlanBackupScheduleRpoConfigExclusionWindowArgs.builder()
.duration("string")
.startTime(BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs.builder()
.hours(0)
.minutes(0)
.nanos(0)
.seconds(0)
.build())
.daily(false)
.daysOfWeek(BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs.builder()
.daysOfWeeks("string")
.build())
.singleOccurrenceDate(BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs.builder()
.day(0)
.month(0)
.year(0)
.build())
.build())
.build())
.build())
.deactivated(false)
.description("string")
.labels(Map.of("string", "string"))
.name("string")
.project("string")
.retentionPolicy(BackupPlanRetentionPolicyArgs.builder()
.backupDeleteLockDays(0)
.backupRetainDays(0)
.locked(false)
.build())
.build());
backup_plan_resource = gcp.gkebackup.BackupPlan("backupPlanResource",
cluster="string",
location="string",
backup_config=gcp.gkebackup.BackupPlanBackupConfigArgs(
all_namespaces=False,
encryption_key=gcp.gkebackup.BackupPlanBackupConfigEncryptionKeyArgs(
gcp_kms_encryption_key="string",
),
include_secrets=False,
include_volume_data=False,
permissive_mode=False,
selected_applications=gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsArgs(
namespaced_names=[gcp.gkebackup.BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs(
name="string",
namespace="string",
)],
),
selected_namespaces=gcp.gkebackup.BackupPlanBackupConfigSelectedNamespacesArgs(
namespaces=["string"],
),
),
backup_schedule=gcp.gkebackup.BackupPlanBackupScheduleArgs(
cron_schedule="string",
paused=False,
rpo_config=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigArgs(
target_rpo_minutes=0,
exclusion_windows=[gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowArgs(
duration="string",
start_time=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs(
hours=0,
minutes=0,
nanos=0,
seconds=0,
),
daily=False,
days_of_week=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs(
days_of_weeks=["string"],
),
single_occurrence_date=gcp.gkebackup.BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs(
day=0,
month=0,
year=0,
),
)],
),
),
deactivated=False,
description="string",
labels={
"string": "string",
},
name="string",
project="string",
retention_policy=gcp.gkebackup.BackupPlanRetentionPolicyArgs(
backup_delete_lock_days=0,
backup_retain_days=0,
locked=False,
))
const backupPlanResource = new gcp.gkebackup.BackupPlan("backupPlanResource", {
cluster: "string",
location: "string",
backupConfig: {
allNamespaces: false,
encryptionKey: {
gcpKmsEncryptionKey: "string",
},
includeSecrets: false,
includeVolumeData: false,
permissiveMode: false,
selectedApplications: {
namespacedNames: [{
name: "string",
namespace: "string",
}],
},
selectedNamespaces: {
namespaces: ["string"],
},
},
backupSchedule: {
cronSchedule: "string",
paused: false,
rpoConfig: {
targetRpoMinutes: 0,
exclusionWindows: [{
duration: "string",
startTime: {
hours: 0,
minutes: 0,
nanos: 0,
seconds: 0,
},
daily: false,
daysOfWeek: {
daysOfWeeks: ["string"],
},
singleOccurrenceDate: {
day: 0,
month: 0,
year: 0,
},
}],
},
},
deactivated: false,
description: "string",
labels: {
string: "string",
},
name: "string",
project: "string",
retentionPolicy: {
backupDeleteLockDays: 0,
backupRetainDays: 0,
locked: false,
},
});
type: gcp:gkebackup:BackupPlan
properties:
backupConfig:
allNamespaces: false
encryptionKey:
gcpKmsEncryptionKey: string
includeSecrets: false
includeVolumeData: false
permissiveMode: false
selectedApplications:
namespacedNames:
- name: string
namespace: string
selectedNamespaces:
namespaces:
- string
backupSchedule:
cronSchedule: string
paused: false
rpoConfig:
exclusionWindows:
- daily: false
daysOfWeek:
daysOfWeeks:
- string
duration: string
singleOccurrenceDate:
day: 0
month: 0
year: 0
startTime:
hours: 0
minutes: 0
nanos: 0
seconds: 0
targetRpoMinutes: 0
cluster: string
deactivated: false
description: string
labels:
string: string
location: string
name: string
project: string
retentionPolicy:
backupDeleteLockDays: 0
backupRetainDays: 0
locked: false
BackupPlan Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The BackupPlan resource accepts the following input properties:
- Cluster string
- The source cluster from which Backups will be created via this BackupPlan.
- Location string
- The region of the Backup Plan.
- Backup
Config BackupPlan Backup Config - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- Backup
Schedule BackupPlan Backup Schedule - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- Deactivated bool
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- Description string
- User specified descriptive string for this BackupPlan.
- Labels Dictionary<string, string>
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Name string
- The full name of the BackupPlan Resource.
- Project string
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Retention
Policy BackupPlan Retention Policy - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- Cluster string
- The source cluster from which Backups will be created via this BackupPlan.
- Location string
- The region of the Backup Plan.
- Backup
Config BackupPlan Backup Config Args - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- Backup
Schedule BackupPlan Backup Schedule Args - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- Deactivated bool
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- Description string
- User specified descriptive string for this BackupPlan.
- Labels map[string]string
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Name string
- The full name of the BackupPlan Resource.
- Project string
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Retention
Policy BackupPlan Retention Policy Args - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- cluster String
- The source cluster from which Backups will be created via this BackupPlan.
- location String
- The region of the Backup Plan.
- backup
Config BackupPlan Backup Config - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup
Schedule BackupPlan Backup Schedule - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- deactivated Boolean
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description String
- User specified descriptive string for this BackupPlan.
- labels Map<String,String>
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name String
- The full name of the BackupPlan Resource.
- project String
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- retention
Policy BackupPlan Retention Policy - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- cluster string
- The source cluster from which Backups will be created via this BackupPlan.
- location string
- The region of the Backup Plan.
- backup
Config BackupPlan Backup Config - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup
Schedule BackupPlan Backup Schedule - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- deactivated boolean
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description string
- User specified descriptive string for this BackupPlan.
- labels {[key: string]: string}
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name string
- The full name of the BackupPlan Resource.
- project string
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- retention
Policy BackupPlan Retention Policy - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- cluster str
- The source cluster from which Backups will be created via this BackupPlan.
- location str
- The region of the Backup Plan.
- backup_
config BackupPlan Backup Config Args - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup_
schedule BackupPlan Backup Schedule Args - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- deactivated bool
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description str
- User specified descriptive string for this BackupPlan.
- labels Mapping[str, str]
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name str
- The full name of the BackupPlan Resource.
- project str
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- retention_
policy BackupPlan Retention Policy Args - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- cluster String
- The source cluster from which Backups will be created via this BackupPlan.
- location String
- The region of the Backup Plan.
- backup
Config Property Map - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup
Schedule Property Map - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- deactivated Boolean
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description String
- User specified descriptive string for this BackupPlan.
- labels Map<String>
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name String
- The full name of the BackupPlan Resource.
- project String
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- retention
Policy Property Map - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
Outputs
All input properties are implicitly available as output properties. Additionally, the BackupPlan resource produces the following output properties:
- Effective
Labels Dictionary<string, string> - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Etag string
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- Protected
Pod intCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- Pulumi
Labels Dictionary<string, string> - The combination of labels configured directly on the resource and default labels configured on the provider.
- State string
- The State of the BackupPlan.
- State
Reason string - Detailed description of why BackupPlan is in its current state.
- Uid string
- Server generated, unique identifier of UUID format.
- Effective
Labels map[string]string - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Etag string
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- Protected
Pod intCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- Pulumi
Labels map[string]string - The combination of labels configured directly on the resource and default labels configured on the provider.
- State string
- The State of the BackupPlan.
- State
Reason string - Detailed description of why BackupPlan is in its current state.
- Uid string
- Server generated, unique identifier of UUID format.
- effective
Labels Map<String,String> - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag String
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- id String
- The provider-assigned unique ID for this managed resource.
- protected
Pod IntegerCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi
Labels Map<String,String> - The combination of labels configured directly on the resource and default labels configured on the provider.
- state String
- The State of the BackupPlan.
- state
Reason String - Detailed description of why BackupPlan is in its current state.
- uid String
- Server generated, unique identifier of UUID format.
- effective
Labels {[key: string]: string} - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag string
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- id string
- The provider-assigned unique ID for this managed resource.
- protected
Pod numberCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi
Labels {[key: string]: string} - The combination of labels configured directly on the resource and default labels configured on the provider.
- state string
- The State of the BackupPlan.
- state
Reason string - Detailed description of why BackupPlan is in its current state.
- uid string
- Server generated, unique identifier of UUID format.
- effective_
labels Mapping[str, str] - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag str
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- id str
- The provider-assigned unique ID for this managed resource.
- protected_
pod_ intcount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi_
labels Mapping[str, str] - The combination of labels configured directly on the resource and default labels configured on the provider.
- state str
- The State of the BackupPlan.
- state_
reason str - Detailed description of why BackupPlan is in its current state.
- uid str
- Server generated, unique identifier of UUID format.
- effective
Labels Map<String> - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag String
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- id String
- The provider-assigned unique ID for this managed resource.
- protected
Pod NumberCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi
Labels Map<String> - The combination of labels configured directly on the resource and default labels configured on the provider.
- state String
- The State of the BackupPlan.
- state
Reason String - Detailed description of why BackupPlan is in its current state.
- uid String
- Server generated, unique identifier of UUID format.
Look up Existing BackupPlan Resource
Get an existing BackupPlan resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: BackupPlanState, opts?: CustomResourceOptions): BackupPlan
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
backup_config: Optional[BackupPlanBackupConfigArgs] = None,
backup_schedule: Optional[BackupPlanBackupScheduleArgs] = None,
cluster: Optional[str] = None,
deactivated: Optional[bool] = None,
description: Optional[str] = None,
effective_labels: Optional[Mapping[str, str]] = None,
etag: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
location: Optional[str] = None,
name: Optional[str] = None,
project: Optional[str] = None,
protected_pod_count: Optional[int] = None,
pulumi_labels: Optional[Mapping[str, str]] = None,
retention_policy: Optional[BackupPlanRetentionPolicyArgs] = None,
state: Optional[str] = None,
state_reason: Optional[str] = None,
uid: Optional[str] = None) -> BackupPlan
func GetBackupPlan(ctx *Context, name string, id IDInput, state *BackupPlanState, opts ...ResourceOption) (*BackupPlan, error)
public static BackupPlan Get(string name, Input<string> id, BackupPlanState? state, CustomResourceOptions? opts = null)
public static BackupPlan get(String name, Output<String> id, BackupPlanState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Backup
Config BackupPlan Backup Config - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- Backup
Schedule BackupPlan Backup Schedule - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- Cluster string
- The source cluster from which Backups will be created via this BackupPlan.
- Deactivated bool
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- Description string
- User specified descriptive string for this BackupPlan.
- Effective
Labels Dictionary<string, string> - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Etag string
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- Labels Dictionary<string, string>
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Location string
- The region of the Backup Plan.
- Name string
- The full name of the BackupPlan Resource.
- Project string
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Protected
Pod intCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- Pulumi
Labels Dictionary<string, string> - The combination of labels configured directly on the resource and default labels configured on the provider.
- Retention
Policy BackupPlan Retention Policy - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- State string
- The State of the BackupPlan.
- State
Reason string - Detailed description of why BackupPlan is in its current state.
- Uid string
- Server generated, unique identifier of UUID format.
- Backup
Config BackupPlan Backup Config Args - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- Backup
Schedule BackupPlan Backup Schedule Args - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- Cluster string
- The source cluster from which Backups will be created via this BackupPlan.
- Deactivated bool
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- Description string
- User specified descriptive string for this BackupPlan.
- Effective
Labels map[string]string - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Etag string
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- Labels map[string]string
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Location string
- The region of the Backup Plan.
- Name string
- The full name of the BackupPlan Resource.
- Project string
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Protected
Pod intCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- Pulumi
Labels map[string]string - The combination of labels configured directly on the resource and default labels configured on the provider.
- Retention
Policy BackupPlan Retention Policy Args - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- State string
- The State of the BackupPlan.
- State
Reason string - Detailed description of why BackupPlan is in its current state.
- Uid string
- Server generated, unique identifier of UUID format.
- backup
Config BackupPlan Backup Config - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup
Schedule BackupPlan Backup Schedule - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- cluster String
- The source cluster from which Backups will be created via this BackupPlan.
- deactivated Boolean
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description String
- User specified descriptive string for this BackupPlan.
- effective
Labels Map<String,String> - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag String
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- labels Map<String,String>
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- location String
- The region of the Backup Plan.
- name String
- The full name of the BackupPlan Resource.
- project String
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- protected
Pod IntegerCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi
Labels Map<String,String> - The combination of labels configured directly on the resource and default labels configured on the provider.
- retention
Policy BackupPlan Retention Policy - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- state String
- The State of the BackupPlan.
- state
Reason String - Detailed description of why BackupPlan is in its current state.
- uid String
- Server generated, unique identifier of UUID format.
- backup
Config BackupPlan Backup Config - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup
Schedule BackupPlan Backup Schedule - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- cluster string
- The source cluster from which Backups will be created via this BackupPlan.
- deactivated boolean
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description string
- User specified descriptive string for this BackupPlan.
- effective
Labels {[key: string]: string} - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag string
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- labels {[key: string]: string}
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- location string
- The region of the Backup Plan.
- name string
- The full name of the BackupPlan Resource.
- project string
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- protected
Pod numberCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi
Labels {[key: string]: string} - The combination of labels configured directly on the resource and default labels configured on the provider.
- retention
Policy BackupPlan Retention Policy - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- state string
- The State of the BackupPlan.
- state
Reason string - Detailed description of why BackupPlan is in its current state.
- uid string
- Server generated, unique identifier of UUID format.
- backup_
config BackupPlan Backup Config Args - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup_
schedule BackupPlan Backup Schedule Args - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- cluster str
- The source cluster from which Backups will be created via this BackupPlan.
- deactivated bool
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description str
- User specified descriptive string for this BackupPlan.
- effective_
labels Mapping[str, str] - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag str
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- labels Mapping[str, str]
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- location str
- The region of the Backup Plan.
- name str
- The full name of the BackupPlan Resource.
- project str
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- protected_
pod_ intcount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi_
labels Mapping[str, str] - The combination of labels configured directly on the resource and default labels configured on the provider.
- retention_
policy BackupPlan Retention Policy Args - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- state str
- The State of the BackupPlan.
- state_
reason str - Detailed description of why BackupPlan is in its current state.
- uid str
- Server generated, unique identifier of UUID format.
- backup
Config Property Map - Defines the configuration of Backups created via this BackupPlan. Structure is documented below.
- backup
Schedule Property Map - Defines a schedule for automatic Backup creation via this BackupPlan. Structure is documented below.
- cluster String
- The source cluster from which Backups will be created via this BackupPlan.
- deactivated Boolean
- This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).
- description String
- User specified descriptive string for this BackupPlan.
- effective
Labels Map<String> - All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- etag String
- etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to backupPlans.get, and systems are expected to put that etag in the request to backupPlans.patch or backupPlans.delete to ensure that their change will be applied to the same version of the resource.
- labels Map<String>
Description: A set of custom labels supplied by the user. A list of key->value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- location String
- The region of the Backup Plan.
- name String
- The full name of the BackupPlan Resource.
- project String
- The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- protected
Pod NumberCount - The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.
- pulumi
Labels Map<String> - The combination of labels configured directly on the resource and default labels configured on the provider.
- retention
Policy Property Map - RetentionPolicy governs lifecycle of Backups created under this plan. Structure is documented below.
- state String
- The State of the BackupPlan.
- state
Reason String - Detailed description of why BackupPlan is in its current state.
- uid String
- Server generated, unique identifier of UUID format.
Supporting Types
BackupPlanBackupConfig, BackupPlanBackupConfigArgs
- All
Namespaces bool - If True, include all namespaced resources.
- Encryption
Key BackupPlan Backup Config Encryption Key - This defines a customer managed encryption key that will be used to encrypt the "config" portion (the Kubernetes resources) of Backups created via this plan. Structure is documented below.
- Include
Secrets bool - This flag specifies whether Kubernetes Secret resources should be included when they fall into the scope of Backups.
- Include
Volume boolData - This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup.
- Permissive
Mode bool - This flag specifies whether Backups will not fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore.
- Selected
Applications BackupPlan Backup Config Selected Applications - A list of namespaced Kubernetes Resources. Structure is documented below.
- Selected
Namespaces BackupPlan Backup Config Selected Namespaces - If set, include just the resources in the listed namespaces. Structure is documented below.
- All
Namespaces bool - If True, include all namespaced resources.
- Encryption
Key BackupPlan Backup Config Encryption Key - This defines a customer managed encryption key that will be used to encrypt the "config" portion (the Kubernetes resources) of Backups created via this plan. Structure is documented below.
- Include
Secrets bool - This flag specifies whether Kubernetes Secret resources should be included when they fall into the scope of Backups.
- Include
Volume boolData - This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup.
- Permissive
Mode bool - This flag specifies whether Backups will not fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore.
- Selected
Applications BackupPlan Backup Config Selected Applications - A list of namespaced Kubernetes Resources. Structure is documented below.
- Selected
Namespaces BackupPlan Backup Config Selected Namespaces - If set, include just the resources in the listed namespaces. Structure is documented below.
- all
Namespaces Boolean - If True, include all namespaced resources.
- encryption
Key BackupPlan Backup Config Encryption Key - This defines a customer managed encryption key that will be used to encrypt the "config" portion (the Kubernetes resources) of Backups created via this plan. Structure is documented below.
- include
Secrets Boolean - This flag specifies whether Kubernetes Secret resources should be included when they fall into the scope of Backups.
- include
Volume BooleanData - This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup.
- permissive
Mode Boolean - This flag specifies whether Backups will not fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore.
- selected
Applications BackupPlan Backup Config Selected Applications - A list of namespaced Kubernetes Resources. Structure is documented below.
- selected
Namespaces BackupPlan Backup Config Selected Namespaces - If set, include just the resources in the listed namespaces. Structure is documented below.
- all
Namespaces boolean - If True, include all namespaced resources.
- encryption
Key BackupPlan Backup Config Encryption Key - This defines a customer managed encryption key that will be used to encrypt the "config" portion (the Kubernetes resources) of Backups created via this plan. Structure is documented below.
- include
Secrets boolean - This flag specifies whether Kubernetes Secret resources should be included when they fall into the scope of Backups.
- include
Volume booleanData - This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup.
- permissive
Mode boolean - This flag specifies whether Backups will not fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore.
- selected
Applications BackupPlan Backup Config Selected Applications - A list of namespaced Kubernetes Resources. Structure is documented below.
- selected
Namespaces BackupPlan Backup Config Selected Namespaces - If set, include just the resources in the listed namespaces. Structure is documented below.
- all_
namespaces bool - If True, include all namespaced resources.
- encryption_
key BackupPlan Backup Config Encryption Key - This defines a customer managed encryption key that will be used to encrypt the "config" portion (the Kubernetes resources) of Backups created via this plan. Structure is documented below.
- include_
secrets bool - This flag specifies whether Kubernetes Secret resources should be included when they fall into the scope of Backups.
- include_
volume_ booldata - This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup.
- permissive_
mode bool - This flag specifies whether Backups will not fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore.
- selected_
applications BackupPlan Backup Config Selected Applications - A list of namespaced Kubernetes Resources. Structure is documented below.
- selected_
namespaces BackupPlan Backup Config Selected Namespaces - If set, include just the resources in the listed namespaces. Structure is documented below.
- all
Namespaces Boolean - If True, include all namespaced resources.
- encryption
Key Property Map - This defines a customer managed encryption key that will be used to encrypt the "config" portion (the Kubernetes resources) of Backups created via this plan. Structure is documented below.
- include
Secrets Boolean - This flag specifies whether Kubernetes Secret resources should be included when they fall into the scope of Backups.
- include
Volume BooleanData - This flag specifies whether volume data should be backed up when PVCs are included in the scope of a Backup.
- permissive
Mode Boolean - This flag specifies whether Backups will not fail when Backup for GKE detects Kubernetes configuration that is non-standard or requires additional setup to restore.
- selected
Applications Property Map - A list of namespaced Kubernetes Resources. Structure is documented below.
- selected
Namespaces Property Map - If set, include just the resources in the listed namespaces. Structure is documented below.
BackupPlanBackupConfigEncryptionKey, BackupPlanBackupConfigEncryptionKeyArgs
- Gcp
Kms stringEncryption Key - Google Cloud KMS encryption key. Format: projects//locations//keyRings//cryptoKeys/
- Gcp
Kms stringEncryption Key - Google Cloud KMS encryption key. Format: projects//locations//keyRings//cryptoKeys/
- gcp
Kms StringEncryption Key - Google Cloud KMS encryption key. Format: projects//locations//keyRings//cryptoKeys/
- gcp
Kms stringEncryption Key - Google Cloud KMS encryption key. Format: projects//locations//keyRings//cryptoKeys/
- gcp_
kms_ strencryption_ key - Google Cloud KMS encryption key. Format: projects//locations//keyRings//cryptoKeys/
- gcp
Kms StringEncryption Key - Google Cloud KMS encryption key. Format: projects//locations//keyRings//cryptoKeys/
BackupPlanBackupConfigSelectedApplications, BackupPlanBackupConfigSelectedApplicationsArgs
- Namespaced
Names List<BackupPlan Backup Config Selected Applications Namespaced Name> - A list of namespaced Kubernetes resources. Structure is documented below.
- Namespaced
Names []BackupPlan Backup Config Selected Applications Namespaced Name - A list of namespaced Kubernetes resources. Structure is documented below.
- namespaced
Names List<BackupPlan Backup Config Selected Applications Namespaced Name> - A list of namespaced Kubernetes resources. Structure is documented below.
- namespaced
Names BackupPlan Backup Config Selected Applications Namespaced Name[] - A list of namespaced Kubernetes resources. Structure is documented below.
- namespaced_
names Sequence[BackupPlan Backup Config Selected Applications Namespaced Name] - A list of namespaced Kubernetes resources. Structure is documented below.
- namespaced
Names List<Property Map> - A list of namespaced Kubernetes resources. Structure is documented below.
BackupPlanBackupConfigSelectedApplicationsNamespacedName, BackupPlanBackupConfigSelectedApplicationsNamespacedNameArgs
BackupPlanBackupConfigSelectedNamespaces, BackupPlanBackupConfigSelectedNamespacesArgs
- Namespaces List<string>
- A list of Kubernetes Namespaces.
- Namespaces []string
- A list of Kubernetes Namespaces.
- namespaces List<String>
- A list of Kubernetes Namespaces.
- namespaces string[]
- A list of Kubernetes Namespaces.
- namespaces Sequence[str]
- A list of Kubernetes Namespaces.
- namespaces List<String>
- A list of Kubernetes Namespaces.
BackupPlanBackupSchedule, BackupPlanBackupScheduleArgs
- Cron
Schedule string - A standard cron string that defines a repeating schedule for creating Backups via this BackupPlan. This is mutually exclusive with the rpoConfig field since at most one schedule can be defined for a BackupPlan. If this is defined, then backupRetainDays must also be defined.
- Paused bool
- This flag denotes whether automatic Backup creation is paused for this BackupPlan.
- Rpo
Config BackupPlan Backup Schedule Rpo Config - Defines the RPO schedule configuration for this BackupPlan. This is mutually exclusive with the cronSchedule field since at most one schedule can be defined for a BackupPLan. If this is defined, then backupRetainDays must also be defined. Structure is documented below.
- Cron
Schedule string - A standard cron string that defines a repeating schedule for creating Backups via this BackupPlan. This is mutually exclusive with the rpoConfig field since at most one schedule can be defined for a BackupPlan. If this is defined, then backupRetainDays must also be defined.
- Paused bool
- This flag denotes whether automatic Backup creation is paused for this BackupPlan.
- Rpo
Config BackupPlan Backup Schedule Rpo Config - Defines the RPO schedule configuration for this BackupPlan. This is mutually exclusive with the cronSchedule field since at most one schedule can be defined for a BackupPLan. If this is defined, then backupRetainDays must also be defined. Structure is documented below.
- cron
Schedule String - A standard cron string that defines a repeating schedule for creating Backups via this BackupPlan. This is mutually exclusive with the rpoConfig field since at most one schedule can be defined for a BackupPlan. If this is defined, then backupRetainDays must also be defined.
- paused Boolean
- This flag denotes whether automatic Backup creation is paused for this BackupPlan.
- rpo
Config BackupPlan Backup Schedule Rpo Config - Defines the RPO schedule configuration for this BackupPlan. This is mutually exclusive with the cronSchedule field since at most one schedule can be defined for a BackupPLan. If this is defined, then backupRetainDays must also be defined. Structure is documented below.
- cron
Schedule string - A standard cron string that defines a repeating schedule for creating Backups via this BackupPlan. This is mutually exclusive with the rpoConfig field since at most one schedule can be defined for a BackupPlan. If this is defined, then backupRetainDays must also be defined.
- paused boolean
- This flag denotes whether automatic Backup creation is paused for this BackupPlan.
- rpo
Config BackupPlan Backup Schedule Rpo Config - Defines the RPO schedule configuration for this BackupPlan. This is mutually exclusive with the cronSchedule field since at most one schedule can be defined for a BackupPLan. If this is defined, then backupRetainDays must also be defined. Structure is documented below.
- cron_
schedule str - A standard cron string that defines a repeating schedule for creating Backups via this BackupPlan. This is mutually exclusive with the rpoConfig field since at most one schedule can be defined for a BackupPlan. If this is defined, then backupRetainDays must also be defined.
- paused bool
- This flag denotes whether automatic Backup creation is paused for this BackupPlan.
- rpo_
config BackupPlan Backup Schedule Rpo Config - Defines the RPO schedule configuration for this BackupPlan. This is mutually exclusive with the cronSchedule field since at most one schedule can be defined for a BackupPLan. If this is defined, then backupRetainDays must also be defined. Structure is documented below.
- cron
Schedule String - A standard cron string that defines a repeating schedule for creating Backups via this BackupPlan. This is mutually exclusive with the rpoConfig field since at most one schedule can be defined for a BackupPlan. If this is defined, then backupRetainDays must also be defined.
- paused Boolean
- This flag denotes whether automatic Backup creation is paused for this BackupPlan.
- rpo
Config Property Map - Defines the RPO schedule configuration for this BackupPlan. This is mutually exclusive with the cronSchedule field since at most one schedule can be defined for a BackupPLan. If this is defined, then backupRetainDays must also be defined. Structure is documented below.
BackupPlanBackupScheduleRpoConfig, BackupPlanBackupScheduleRpoConfigArgs
- Target
Rpo intMinutes - Defines the target RPO for the BackupPlan in minutes, which means the target maximum data loss in time that is acceptable for this BackupPlan. This must be at least 60, i.e., 1 hour, and at most 86400, i.e., 60 days.
- Exclusion
Windows List<BackupPlan Backup Schedule Rpo Config Exclusion Window> - User specified time windows during which backup can NOT happen for this BackupPlan. Backups should start and finish outside of any given exclusion window. Note: backup jobs will be scheduled to start and finish outside the duration of the window as much as possible, but running jobs will not get canceled when it runs into the window. All the time and date values in exclusionWindows entry in the API are in UTC. We only allow <=1 recurrence (daily or weekly) exclusion window for a BackupPlan while no restriction on number of single occurrence windows. Structure is documented below.
- Target
Rpo intMinutes - Defines the target RPO for the BackupPlan in minutes, which means the target maximum data loss in time that is acceptable for this BackupPlan. This must be at least 60, i.e., 1 hour, and at most 86400, i.e., 60 days.
- Exclusion
Windows []BackupPlan Backup Schedule Rpo Config Exclusion Window - User specified time windows during which backup can NOT happen for this BackupPlan. Backups should start and finish outside of any given exclusion window. Note: backup jobs will be scheduled to start and finish outside the duration of the window as much as possible, but running jobs will not get canceled when it runs into the window. All the time and date values in exclusionWindows entry in the API are in UTC. We only allow <=1 recurrence (daily or weekly) exclusion window for a BackupPlan while no restriction on number of single occurrence windows. Structure is documented below.
- target
Rpo IntegerMinutes - Defines the target RPO for the BackupPlan in minutes, which means the target maximum data loss in time that is acceptable for this BackupPlan. This must be at least 60, i.e., 1 hour, and at most 86400, i.e., 60 days.
- exclusion
Windows List<BackupPlan Backup Schedule Rpo Config Exclusion Window> - User specified time windows during which backup can NOT happen for this BackupPlan. Backups should start and finish outside of any given exclusion window. Note: backup jobs will be scheduled to start and finish outside the duration of the window as much as possible, but running jobs will not get canceled when it runs into the window. All the time and date values in exclusionWindows entry in the API are in UTC. We only allow <=1 recurrence (daily or weekly) exclusion window for a BackupPlan while no restriction on number of single occurrence windows. Structure is documented below.
- target
Rpo numberMinutes - Defines the target RPO for the BackupPlan in minutes, which means the target maximum data loss in time that is acceptable for this BackupPlan. This must be at least 60, i.e., 1 hour, and at most 86400, i.e., 60 days.
- exclusion
Windows BackupPlan Backup Schedule Rpo Config Exclusion Window[] - User specified time windows during which backup can NOT happen for this BackupPlan. Backups should start and finish outside of any given exclusion window. Note: backup jobs will be scheduled to start and finish outside the duration of the window as much as possible, but running jobs will not get canceled when it runs into the window. All the time and date values in exclusionWindows entry in the API are in UTC. We only allow <=1 recurrence (daily or weekly) exclusion window for a BackupPlan while no restriction on number of single occurrence windows. Structure is documented below.
- target_
rpo_ intminutes - Defines the target RPO for the BackupPlan in minutes, which means the target maximum data loss in time that is acceptable for this BackupPlan. This must be at least 60, i.e., 1 hour, and at most 86400, i.e., 60 days.
- exclusion_
windows Sequence[BackupPlan Backup Schedule Rpo Config Exclusion Window] - User specified time windows during which backup can NOT happen for this BackupPlan. Backups should start and finish outside of any given exclusion window. Note: backup jobs will be scheduled to start and finish outside the duration of the window as much as possible, but running jobs will not get canceled when it runs into the window. All the time and date values in exclusionWindows entry in the API are in UTC. We only allow <=1 recurrence (daily or weekly) exclusion window for a BackupPlan while no restriction on number of single occurrence windows. Structure is documented below.
- target
Rpo NumberMinutes - Defines the target RPO for the BackupPlan in minutes, which means the target maximum data loss in time that is acceptable for this BackupPlan. This must be at least 60, i.e., 1 hour, and at most 86400, i.e., 60 days.
- exclusion
Windows List<Property Map> - User specified time windows during which backup can NOT happen for this BackupPlan. Backups should start and finish outside of any given exclusion window. Note: backup jobs will be scheduled to start and finish outside the duration of the window as much as possible, but running jobs will not get canceled when it runs into the window. All the time and date values in exclusionWindows entry in the API are in UTC. We only allow <=1 recurrence (daily or weekly) exclusion window for a BackupPlan while no restriction on number of single occurrence windows. Structure is documented below.
BackupPlanBackupScheduleRpoConfigExclusionWindow, BackupPlanBackupScheduleRpoConfigExclusionWindowArgs
- Duration string
- Specifies duration of the window in seconds with up to nine fractional digits,
terminated by 's'. Example: "3.5s". Restrictions for duration based on the
recurrence type to allow some time for backup to happen:
- single_occurrence_date: no restriction
- daily window: duration < 24 hours
- weekly window:
- days of week includes all seven days of a week: duration < 24 hours
- all other weekly window: duration < 168 hours (i.e., 24 * 7 hours)
- Start
Time BackupPlan Backup Schedule Rpo Config Exclusion Window Start Time - Specifies the start time of the window using time of the day in UTC. Structure is documented below.
- Daily bool
- The exclusion window occurs every day if set to "True". Specifying this field to "False" is an error. Only one of singleOccurrenceDate, daily and daysOfWeek may be set.
- Days
Of BackupWeek Plan Backup Schedule Rpo Config Exclusion Window Days Of Week - The exclusion window occurs on these days of each week in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- Single
Occurrence BackupDate Plan Backup Schedule Rpo Config Exclusion Window Single Occurrence Date - No recurrence. The exclusion window occurs only once and on this date in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- Duration string
- Specifies duration of the window in seconds with up to nine fractional digits,
terminated by 's'. Example: "3.5s". Restrictions for duration based on the
recurrence type to allow some time for backup to happen:
- single_occurrence_date: no restriction
- daily window: duration < 24 hours
- weekly window:
- days of week includes all seven days of a week: duration < 24 hours
- all other weekly window: duration < 168 hours (i.e., 24 * 7 hours)
- Start
Time BackupPlan Backup Schedule Rpo Config Exclusion Window Start Time - Specifies the start time of the window using time of the day in UTC. Structure is documented below.
- Daily bool
- The exclusion window occurs every day if set to "True". Specifying this field to "False" is an error. Only one of singleOccurrenceDate, daily and daysOfWeek may be set.
- Days
Of BackupWeek Plan Backup Schedule Rpo Config Exclusion Window Days Of Week - The exclusion window occurs on these days of each week in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- Single
Occurrence BackupDate Plan Backup Schedule Rpo Config Exclusion Window Single Occurrence Date - No recurrence. The exclusion window occurs only once and on this date in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- duration String
- Specifies duration of the window in seconds with up to nine fractional digits,
terminated by 's'. Example: "3.5s". Restrictions for duration based on the
recurrence type to allow some time for backup to happen:
- single_occurrence_date: no restriction
- daily window: duration < 24 hours
- weekly window:
- days of week includes all seven days of a week: duration < 24 hours
- all other weekly window: duration < 168 hours (i.e., 24 * 7 hours)
- start
Time BackupPlan Backup Schedule Rpo Config Exclusion Window Start Time - Specifies the start time of the window using time of the day in UTC. Structure is documented below.
- daily Boolean
- The exclusion window occurs every day if set to "True". Specifying this field to "False" is an error. Only one of singleOccurrenceDate, daily and daysOfWeek may be set.
- days
Of BackupWeek Plan Backup Schedule Rpo Config Exclusion Window Days Of Week - The exclusion window occurs on these days of each week in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- single
Occurrence BackupDate Plan Backup Schedule Rpo Config Exclusion Window Single Occurrence Date - No recurrence. The exclusion window occurs only once and on this date in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- duration string
- Specifies duration of the window in seconds with up to nine fractional digits,
terminated by 's'. Example: "3.5s". Restrictions for duration based on the
recurrence type to allow some time for backup to happen:
- single_occurrence_date: no restriction
- daily window: duration < 24 hours
- weekly window:
- days of week includes all seven days of a week: duration < 24 hours
- all other weekly window: duration < 168 hours (i.e., 24 * 7 hours)
- start
Time BackupPlan Backup Schedule Rpo Config Exclusion Window Start Time - Specifies the start time of the window using time of the day in UTC. Structure is documented below.
- daily boolean
- The exclusion window occurs every day if set to "True". Specifying this field to "False" is an error. Only one of singleOccurrenceDate, daily and daysOfWeek may be set.
- days
Of BackupWeek Plan Backup Schedule Rpo Config Exclusion Window Days Of Week - The exclusion window occurs on these days of each week in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- single
Occurrence BackupDate Plan Backup Schedule Rpo Config Exclusion Window Single Occurrence Date - No recurrence. The exclusion window occurs only once and on this date in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- duration str
- Specifies duration of the window in seconds with up to nine fractional digits,
terminated by 's'. Example: "3.5s". Restrictions for duration based on the
recurrence type to allow some time for backup to happen:
- single_occurrence_date: no restriction
- daily window: duration < 24 hours
- weekly window:
- days of week includes all seven days of a week: duration < 24 hours
- all other weekly window: duration < 168 hours (i.e., 24 * 7 hours)
- start_
time BackupPlan Backup Schedule Rpo Config Exclusion Window Start Time - Specifies the start time of the window using time of the day in UTC. Structure is documented below.
- daily bool
- The exclusion window occurs every day if set to "True". Specifying this field to "False" is an error. Only one of singleOccurrenceDate, daily and daysOfWeek may be set.
- days_
of_ Backupweek Plan Backup Schedule Rpo Config Exclusion Window Days Of Week - The exclusion window occurs on these days of each week in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- single_
occurrence_ Backupdate Plan Backup Schedule Rpo Config Exclusion Window Single Occurrence Date - No recurrence. The exclusion window occurs only once and on this date in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- duration String
- Specifies duration of the window in seconds with up to nine fractional digits,
terminated by 's'. Example: "3.5s". Restrictions for duration based on the
recurrence type to allow some time for backup to happen:
- single_occurrence_date: no restriction
- daily window: duration < 24 hours
- weekly window:
- days of week includes all seven days of a week: duration < 24 hours
- all other weekly window: duration < 168 hours (i.e., 24 * 7 hours)
- start
Time Property Map - Specifies the start time of the window using time of the day in UTC. Structure is documented below.
- daily Boolean
- The exclusion window occurs every day if set to "True". Specifying this field to "False" is an error. Only one of singleOccurrenceDate, daily and daysOfWeek may be set.
- days
Of Property MapWeek - The exclusion window occurs on these days of each week in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
- single
Occurrence Property MapDate - No recurrence. The exclusion window occurs only once and on this date in UTC. Only one of singleOccurrenceDate, daily and daysOfWeek may be set. Structure is documented below.
BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeek, BackupPlanBackupScheduleRpoConfigExclusionWindowDaysOfWeekArgs
- Days
Of List<string>Weeks - A list of days of week.
Each value may be one of:
MONDAY
,TUESDAY
,WEDNESDAY
,THURSDAY
,FRIDAY
,SATURDAY
,SUNDAY
.
- Days
Of []stringWeeks - A list of days of week.
Each value may be one of:
MONDAY
,TUESDAY
,WEDNESDAY
,THURSDAY
,FRIDAY
,SATURDAY
,SUNDAY
.
- days
Of List<String>Weeks - A list of days of week.
Each value may be one of:
MONDAY
,TUESDAY
,WEDNESDAY
,THURSDAY
,FRIDAY
,SATURDAY
,SUNDAY
.
- days
Of string[]Weeks - A list of days of week.
Each value may be one of:
MONDAY
,TUESDAY
,WEDNESDAY
,THURSDAY
,FRIDAY
,SATURDAY
,SUNDAY
.
- days_
of_ Sequence[str]weeks - A list of days of week.
Each value may be one of:
MONDAY
,TUESDAY
,WEDNESDAY
,THURSDAY
,FRIDAY
,SATURDAY
,SUNDAY
.
- days
Of List<String>Weeks - A list of days of week.
Each value may be one of:
MONDAY
,TUESDAY
,WEDNESDAY
,THURSDAY
,FRIDAY
,SATURDAY
,SUNDAY
.
BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDate, BackupPlanBackupScheduleRpoConfigExclusionWindowSingleOccurrenceDateArgs
BackupPlanBackupScheduleRpoConfigExclusionWindowStartTime, BackupPlanBackupScheduleRpoConfigExclusionWindowStartTimeArgs
BackupPlanRetentionPolicy, BackupPlanRetentionPolicyArgs
- Backup
Delete intLock Days - Minimum age for a Backup created via this BackupPlan (in days). Must be an integer value between 0-90 (inclusive). A Backup created under this BackupPlan will not be deletable until it reaches Backup's (create time + backup_delete_lock_days). Updating this field of a BackupPlan does not affect existing Backups. Backups created after a successful update will inherit this new value.
- Backup
Retain intDays - The default maximum age of a Backup created via this BackupPlan. This field MUST be an integer value >= 0 and <= 365. If specified, a Backup created under this BackupPlan will be automatically deleted after its age reaches (createTime + backupRetainDays). If not specified, Backups created under this BackupPlan will NOT be subject to automatic deletion. Updating this field does NOT affect existing Backups under it. Backups created AFTER a successful update will automatically pick up the new value. NOTE: backupRetainDays must be >= backupDeleteLockDays. If cronSchedule is defined, then this must be <= 360 * the creation interval. If rpo_config is defined, then this must be <= 360 * targetRpoMinutes/(1440minutes/day)
- Locked bool
- This flag denotes whether the retention policy of this BackupPlan is locked. If set to True, no further update is allowed on this policy, including the locked field itself.
- Backup
Delete intLock Days - Minimum age for a Backup created via this BackupPlan (in days). Must be an integer value between 0-90 (inclusive). A Backup created under this BackupPlan will not be deletable until it reaches Backup's (create time + backup_delete_lock_days). Updating this field of a BackupPlan does not affect existing Backups. Backups created after a successful update will inherit this new value.
- Backup
Retain intDays - The default maximum age of a Backup created via this BackupPlan. This field MUST be an integer value >= 0 and <= 365. If specified, a Backup created under this BackupPlan will be automatically deleted after its age reaches (createTime + backupRetainDays). If not specified, Backups created under this BackupPlan will NOT be subject to automatic deletion. Updating this field does NOT affect existing Backups under it. Backups created AFTER a successful update will automatically pick up the new value. NOTE: backupRetainDays must be >= backupDeleteLockDays. If cronSchedule is defined, then this must be <= 360 * the creation interval. If rpo_config is defined, then this must be <= 360 * targetRpoMinutes/(1440minutes/day)
- Locked bool
- This flag denotes whether the retention policy of this BackupPlan is locked. If set to True, no further update is allowed on this policy, including the locked field itself.
- backup
Delete IntegerLock Days - Minimum age for a Backup created via this BackupPlan (in days). Must be an integer value between 0-90 (inclusive). A Backup created under this BackupPlan will not be deletable until it reaches Backup's (create time + backup_delete_lock_days). Updating this field of a BackupPlan does not affect existing Backups. Backups created after a successful update will inherit this new value.
- backup
Retain IntegerDays - The default maximum age of a Backup created via this BackupPlan. This field MUST be an integer value >= 0 and <= 365. If specified, a Backup created under this BackupPlan will be automatically deleted after its age reaches (createTime + backupRetainDays). If not specified, Backups created under this BackupPlan will NOT be subject to automatic deletion. Updating this field does NOT affect existing Backups under it. Backups created AFTER a successful update will automatically pick up the new value. NOTE: backupRetainDays must be >= backupDeleteLockDays. If cronSchedule is defined, then this must be <= 360 * the creation interval. If rpo_config is defined, then this must be <= 360 * targetRpoMinutes/(1440minutes/day)
- locked Boolean
- This flag denotes whether the retention policy of this BackupPlan is locked. If set to True, no further update is allowed on this policy, including the locked field itself.
- backup
Delete numberLock Days - Minimum age for a Backup created via this BackupPlan (in days). Must be an integer value between 0-90 (inclusive). A Backup created under this BackupPlan will not be deletable until it reaches Backup's (create time + backup_delete_lock_days). Updating this field of a BackupPlan does not affect existing Backups. Backups created after a successful update will inherit this new value.
- backup
Retain numberDays - The default maximum age of a Backup created via this BackupPlan. This field MUST be an integer value >= 0 and <= 365. If specified, a Backup created under this BackupPlan will be automatically deleted after its age reaches (createTime + backupRetainDays). If not specified, Backups created under this BackupPlan will NOT be subject to automatic deletion. Updating this field does NOT affect existing Backups under it. Backups created AFTER a successful update will automatically pick up the new value. NOTE: backupRetainDays must be >= backupDeleteLockDays. If cronSchedule is defined, then this must be <= 360 * the creation interval. If rpo_config is defined, then this must be <= 360 * targetRpoMinutes/(1440minutes/day)
- locked boolean
- This flag denotes whether the retention policy of this BackupPlan is locked. If set to True, no further update is allowed on this policy, including the locked field itself.
- backup_
delete_ intlock_ days - Minimum age for a Backup created via this BackupPlan (in days). Must be an integer value between 0-90 (inclusive). A Backup created under this BackupPlan will not be deletable until it reaches Backup's (create time + backup_delete_lock_days). Updating this field of a BackupPlan does not affect existing Backups. Backups created after a successful update will inherit this new value.
- backup_
retain_ intdays - The default maximum age of a Backup created via this BackupPlan. This field MUST be an integer value >= 0 and <= 365. If specified, a Backup created under this BackupPlan will be automatically deleted after its age reaches (createTime + backupRetainDays). If not specified, Backups created under this BackupPlan will NOT be subject to automatic deletion. Updating this field does NOT affect existing Backups under it. Backups created AFTER a successful update will automatically pick up the new value. NOTE: backupRetainDays must be >= backupDeleteLockDays. If cronSchedule is defined, then this must be <= 360 * the creation interval. If rpo_config is defined, then this must be <= 360 * targetRpoMinutes/(1440minutes/day)
- locked bool
- This flag denotes whether the retention policy of this BackupPlan is locked. If set to True, no further update is allowed on this policy, including the locked field itself.
- backup
Delete NumberLock Days - Minimum age for a Backup created via this BackupPlan (in days). Must be an integer value between 0-90 (inclusive). A Backup created under this BackupPlan will not be deletable until it reaches Backup's (create time + backup_delete_lock_days). Updating this field of a BackupPlan does not affect existing Backups. Backups created after a successful update will inherit this new value.
- backup
Retain NumberDays - The default maximum age of a Backup created via this BackupPlan. This field MUST be an integer value >= 0 and <= 365. If specified, a Backup created under this BackupPlan will be automatically deleted after its age reaches (createTime + backupRetainDays). If not specified, Backups created under this BackupPlan will NOT be subject to automatic deletion. Updating this field does NOT affect existing Backups under it. Backups created AFTER a successful update will automatically pick up the new value. NOTE: backupRetainDays must be >= backupDeleteLockDays. If cronSchedule is defined, then this must be <= 360 * the creation interval. If rpo_config is defined, then this must be <= 360 * targetRpoMinutes/(1440minutes/day)
- locked Boolean
- This flag denotes whether the retention policy of this BackupPlan is locked. If set to True, no further update is allowed on this policy, including the locked field itself.
Import
BackupPlan can be imported using any of these accepted formats:
projects/{{project}}/locations/{{location}}/backupPlans/{{name}}
{{project}}/{{location}}/{{name}}
{{location}}/{{name}}
When using the pulumi import
command, BackupPlan can be imported using one of the formats above. For example:
$ pulumi import gcp:gkebackup/backupPlan:BackupPlan default projects/{{project}}/locations/{{location}}/backupPlans/{{name}}
$ pulumi import gcp:gkebackup/backupPlan:BackupPlan default {{project}}/{{location}}/{{name}}
$ pulumi import gcp:gkebackup/backupPlan:BackupPlan default {{location}}/{{name}}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
google-beta
Terraform Provider.