Share via


Copy-PowerAppEnvironment

Copy an environment from source to target.

Syntax

Default (Default)

Copy-PowerAppEnvironment
    [-EnvironmentName] <String>
    [-CopyToRequestDefinition] <Object>
    [[-WaitUntilFinished] <Boolean>]
    [[-TimeoutInMinutes] <Int32>]
    [[-ApiVersion] <String>]
    [<CommonParameters>]

Description

The Copy-PowerAppEnvironment cmdlet copies an environment from source to target. Use Get-Help Copy-PowerAppEnvironment -Examples for more detail.

Examples

EXAMPLE 1

Copy-PowerAppEnvironment -EnvironmentName 0fc02431-15fb-4563-a5ab-8211beb2a86f -CopyToRequestDefinition $copyToRequest

Copy a source environment to 0fc02431-15fb-4563-a5ab-8211beb2a86f. $copyToRequest = [pscustomobject]@{ SourceEnvironmentId = $sourceEnvironment.EnvironmentName TargetEnvironmentName = "Copied from source" TargetSecurityGroupId = "204162d5-59db-40c2-9788-2cda6b063f2b" CopyType = "MinimalCopy" SkipAuditData: true }

Parameters

-ApiVersion

The api version to call with.

Parameter properties

Type:String
Default value:2019-05-01
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:5
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CopyToRequestDefinition

The copy request definition object.

Parameter properties

Type:Object
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:2
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-EnvironmentName

The target environment ID.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:1
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:True
Value from remaining arguments:False

-TimeoutInMinutes

The timeout setting in minutes.

Parameter properties

Type:Int32
Default value:10080
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:4
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-WaitUntilFinished

If set to true, the cmdlet doesn't return until completed.

Parameter properties

Type:Boolean
Default value:False
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:3
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.