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.azurenative.resources.kotlin
import com.pulumi.azurenative.resources.AzurePowerShellScriptArgs.builder
import com.pulumi.azurenative.resources.kotlin.enums.CleanupOptions
import com.pulumi.azurenative.resources.kotlin.inputs.ContainerConfigurationArgs
import com.pulumi.azurenative.resources.kotlin.inputs.ContainerConfigurationArgsBuilder
import com.pulumi.azurenative.resources.kotlin.inputs.EnvironmentVariableArgs
import com.pulumi.azurenative.resources.kotlin.inputs.EnvironmentVariableArgsBuilder
import com.pulumi.azurenative.resources.kotlin.inputs.ManagedServiceIdentityArgs
import com.pulumi.azurenative.resources.kotlin.inputs.ManagedServiceIdentityArgsBuilder
import com.pulumi.azurenative.resources.kotlin.inputs.StorageAccountConfigurationArgs
import com.pulumi.azurenative.resources.kotlin.inputs.StorageAccountConfigurationArgsBuilder
import com.pulumi.core.Either
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* Object model for the Azure PowerShell script.
* Azure REST API version: 2020-10-01. Prior API version in Azure Native 1.x: 2020-10-01.
* ## Example Usage
* ### DeploymentScriptsCreateNoUserManagedIdentity
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using AzureNative = Pulumi.AzureNative;
* return await Deployment.RunAsync(() =>
* {
* var azurePowerShellScript = new AzureNative.Resources.AzurePowerShellScript("azurePowerShellScript", new()
* {
* Arguments = "-Location 'westus' -Name \"*rg2\"",
* AzPowerShellVersion = "1.7.0",
* CleanupPreference = AzureNative.Resources.CleanupOptions.Always,
* Kind = "AzurePowerShell",
* Location = "westus",
* ResourceGroupName = "script-rg",
* RetentionInterval = "PT7D",
* ScriptContent = "Param([string]$Location,[string]$Name) $deploymentScriptOutputs['test'] = 'value' Get-AzResourceGroup -Location $Location -Name $Name",
* ScriptName = "MyDeploymentScript",
* SupportingScriptUris = new[]
* {
* "https://uri1.to.supporting.script",
* "https://uri2.to.supporting.script",
* },
* Timeout = "PT1H",
* });
* });
* ```
* ```go
* package main
* import (
* resources "github.com/pulumi/pulumi-azure-native-sdk/resources/v2"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* _, err := resources.NewAzurePowerShellScript(ctx, "azurePowerShellScript", &resources.AzurePowerShellScriptArgs{
* Arguments: pulumi.String("-Location 'westus' -Name \"*rg2\""),
* AzPowerShellVersion: pulumi.String("1.7.0"),
* CleanupPreference: pulumi.String(resources.CleanupOptionsAlways),
* Kind: pulumi.String("AzurePowerShell"),
* Location: pulumi.String("westus"),
* ResourceGroupName: pulumi.String("script-rg"),
* RetentionInterval: pulumi.String("PT7D"),
* ScriptContent: pulumi.String("Param([string]$Location,[string]$Name) $deploymentScriptOutputs['test'] = 'value' Get-AzResourceGroup -Location $Location -Name $Name"),
* ScriptName: pulumi.String("MyDeploymentScript"),
* SupportingScriptUris: pulumi.StringArray{
* pulumi.String("https://uri1.to.supporting.script"),
* pulumi.String("https://uri2.to.supporting.script"),
* },
* Timeout: pulumi.String("PT1H"),
* })
* 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.azurenative.resources.AzurePowerShellScript;
* import com.pulumi.azurenative.resources.AzurePowerShellScriptArgs;
* 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 azurePowerShellScript = new AzurePowerShellScript("azurePowerShellScript", AzurePowerShellScriptArgs.builder()
* .arguments("-Location 'westus' -Name \"*rg2\"")
* .azPowerShellVersion("1.7.0")
* .cleanupPreference("Always")
* .kind("AzurePowerShell")
* .location("westus")
* .resourceGroupName("script-rg")
* .retentionInterval("PT7D")
* .scriptContent("Param([string]$Location,[string]$Name) $deploymentScriptOutputs['test'] = 'value' Get-AzResourceGroup -Location $Location -Name $Name")
* .scriptName("MyDeploymentScript")
* .supportingScriptUris(
* "https://uri1.to.supporting.script",
* "https://uri2.to.supporting.script")
* .timeout("PT1H")
* .build());
* }
* }
* ```
* ## Import
* An existing resource can be imported using its type token, name, and identifier, e.g.
* ```sh
* $ pulumi import azure-native:resources:AzurePowerShellScript myresource1 /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deploymentScripts/{scriptName}
* ```
* @property arguments Command line arguments to pass to the script. Arguments are separated by spaces. ex: -Name blue* -Location 'West US 2'
* @property azPowerShellVersion Azure PowerShell module version to be used.
* @property cleanupPreference The clean up preference when the script execution gets in a terminal state. Default setting is 'Always'.
* @property containerSettings Container settings.
* @property environmentVariables The environment variables to pass over to the script.
* @property forceUpdateTag Gets or sets how the deployment script should be forced to execute even if the script resource has not changed. Can be current time stamp or a GUID.
* @property identity Optional property. Managed identity to be used for this deployment script. Currently, only user-assigned MSI is supported.
* @property kind Type of the script.
* Expected value is 'AzurePowerShell'.
* @property location The location of the ACI and the storage account for the deployment script.
* @property primaryScriptUri Uri for the script. This is the entry point for the external script.
* @property resourceGroupName The name of the resource group. The name is case insensitive.
* @property retentionInterval Interval for which the service retains the script resource after it reaches a terminal state. Resource will be deleted when this duration expires. Duration is based on ISO 8601 pattern (for example P1D means one day).
* @property scriptContent Script body.
* @property scriptName Name of the deployment script.
* @property storageAccountSettings Storage Account settings.
* @property supportingScriptUris Supporting files for the external script.
* @property tags Resource tags.
* @property timeout Maximum allowed script execution time specified in ISO 8601 format. Default value is P1D
*/
public data class AzurePowerShellScriptArgs(
public val arguments: Output? = null,
public val azPowerShellVersion: Output? = null,
public val cleanupPreference: Output>? = null,
public val containerSettings: Output? = null,
public val environmentVariables: Output>? = null,
public val forceUpdateTag: Output? = null,
public val identity: Output? = null,
public val kind: Output? = null,
public val location: Output? = null,
public val primaryScriptUri: Output? = null,
public val resourceGroupName: Output? = null,
public val retentionInterval: Output? = null,
public val scriptContent: Output? = null,
public val scriptName: Output? = null,
public val storageAccountSettings: Output? = null,
public val supportingScriptUris: Output>? = null,
public val tags: Output