Updates a BuildTrigger by its project ID and trigger ID.

Scopes

You will need authorization for the https://www.googleapis.com/auth/cloud-platform scope to make a valid call.

If unset, the scope for this method defaults to https://www.googleapis.com/auth/cloud-platform. You can set the scope for this method like this: cloudbuild1 --scope <scope> projects triggers-patch ...

Required Scalar Arguments

  • <project-id> (string)
    • Required. ID of the project that owns the trigger.
  • <trigger-id> (string)
    • Required. ID of the BuildTrigger to update.

Required Request Value

The request value is a data-structure with various fields. Each field may be a simple scalar or another data-structure. In the latter case it is advised to set the field-cursor to the data-structure's field to specify values more concisely.

For example, a structure like this:

BuildTrigger:
  approval-config:
    approval-required: boolean
  autodetect: boolean
  bitbucket-server-trigger-config:
    bitbucket-server-config:
      api-key: string
      create-time: string
      host-uri: string
      name: string
      peered-network: string
      peered-network-ip-range: string
      secrets:
        admin-access-token-version-name: string
        read-access-token-version-name: string
        webhook-secret-version-name: string
      ssl-ca: string
      username: string
      webhook-key: string
    bitbucket-server-config-resource: string
    project-key: string
    pull-request:
      branch: string
      comment-control: string
      invert-regex: boolean
    push:
      branch: string
      invert-regex: boolean
      tag: string
    repo-slug: string
  build:
    approval:
      config:
        approval-required: boolean
      result:
        approval-time: string
        approver-account: string
        comment: string
        decision: string
        url: string
      state: string
    artifacts:
      images: [string]
      objects:
        location: string
        paths: [string]
        timing:
          end-time: string
          start-time: string
    build-trigger-id: string
    create-time: string
    failure-info:
      detail: string
      type: string
    finish-time: string
    id: string
    images: [string]
    log-url: string
    logs-bucket: string
    name: string
    options:
      automap-substitutions: boolean
      default-logs-bucket-behavior: string
      disk-size-gb: string
      dynamic-substitutions: boolean
      env: [string]
      log-streaming-option: string
      logging: string
      machine-type: string
      pool:
        name: string
      requested-verify-option: string
      secret-env: [string]
      source-provenance-hash: [string]
      substitution-option: string
      worker-pool: string
    project-id: string
    queue-ttl: string
    results:
      artifact-manifest: string
      artifact-timing:
        end-time: string
        start-time: string
      build-step-images: [string]
      build-step-outputs: [string]
      num-artifacts: string
    service-account: string
    source:
      connected-repository:
        dir: string
        repository: string
        revision: string
      git-source:
        dir: string
        revision: string
        url: string
      repo-source:
        branch-name: string
        commit-sha: string
        dir: string
        invert-regex: boolean
        project-id: string
        repo-name: string
        substitutions: { string: string }
        tag-name: string
      storage-source:
        bucket: string
        generation: string
        object: string
        source-fetcher: string
      storage-source-manifest:
        bucket: string
        generation: string
        object: string
    source-provenance:
      resolved-connected-repository:
        dir: string
        repository: string
        revision: string
      resolved-git-source:
        dir: string
        revision: string
        url: string
      resolved-repo-source:
        branch-name: string
        commit-sha: string
        dir: string
        invert-regex: boolean
        project-id: string
        repo-name: string
        substitutions: { string: string }
        tag-name: string
      resolved-storage-source:
        bucket: string
        generation: string
        object: string
        source-fetcher: string
      resolved-storage-source-manifest:
        bucket: string
        generation: string
        object: string
    start-time: string
    status: string
    status-detail: string
    substitutions: { string: string }
    tags: [string]
    timeout: string
  create-time: string
  description: string
  disabled: boolean
  event-type: string
  filename: string
  filter: string
  git-file-source:
    bitbucket-server-config: string
    github-enterprise-config: string
    path: string
    repo-type: string
    repository: string
    revision: string
    uri: string
  github:
    enterprise-config-resource-name: string
    installation-id: string
    name: string
    owner: string
    pull-request:
      branch: string
      comment-control: string
      invert-regex: boolean
    push:
      branch: string
      invert-regex: boolean
      tag: string
  gitlab-enterprise-events-config:
    gitlab-config:
      create-time: string
      enterprise-config:
        host-uri: string
        service-directory-config:
          service: string
        ssl-ca: string
      name: string
      secrets:
        api-access-token-version: string
        api-key-version: string
        read-access-token-version: string
        webhook-secret-version: string
      username: string
      webhook-key: string
    gitlab-config-resource: string
    project-namespace: string
    pull-request:
      branch: string
      comment-control: string
      invert-regex: boolean
    push:
      branch: string
      invert-regex: boolean
      tag: string
  id: string
  ignored-files: [string]
  include-build-logs: string
  included-files: [string]
  name: string
  pubsub-config:
    service-account-email: string
    state: string
    subscription: string
    topic: string
  repository-event-config:
    pull-request:
      branch: string
      comment-control: string
      invert-regex: boolean
    push:
      branch: string
      invert-regex: boolean
      tag: string
    repository: string
    repository-type: string
  resource-name: string
  service-account: string
  source-to-build:
    bitbucket-server-config: string
    github-enterprise-config: string
    ref: string
    repo-type: string
    repository: string
    uri: string
  substitutions: { string: string }
  tags: [string]
  trigger-template:
    branch-name: string
    commit-sha: string
    dir: string
    invert-regex: boolean
    project-id: string
    repo-name: string
    substitutions: { string: string }
    tag-name: string
  webhook-config:
    secret: string
    state: string

