HEX
Server: Apache/2.4.65 (Ubuntu)
System: Linux ielts-store-v2 6.8.0-1036-gcp #38~22.04.1-Ubuntu SMP Thu Aug 14 01:19:18 UTC 2025 x86_64
User: root (0)
PHP: 7.2.34-54+ubuntu20.04.1+deb.sury.org+1
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
Upload Files
File: //snap/google-cloud-cli/396/lib/surface/scc/posture_deployments/update.yaml
- release_tracks: [ALPHA, GA]
  command_type: GENERIC
  help_text:
    brief: Update the given Cloud Security Command Center (SCC) posture deployment.
    description: |
      Update a Cloud Security Command Center (SCC) posture deployment.

      Fields specified in update-mask flag are updated. Updatable fields are description and posture_name with posture_revision-id.
      The target_resource for a posture deployment cannot be updated. The posture deployment to be updated should be in ACTIVE State.
      An empty or "*" update-mask implies that posture-id and posture-revision-id are to be updated.
      If posture details of posture deployment need to be updated, then the desired posture needs to be in ACTIVE state.
      LRO operation ID is returned as the response of the command.

    examples: |
      Update the description of the posture deployment named `foo-posture-deployment` in the organization `organizations/123/locations/global`:
        $ {command} organizations/123/locations/global/postureDeployments/foo-posture-deployment --update-mask=description --description="updated-description"

      Update posture deployment named `foo-posture-deployment` with the posture named `foo-posture` and revision_id `abcdefgh` in the organization `organizations/123/locations/global`:
        $ {command} organizations/123/locations/global/postureDeployments/foo-posture-deployment --update-mask=posture_id,posture_revision-id --posture-id=foo-posture --posture-revision-id=abcdefgh

       Update posture deployment named `foo-posture-deployment` with the posture named `foo-posture` and revision_id `abcdefgh` in the organization `organizations/123/locations/global`:
        $ {command} organizations/123/locations/global/postureDeployments/foo-posture-deployment  --posture-id=foo-posture --posture-revision-id=abcdefgh

  request:
    collection: securityposture.organizations.locations.postureDeployments
    api_version: v1alpha
    method: patch
    GA:
      api_version: v1

  arguments:
    resource:
      spec: !REF googlecloudsdk.command_lib.scc.resources:posture_deployment
      help_text: |
          The posture deployment to update. For example organizations/<organizationID>/locations/<location>/postureDeployments/<postureDeploymentID>.

    params:
    - group:
        params:
        - arg_name: posture-id
          api_field: postureDeployment.postureId
          required: true
          help_text: |
            Relative name of the posture to be updated, like `organizations/<organizationID>/locations/<location>/postures/<postureID>`.
        - arg_name: posture-revision-id
          api_field: postureDeployment.postureRevisionId
          required: true
          help_text: |
            Revision ID of the posture to be updated.

    - arg_name: description
      api_field: postureDeployment.description
      help_text: |
        Updated description of posture deployment.

    - arg_name: update-mask
      api_field: updateMask
      help_text: |
        Comma-separated string containing list of fields to be updated.

    - arg_name: etag
      api_field: postureDeployment.etag
      required: false
      help_text: |
          Etag is an optional flag. If the provided Etag doesn't match the server generated Etag, the update operation won't proceed.

  async:
    collection: securityposture.organizations.locations.operations
    extract_resource_result: false

  output:
    format: yaml