Modifier

Partager via


New-AzSecurityGcpProjectEnvironmentObject

Create an in-memory object for GcpProjectEnvironment.

Syntax

New-AzSecurityGcpProjectEnvironmentObject
   [-OrganizationalData <IGcpOrganizationalData>]
   [-ProjectDetailProjectId <String>]
   [-ProjectDetailProjectNumber <String>]
   [-ScanInterval <Int64>]
   [<CommonParameters>]

Description

Create an in-memory object for GcpProjectEnvironment.

Examples

Example 1: Create new GcpOrganizationalDataOrganization object

$orgData = New-AzSecurityGcpOrganizationalDataOrganizationObject -WorkloadIdentityProviderId "provider" -ServiceAccountEmailAddress "my@email.com" -ExcludedProjectNumber @(1,2)
New-AzSecurityGcpProjectEnvironmentObject -ProjectDetailProjectId "asc-sdk-samples" -ScanInterval 24 -OrganizationalData $orgData -ProjectDetailProjectNumber "1234"

EnvironmentType                     : GcpProject
OrganizationalData                  : {
                                        "organizationMembershipType": "Organization",
                                        "excludedProjectNumbers": [ "1", "2" ],
                                        "serviceAccountEmailAddress": "my@email.com",
                                        "workloadIdentityProviderId": "provider"
                                      }
ProjectDetailProjectId              : asc-sdk-samples
ProjectDetailProjectName            : 
ProjectDetailProjectNumber          : 1234
ProjectDetailWorkloadIdentityPoolId : 
ScanInterval                        : 24

Parameters

-OrganizationalData

The Gcp project's organizational data.

Type:IGcpOrganizationalData
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ProjectDetailProjectId

The GCP Project id.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ProjectDetailProjectNumber

The unique GCP Project number.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ScanInterval

Scan interval in hours (value should be between 1-hour to 24-hours).

Type:Int64
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Outputs

GcpProjectEnvironment