can be set completely with the following arguments which are assumed to be executed in the given order. Note how the cursor position is adjusted to the respective structures, allowing simple field names to be used most of the time.

  • -r .approval-config approval-required=true

    • Whether or not approval is needed. If this is set on a build, it will become pending when created, and will need to be explicitly approved to start.
  • .. autodetect=true

    • Autodetect build configuration. The following precedence is used (case insensitive): 1. cloudbuild.yaml 2. cloudbuild.yml 3. cloudbuild.json 4. Dockerfile Currently only available for GitHub App Triggers.
  • bitbucket-server-trigger-config.bitbucket-server-config api-key=sed
    • Required. Immutable. API Key that will be attached to webhook. Once this field has been set, it cannot be changed. If you need to change it, please create another BitbucketServerConfig.
  • create-time=et
    • Time when the config was created.
  • host-uri=et
    • Required. Immutable. The URI of the Bitbucket Server host. Once this field has been set, it cannot be changed. If you need to change it, please create another BitbucketServerConfig.
  • name=duo
    • The resource name for the config.
  • peered-network=dolor
    • Optional. The network to be used when reaching out to the Bitbucket Server instance. The VPC network must be enabled for private service connection. This should be set if the Bitbucket Server instance is hosted on-premises and not reachable by public internet. If this field is left empty, no network peering will occur and calls to the Bitbucket Server instance will be made over the public internet. Must be in the format projects/{project}/global/networks/{network}, where {project} is a project number or id and {network} is the name of a VPC network in the project.
  • peered-network-ip-range=voluptua.
    • Immutable. IP range within the peered network. This is specified in CIDR notation with a slash and the subnet prefix size. You can optionally specify an IP address before the subnet prefix value. e.g. 192.168.0.0/29 would specify an IP range starting at 192.168.0.0 with a 29 bit prefix size. /16 would specify a prefix size of 16 bits, with an automatically determined IP within the peered VPC. If unspecified, a value of /24 will be used. The field only has an effect if peered_network is set.
  • secrets admin-access-token-version-name=magna
    • Required. The resource name for the admin access token's secret version.
  • read-access-token-version-name=est
    • Required. The resource name for the read access token's secret version.
  • webhook-secret-version-name=voluptua.

    • Required. Immutable. The resource name for the webhook secret's secret version. Once this field has been set, it cannot be changed. If you need to change it, please create another BitbucketServerConfig.
  • .. ssl-ca=voluptua.

    • Optional. SSL certificate to use for requests to Bitbucket Server. The format should be PEM format but the extension can be one of .pem, .cer, or .crt.
  • username=tempor
    • Username of the account Cloud Build will use on Bitbucket Server.
  • webhook-key=takimata

    • Output only. UUID included in webhook requests. The UUID is used to look up the corresponding config.
  • .. bitbucket-server-config-resource=ut

    • Required. The Bitbucket server config resource that this trigger config maps to.
  • project-key=no
    • Required. Key of the project that the repo is in. For example: The key for https://mybitbucket.server/projects/TEST/repos/test-repo is "TEST".
  • pull-request branch=gubergren
    • Regex of branches to match. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • comment-control=ut
    • If CommentControl is enabled, depending on the setting, builds may not fire until a repository writer comments /gcbrun on a pull request or /gcbrun is in the pull request description. Only PR comments that contain /gcbrun will trigger builds. If CommentControl is set to disabled, comments with /gcbrun from a user with repository write permission or above will still trigger builds to run.
  • invert-regex=true

    • If true, branches that do NOT match the git_ref will trigger a build.
  • ..push branch=lorem

    • Regexes matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • invert-regex=false
    • When true, only trigger a build if the revision regex does NOT match the git_ref regex.
  • tag=sed

    • Regexes matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • .. repo-slug=rebum.

    • Required. Slug of the repository. A repository slug is a URL-friendly version of a repository name, automatically generated by Bitbucket for use in the URL. For example, if the repository name is 'test repo', in the URL it would become 'test-repo' as in https://mybitbucket.server/projects/TEST/repos/test-repo.
  • ..build.approval.config approval-required=true

    • Whether or not approval is needed. If this is set on a build, it will become pending when created, and will need to be explicitly approved to start.
  • ..result approval-time=sit

    • Output only. The time when the approval decision was made.
  • approver-account=no
    • Output only. Email of the user that called the ApproveBuild API to approve or reject a build at the time that the API was called.
  • comment=kasd
    • Optional. An optional comment for this manual approval result.
  • decision=stet
    • Required. The decision of this manual approval.
  • url=accusam

    • Optional. An optional URL tied to this manual approval result. This field is essentially the same as comment, except that it will be rendered by the UI differently. An example use case is a link to an external job that approved this Build.
  • .. state=lorem

    • Output only. The state of this build's approval.
  • ..artifacts images=et

    • A list of images to be pushed upon the successful completion of all build steps. The images will be pushed using the builder service account's credentials. The digests of the pushed images will be stored in the Build resource's results field. If any of the images fail to be pushed, the build is marked FAILURE.
    • Each invocation of this argument appends the given value to the array.
  • objects location=nonumy
    • Cloud Storage bucket and optional object path, in the form "gs://bucket/path/to/somewhere/". (see Bucket Name Requirements). Files in the workspace matching any path pattern will be uploaded to Cloud Storage with this location as a prefix.
  • paths=kasd
    • Path globs used to match files in the build's workspace.
    • Each invocation of this argument appends the given value to the array.
  • timing end-time=et
    • End of time span.
  • start-time=amet

    • Start of time span.
  • .... build-trigger-id=et

    • Output only. The ID of the BuildTrigger that triggered this build, if it was triggered automatically.
  • create-time=dolor
    • Output only. Time at which the request to create the build was received.
  • failure-info detail=elitr
    • Explains the failure issue in more detail using hard-coded text.
  • type=sanctus

    • The name of the failure.
  • .. finish-time=dolor

    • Output only. Time at which execution of the build was finished. The difference between finish_time and start_time is the duration of the build's execution.
  • id=sea
    • Output only. Unique identifier of the build.
  • images=sanctus
    • A list of images to be pushed upon the successful completion of all build steps. The images are pushed using the builder service account's credentials. The digests of the pushed images will be stored in the Build resource's results field. If any of the images fail to be pushed, the build status is marked FAILURE.
    • Each invocation of this argument appends the given value to the array.
  • log-url=sit
    • Output only. URL to logs for this build in Google Cloud Console.
  • logs-bucket=est
    • Cloud Storage bucket where logs should be written (see Bucket Name Requirements). Logs file names will be of the format ${logs_bucket}/log-${build_id}.txt.
  • name=nonumy
    • Output only. The 'Build' name with format: projects/{project}/locations/{location}/builds/{build}, where {build} is a unique identifier generated by the service.
  • options automap-substitutions=false
    • Option to include built-in and custom substitutions as env variables for all build steps.
  • default-logs-bucket-behavior=invidunt
    • Optional. Option to specify how default logs buckets are setup.
  • disk-size-gb=takimata
    • Requested disk size for the VM that runs the build. Note that this is NOT "disk free"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.
  • dynamic-substitutions=true
    • Option to specify whether or not to apply bash style string operations to the substitutions. NOTE: this is always enabled for triggered builds and cannot be overridden in the build configuration file.
  • env=tempor
    • A list of global environment variable definitions that will exist for all build steps in this build. If a variable is defined in both globally and in a build step, the variable will use the build step value. The elements are of the form "KEY=VALUE" for the environment variable "KEY" being given the value "VALUE".
    • Each invocation of this argument appends the given value to the array.
  • log-streaming-option=nonumy
    • Option to define build log streaming behavior to Cloud Storage.
  • logging=sanctus
    • Option to specify the logging mode, which determines if and where build logs are stored.
  • machine-type=labore
    • Compute Engine machine type on which to run the build.
  • pool name=est

    • The WorkerPool resource to execute the build on. You must have cloudbuild.workerpools.use on the project hosting the WorkerPool. Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
  • .. requested-verify-option=sadipscing

    • Requested verifiability options.
  • secret-env=accusam
    • A list of global environment variables, which are encrypted using a Cloud Key Management Service crypto key. These values must be specified in the build's Secret. These variables will be available to all build steps in this build.
    • Each invocation of this argument appends the given value to the array.
  • source-provenance-hash=elitr
    • Requested hash for SourceProvenance.
    • Each invocation of this argument appends the given value to the array.
  • substitution-option=sit
    • Option to specify behavior when there is an error in the substitution checks. NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot be overridden in the build configuration file.
  • worker-pool=invidunt

    • This field deprecated; please use pool.name instead.
  • .. project-id=dolore

    • Output only. ID of the project.
  • queue-ttl=et
    • TTL in queue for this build. If provided and the build is enqueued longer than this value, the build will expire and the build status will be EXPIRED. The TTL starts ticking from create_time.
  • results artifact-manifest=tempor
    • Path to the artifact manifest for non-container artifacts uploaded to Cloud Storage. Only populated when artifacts are uploaded to Cloud Storage.
  • artifact-timing end-time=nonumy
    • End of time span.
  • start-time=labore

    • Start of time span.
  • .. build-step-images=et

    • List of build step digests, in the order corresponding to build step indices.
    • Each invocation of this argument appends the given value to the array.
  • build-step-outputs=et
    • List of build step outputs, produced by builder images, in the order corresponding to build step indices. Cloud Builders can produce this output by writing to $BUILDER_OUTPUT/output. Only the first 50KB of data is stored.
    • Each invocation of this argument appends the given value to the array.
  • num-artifacts=nonumy

    • Number of non-container artifacts uploaded to Cloud Storage. Only populated when artifacts are uploaded to Cloud Storage.
  • .. service-account=sit

    • IAM service account whose credentials will be used at build runtime. Must be of the format projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}. ACCOUNT can be email address or uniqueId of the service account.
  • source.connected-repository dir=lorem
    • Directory, relative to the source root, in which to run the build.
  • repository=amet.
    • Required. Name of the Google Cloud Build repository, formatted as projects/*/locations/*/connections/*/repositories/*.
  • revision=kasd

    • The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.
  • ..git-source dir=elitr

    • Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's dir is specified and is an absolute path, this value is ignored for that step's execution.
  • revision=sea
    • The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses git fetch to fetch the revision from the Git repository; therefore make sure that the string you provide for revision is parsable by the command. For information on string values accepted by git fetch, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on git fetch, see https://git-scm.com/docs/git-fetch.
  • url=duo

    • Location of the Git repo to build. This will be used as a git remote, see https://git-scm.com/docs/git-remote.
  • ..repo-source branch-name=sea

    • Regex matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • commit-sha=stet
    • Explicit commit SHA to build.
  • dir=erat
    • Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's dir is specified and is an absolute path, this value is ignored for that step's execution.
  • invert-regex=false
    • Only trigger a build if the revision regex does NOT match the revision regex.
  • project-id=no
    • ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.
  • repo-name=eirmod
    • Name of the Cloud Source Repository.
  • substitutions=key=accusam
    • Substitutions to use in a triggered build. Should only be used with RunBuildTrigger
    • the value will be associated with the given key
  • tag-name=et

    • Regex matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • ..storage-source bucket=sit

  • generation=lorem
    • Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.
  • object=et
    • Cloud Storage object containing the source. This object must be a zipped (.zip) or gzipped archive file (.tar.gz) containing source to build.
  • source-fetcher=tempor

    • Optional. Option to specify the tool to fetch the source file for the build.
  • ..storage-source-manifest bucket=lorem

  • generation=vero
    • Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.
  • object=at

    • Cloud Storage object containing the source manifest. This object must be a JSON file.
  • ...source-provenance.resolved-connected-repository dir=duo

    • Directory, relative to the source root, in which to run the build.
  • repository=ea
    • Required. Name of the Google Cloud Build repository, formatted as projects/*/locations/*/connections/*/repositories/*.
  • revision=et

    • The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.
  • ..resolved-git-source dir=lorem

    • Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's dir is specified and is an absolute path, this value is ignored for that step's execution.
  • revision=justo
    • The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses git fetch to fetch the revision from the Git repository; therefore make sure that the string you provide for revision is parsable by the command. For information on string values accepted by git fetch, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on git fetch, see https://git-scm.com/docs/git-fetch.
  • url=et

    • Location of the Git repo to build. This will be used as a git remote, see https://git-scm.com/docs/git-remote.
  • ..resolved-repo-source branch-name=labore

    • Regex matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • commit-sha=ipsum
    • Explicit commit SHA to build.
  • dir=aliquyam
    • Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's dir is specified and is an absolute path, this value is ignored for that step's execution.
  • invert-regex=false
    • Only trigger a build if the revision regex does NOT match the revision regex.
  • project-id=erat
    • ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.
  • repo-name=diam
    • Name of the Cloud Source Repository.
  • substitutions=key=et
    • Substitutions to use in a triggered build. Should only be used with RunBuildTrigger
    • the value will be associated with the given key
  • tag-name=ipsum

    • Regex matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • ..resolved-storage-source bucket=et

  • generation=dolor
    • Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.
  • object=amet
    • Cloud Storage object containing the source. This object must be a zipped (.zip) or gzipped archive file (.tar.gz) containing source to build.
  • source-fetcher=magna

    • Optional. Option to specify the tool to fetch the source file for the build.
  • ..resolved-storage-source-manifest bucket=gubergren

  • generation=dolor
    • Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.
  • object=est

    • Cloud Storage object containing the source manifest. This object must be a JSON file.
  • ... start-time=eirmod

    • Output only. Time at which execution of the build was started.
  • status=invidunt
    • Output only. Status of the build.
  • status-detail=consetetur
    • Output only. Customer-readable message about the current status.
  • substitutions=key=duo
    • Substitutions data for Build resource.
    • the value will be associated with the given key
  • tags=est
    • Tags for annotation of a Build. These are not docker tags.
    • Each invocation of this argument appends the given value to the array.
  • timeout=erat

    • Amount of time that this build should be allowed to run, to second granularity. If this amount of time elapses, work on the build will cease and the build status will be TIMEOUT. timeout starts ticking from startTime. Default time is 60 minutes.
  • .. create-time=duo

    • Output only. Time when the trigger was created.
  • description=sed
    • Human-readable description of this trigger.
  • disabled=true
    • If true, the trigger will never automatically execute a build.
  • event-type=gubergren
    • EventType allows the user to explicitly set the type of event to which this BuildTrigger should respond. This field will be validated against the rest of the configuration if it is set.
  • filename=takimata
    • Path, from the source root, to the build configuration file (i.e. cloudbuild.yaml).
  • filter=et
    • A Common Expression Language string.
  • git-file-source bitbucket-server-config=erat
    • The full resource name of the bitbucket server config. Format: projects/{project}/locations/{location}/bitbucketServerConfigs/{id}.
  • github-enterprise-config=sea
    • The full resource name of the github enterprise config. Format: projects/{project}/locations/{location}/githubEnterpriseConfigs/{id}. projects/{project}/githubEnterpriseConfigs/{id}.
  • path=vero
    • The path of the file, with the repo root as the root of the path.
  • repo-type=diam
    • See RepoType above.
  • repository=takimata
    • The fully qualified resource name of the Repos API repository. Either URI or repository can be specified. If unspecified, the repo from which the trigger invocation originated is assumed to be the repo from which to read the specified path.
  • revision=voluptua.
    • The branch, tag, arbitrary ref, or SHA version of the repo to use when resolving the filename (optional). This field respects the same syntax/resolution as described here: https://git-scm.com/docs/gitrevisions If unspecified, the revision from which the trigger invocation originated is assumed to be the revision from which to read the specified path.
  • uri=et

    • The URI of the repo. Either uri or repository can be specified. If unspecified, the repo from which the trigger invocation originated is assumed to be the repo from which to read the specified path.
  • ..github enterprise-config-resource-name=sea

    • Optional. The resource name of the github enterprise config that should be applied to this installation. For example: "projects/{$project_id}/locations/{$location_id}/githubEnterpriseConfigs/{$config_id}"
  • installation-id=aliquyam
    • The installationID that emits the GitHub event.
  • name=ut
    • Name of the repository. For example: The name for https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
  • owner=magna
    • Owner of the repository. For example: The owner for https://github.com/googlecloudplatform/cloud-builders is "googlecloudplatform".
  • pull-request branch=tempor
    • Regex of branches to match. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • comment-control=dolor
    • If CommentControl is enabled, depending on the setting, builds may not fire until a repository writer comments /gcbrun on a pull request or /gcbrun is in the pull request description. Only PR comments that contain /gcbrun will trigger builds. If CommentControl is set to disabled, comments with /gcbrun from a user with repository write permission or above will still trigger builds to run.
  • invert-regex=false

    • If true, branches that do NOT match the git_ref will trigger a build.
  • ..push branch=et

    • Regexes matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • invert-regex=false
    • When true, only trigger a build if the revision regex does NOT match the git_ref regex.
  • tag=no

    • Regexes matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • ...gitlab-enterprise-events-config.gitlab-config create-time=amet

    • Output only. Time when the config was created.
  • enterprise-config host-uri=vero
    • Immutable. The URI of the GitlabEnterprise host.
  • service-directory-config service=duo

    • The Service Directory service name. Format: projects/{project}/locations/{location}/namespaces/{namespace}/services/{service}.
  • .. ssl-ca=dolor

    • The SSL certificate to use in requests to GitLab Enterprise instances.
  • .. name=est

    • The resource name for the config.
  • secrets api-access-token-version=et
    • Required. The resource name for the api access token’s secret version
  • api-key-version=ipsum
    • Required. Immutable. API Key that will be attached to webhook requests from GitLab to Cloud Build.
  • read-access-token-version=stet
    • Required. The resource name for the read access token’s secret version
  • webhook-secret-version=stet

    • Required. Immutable. The resource name for the webhook secret’s secret version. Once this field has been set, it cannot be changed. If you need to change it, please create another GitLabConfig.
  • .. username=amet.

    • Username of the GitLab.com or GitLab Enterprise account Cloud Build will use.
  • webhook-key=ut

    • Output only. UUID included in webhook requests. The UUID is used to look up the corresponding config.
  • .. gitlab-config-resource=duo

    • The GitLab config resource that this trigger config maps to.
  • project-namespace=sed
    • Namespace of the GitLab project.
  • pull-request branch=accusam
    • Regex of branches to match. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • comment-control=accusam
    • If CommentControl is enabled, depending on the setting, builds may not fire until a repository writer comments /gcbrun on a pull request or /gcbrun is in the pull request description. Only PR comments that contain /gcbrun will trigger builds. If CommentControl is set to disabled, comments with /gcbrun from a user with repository write permission or above will still trigger builds to run.
  • invert-regex=true

    • If true, branches that do NOT match the git_ref will trigger a build.
  • ..push branch=lorem

    • Regexes matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • invert-regex=true
    • When true, only trigger a build if the revision regex does NOT match the git_ref regex.
  • tag=kasd

    • Regexes matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • ... id=justo

    • Output only. Unique identifier of the trigger.
  • ignored-files=duo
    • ignored_files and included_files are file glob matches using https://golang.org/pkg/path/filepath/#Match extended with support for "**". If ignored_files and changed files are both empty, then they are not used to determine whether or not to trigger a build. If ignored_files is not empty, then we ignore any files that match any of the ignored_file globs. If the change has no files that are outside of the ignored_files globs, then we do not trigger a build.
    • Each invocation of this argument appends the given value to the array.
  • include-build-logs=nonumy
    • If set to INCLUDE_BUILD_LOGS_WITH_STATUS, log url will be shown on GitHub page when build status is final. Setting this field to INCLUDE_BUILD_LOGS_WITH_STATUS for non GitHub triggers results in INVALID_ARGUMENT error.
  • included-files=sea
    • If any of the files altered in the commit pass the ignored_files filter and included_files is empty, then as far as this filter is concerned, we should trigger the build. If any of the files altered in the commit pass the ignored_files filter and included_files is not empty, then we make sure that at least one of those files matches a included_files glob. If not, then we do not trigger a build.
    • Each invocation of this argument appends the given value to the array.
  • name=eirmod
    • User-assigned name of the trigger. Must be unique within the project. Trigger names must meet the following requirements: + They must contain only alphanumeric characters and dashes. + They can be 1-64 characters long. + They must begin and end with an alphanumeric character.
  • pubsub-config service-account-email=amet
    • Service account that will make the push request.
  • state=sed
    • Potential issues with the underlying Pub/Sub subscription configuration. Only populated on get requests.
  • subscription=dolor
    • Output only. Name of the subscription. Format is projects/{project}/subscriptions/{subscription}.
  • topic=sea

    • The name of the topic from which this subscription is receiving messages. Format is projects/{project}/topics/{topic}.
  • ..repository-event-config.pull-request branch=sadipscing

    • Regex of branches to match. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • comment-control=nonumy
    • If CommentControl is enabled, depending on the setting, builds may not fire until a repository writer comments /gcbrun on a pull request or /gcbrun is in the pull request description. Only PR comments that contain /gcbrun will trigger builds. If CommentControl is set to disabled, comments with /gcbrun from a user with repository write permission or above will still trigger builds to run.
  • invert-regex=false

    • If true, branches that do NOT match the git_ref will trigger a build.
  • ..push branch=labore

    • Regexes matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • invert-regex=false
    • When true, only trigger a build if the revision regex does NOT match the git_ref regex.
  • tag=justo

    • Regexes matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • .. repository=sed

    • The resource name of the Repo API resource.
  • repository-type=sit

    • Output only. The type of the SCM vendor the repository points to.
  • .. resource-name=ipsum

    • The Trigger name with format: projects/{project}/locations/{location}/triggers/{trigger}, where {trigger} is a unique identifier generated by the service.
  • service-account=sanctus
    • The service account used for all user-controlled operations including UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. If no service account is set, then the standard Cloud Build service account ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. Format: projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}
  • source-to-build bitbucket-server-config=sed
    • The full resource name of the bitbucket server config. Format: projects/{project}/locations/{location}/bitbucketServerConfigs/{id}.
  • github-enterprise-config=justo
    • The full resource name of the github enterprise config. Format: projects/{project}/locations/{location}/githubEnterpriseConfigs/{id}. projects/{project}/githubEnterpriseConfigs/{id}.
  • ref=elitr
    • The branch or tag to use. Must start with "refs/" (required).
  • repo-type=sed
    • See RepoType below.
  • repository=sed
    • The connected repository resource name, in the format projects/*/locations/*/connections/*/repositories/*. Either uri or repository can be specified and is required.
  • uri=dolor

    • The URI of the repo (e.g. https://github.com/user/repo.git). Either uri or repository can be specified and is required.
  • .. substitutions=key=no

    • Substitutions for Build resource. The keys must match the following regular expression: ^_[A-Z0-9_]+$.
    • the value will be associated with the given key
  • tags=rebum.
    • Tags for annotation of a BuildTrigger
    • Each invocation of this argument appends the given value to the array.
  • trigger-template branch-name=ipsum
    • Regex matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • commit-sha=rebum.
    • Explicit commit SHA to build.
  • dir=lorem
    • Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's dir is specified and is an absolute path, this value is ignored for that step's execution.
  • invert-regex=false
    • Only trigger a build if the revision regex does NOT match the revision regex.
  • project-id=no
    • ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.
  • repo-name=et
    • Name of the Cloud Source Repository.
  • substitutions=key=sanctus
    • Substitutions to use in a triggered build. Should only be used with RunBuildTrigger
    • the value will be associated with the given key
  • tag-name=no

    • Regex matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax
  • ..webhook-config secret=et

    • Required. Resource name for the secret required as a URL parameter.
  • state=dolor
    • Potential issues with the underlying Pub/Sub subscription configuration. Only populated on get requests.

About Cursors

The cursor position is key to comfortably set complex nested structures. The following rules apply:

  • The cursor position is always set relative to the current one, unless the field name starts with the . character. Fields can be nested such as in -r f.s.o .
  • The cursor position is set relative to the top-level structure if it starts with ., e.g. -r .s.s
  • You can also set nested fields without setting the cursor explicitly. For example, to set a value relative to the current cursor position, you would specify -r struct.sub_struct=bar.
  • You can move the cursor one level up by using ... Each additional . moves it up one additional level. E.g. ... would go three levels up.

Optional Output Flags

The method's return value a JSON encoded structure, which will be written to standard output by default.

  • -o out
    • out specifies the destination to which to write the server's result to. It will be a JSON-encoded structure. The destination may be - to indicate standard output, or a filepath that is to contain the received bytes. If unset, it defaults to standard output.

Optional Method Properties

You may set the following properties to further configure the call. Please note that -p is followed by one or more key-value-pairs, and is called like this -p k1=v1 k2=v2 even though the listing below repeats the -p for completeness.

  • -p update-mask=string
    • Update mask for the resource. If this is set, the server will only update the fields specified in the field mask. Otherwise, a full update of the mutable resource fields will be performed.

Optional General Properties

The following properties can configure any call, and are not specific to this method.

  • -p $-xgafv=string

    • V1 error format.
  • -p access-token=string

    • OAuth access token.
  • -p alt=string

    • Data format for response.
  • -p callback=string

    • JSONP
  • -p fields=string

    • Selector specifying which fields to include in a partial response.
  • -p key=string

    • API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
  • -p oauth-token=string

    • OAuth 2.0 token for the current user.
  • -p pretty-print=boolean

    • Returns response with indentations and line breaks.
  • -p quota-user=string

    • Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
  • -p upload-type=string

    • Legacy upload protocol for media (e.g. "media", "multipart").
  • -p upload-protocol=string

    • Upload protocol for media (e.g. "raw", "multipart").