Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.gcp.gkebackup.kotlin
import com.pulumi.gcp.gkebackup.GkebackupFunctions.getBackupPlanIamPolicyPlain
import com.pulumi.gcp.gkebackup.GkebackupFunctions.getRestorePlanIamPolicyPlain
import com.pulumi.gcp.gkebackup.kotlin.inputs.GetBackupPlanIamPolicyPlainArgs
import com.pulumi.gcp.gkebackup.kotlin.inputs.GetBackupPlanIamPolicyPlainArgsBuilder
import com.pulumi.gcp.gkebackup.kotlin.inputs.GetRestorePlanIamPolicyPlainArgs
import com.pulumi.gcp.gkebackup.kotlin.inputs.GetRestorePlanIamPolicyPlainArgsBuilder
import com.pulumi.gcp.gkebackup.kotlin.outputs.GetBackupPlanIamPolicyResult
import com.pulumi.gcp.gkebackup.kotlin.outputs.GetRestorePlanIamPolicyResult
import kotlinx.coroutines.future.await
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import com.pulumi.gcp.gkebackup.kotlin.outputs.GetBackupPlanIamPolicyResult.Companion.toKotlin as getBackupPlanIamPolicyResultToKotlin
import com.pulumi.gcp.gkebackup.kotlin.outputs.GetRestorePlanIamPolicyResult.Companion.toKotlin as getRestorePlanIamPolicyResultToKotlin
public object GkebackupFunctions {
/**
* Retrieves the current IAM policy data for backupplan
* ## example
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
* const policy = gcp.gkebackup.getBackupPlanIamPolicy({
* project: basic.project,
* location: basic.location,
* name: basic.name,
* });
* ```
* ```python
* import pulumi
* import pulumi_gcp as gcp
* policy = gcp.gkebackup.get_backup_plan_iam_policy(project=basic["project"],
* location=basic["location"],
* name=basic["name"])
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Gcp = Pulumi.Gcp;
* return await Deployment.RunAsync(() =>
* {
* var policy = Gcp.GkeBackup.GetBackupPlanIamPolicy.Invoke(new()
* {
* Project = basic.Project,
* Location = basic.Location,
* Name = basic.Name,
* });
* });
* ```
* ```go
* package main
* import (
* "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 {
* _, err := gkebackup.LookupBackupPlanIamPolicy(ctx, &gkebackup.LookupBackupPlanIamPolicyArgs{
* Project: pulumi.StringRef(basic.Project),
* Location: pulumi.StringRef(basic.Location),
* Name: basic.Name,
* }, nil)
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.gcp.gkebackup.GkebackupFunctions;
* import com.pulumi.gcp.gkebackup.inputs.GetBackupPlanIamPolicyArgs;
* 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) {
* final var policy = GkebackupFunctions.getBackupPlanIamPolicy(GetBackupPlanIamPolicyArgs.builder()
* .project(basic.project())
* .location(basic.location())
* .name(basic.name())
* .build());
* }
* }
* ```
* ```yaml
* variables:
* policy:
* fn::invoke:
* Function: gcp:gkebackup:getBackupPlanIamPolicy
* Arguments:
* project: ${basic.project}
* location: ${basic.location}
* name: ${basic.name}
* ```
*
* @param argument A collection of arguments for invoking getBackupPlanIamPolicy.
* @return A collection of values returned by getBackupPlanIamPolicy.
*/
public suspend fun getBackupPlanIamPolicy(argument: GetBackupPlanIamPolicyPlainArgs): GetBackupPlanIamPolicyResult =
getBackupPlanIamPolicyResultToKotlin(getBackupPlanIamPolicyPlain(argument.toJava()).await())
/**
* @see [getBackupPlanIamPolicy].
* @param location The region of the Backup Plan.
* Used to find the parent resource to bind the IAM policy to. If not specified,
* the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
* location is specified, it is taken from the provider configuration.
* @param name Used to find the parent resource to bind the IAM policy to
* @param project The ID of the project in which the resource belongs.
* If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
* @return A collection of values returned by getBackupPlanIamPolicy.
*/
public suspend fun getBackupPlanIamPolicy(
location: String? = null,
name: String,
project: String? = null,
): GetBackupPlanIamPolicyResult {
val argument = GetBackupPlanIamPolicyPlainArgs(
location = location,
name = name,
project = project,
)
return getBackupPlanIamPolicyResultToKotlin(getBackupPlanIamPolicyPlain(argument.toJava()).await())
}
/**
* @see [getBackupPlanIamPolicy].
* @param argument Builder for [com.pulumi.gcp.gkebackup.kotlin.inputs.GetBackupPlanIamPolicyPlainArgs].
* @return A collection of values returned by getBackupPlanIamPolicy.
*/
public suspend fun getBackupPlanIamPolicy(argument: suspend GetBackupPlanIamPolicyPlainArgsBuilder.() -> Unit): GetBackupPlanIamPolicyResult {
val builder = GetBackupPlanIamPolicyPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getBackupPlanIamPolicyResultToKotlin(getBackupPlanIamPolicyPlain(builtArgument.toJava()).await())
}
/**
* Retrieves the current IAM policy data for restoreplan
* ## example
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as gcp from "@pulumi/gcp";
* const policy = gcp.gkebackup.getRestorePlanIamPolicy({
* project: allNs.project,
* location: allNs.location,
* name: allNs.name,
* });
* ```
* ```python
* import pulumi
* import pulumi_gcp as gcp
* policy = gcp.gkebackup.get_restore_plan_iam_policy(project=all_ns["project"],
* location=all_ns["location"],
* name=all_ns["name"])
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Gcp = Pulumi.Gcp;
* return await Deployment.RunAsync(() =>
* {
* var policy = Gcp.GkeBackup.GetRestorePlanIamPolicy.Invoke(new()
* {
* Project = allNs.Project,
* Location = allNs.Location,
* Name = allNs.Name,
* });
* });
* ```
* ```go
* package main
* import (
* "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 {
* _, err := gkebackup.LookupRestorePlanIamPolicy(ctx, &gkebackup.LookupRestorePlanIamPolicyArgs{
* Project: pulumi.StringRef(allNs.Project),
* Location: pulumi.StringRef(allNs.Location),
* Name: allNs.Name,
* }, nil)
* if err != nil {
* return err
* }
* return nil
* })
* }
* ```
* ```java
* package generated_program;
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.gcp.gkebackup.GkebackupFunctions;
* import com.pulumi.gcp.gkebackup.inputs.GetRestorePlanIamPolicyArgs;
* 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) {
* final var policy = GkebackupFunctions.getRestorePlanIamPolicy(GetRestorePlanIamPolicyArgs.builder()
* .project(allNs.project())
* .location(allNs.location())
* .name(allNs.name())
* .build());
* }
* }
* ```
* ```yaml
* variables:
* policy:
* fn::invoke:
* Function: gcp:gkebackup:getRestorePlanIamPolicy
* Arguments:
* project: ${allNs.project}
* location: ${allNs.location}
* name: ${allNs.name}
* ```
*
* @param argument A collection of arguments for invoking getRestorePlanIamPolicy.
* @return A collection of values returned by getRestorePlanIamPolicy.
*/
public suspend fun getRestorePlanIamPolicy(argument: GetRestorePlanIamPolicyPlainArgs): GetRestorePlanIamPolicyResult =
getRestorePlanIamPolicyResultToKotlin(getRestorePlanIamPolicyPlain(argument.toJava()).await())
/**
* @see [getRestorePlanIamPolicy].
* @param location The region of the Restore Plan.
* Used to find the parent resource to bind the IAM policy to. If not specified,
* the value will be parsed from the identifier of the parent resource. If no location is provided in the parent identifier and no
* location is specified, it is taken from the provider configuration.
* @param name Used to find the parent resource to bind the IAM policy to
* @param project The ID of the project in which the resource belongs.
* If it is not provided, the project will be parsed from the identifier of the parent resource. If no project is provided in the parent identifier and no project is specified, the provider project is used.
* @return A collection of values returned by getRestorePlanIamPolicy.
*/
public suspend fun getRestorePlanIamPolicy(
location: String? = null,
name: String,
project: String? = null,
): GetRestorePlanIamPolicyResult {
val argument = GetRestorePlanIamPolicyPlainArgs(
location = location,
name = name,
project = project,
)
return getRestorePlanIamPolicyResultToKotlin(getRestorePlanIamPolicyPlain(argument.toJava()).await())
}
/**
* @see [getRestorePlanIamPolicy].
* @param argument Builder for [com.pulumi.gcp.gkebackup.kotlin.inputs.GetRestorePlanIamPolicyPlainArgs].
* @return A collection of values returned by getRestorePlanIamPolicy.
*/
public suspend fun getRestorePlanIamPolicy(argument: suspend GetRestorePlanIamPolicyPlainArgsBuilder.() -> Unit): GetRestorePlanIamPolicyResult {
val builder = GetRestorePlanIamPolicyPlainArgsBuilder()
builder.argument()
val builtArgument = builder.build()
return getRestorePlanIamPolicyResultToKotlin(getRestorePlanIamPolicyPlain(builtArgument.toJava()).await())
}
}