|
| 1 | +# Copyright 2024 Google Inc. |
| 2 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 3 | +# you may not use this file except in compliance with the License. |
| 4 | +# You may obtain a copy of the License at |
| 5 | +# |
| 6 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 7 | +# |
| 8 | +# Unless required by applicable law or agreed to in writing, software |
| 9 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 10 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 11 | +# See the License for the specific language governing permissions and |
| 12 | +# limitations under the License. |
| 13 | + |
| 14 | +--- !ruby/object:Api::Resource |
| 15 | +name: 'LogScope' |
| 16 | +base_url: '{{parent}}/locations/{{location}}/logScopes' |
| 17 | +create_url: '{{parent}}/locations/{{location}}/logScopes?logScopeId={{name}}' |
| 18 | +self_link: '{{parent}}/locations/{{location}}/logScopes/{{name}}' |
| 19 | +import_format: ['{{%parent}}/locations/{{location}}/logScopes/{{name}}'] |
| 20 | +update_verb: :PATCH |
| 21 | +update_mask: true |
| 22 | +references: !ruby/object:Api::Resource::ReferenceLinks |
| 23 | + guides: |
| 24 | + 'Official Documentation': 'https://cloud.google.com/logging/docs/apis' |
| 25 | + api: 'https://cloud.google.com/logging/docs/reference/v2/rest/v2/projects.locations.logScopes' |
| 26 | +description: 'Describes a group of resources to read log entries from' |
| 27 | +examples: |
| 28 | + - !ruby/object:Provider::Terraform::Examples |
| 29 | + name: 'logging_log_scope_basic' |
| 30 | + primary_resource_id: 'logging_log_scope' |
| 31 | + vars: |
| 32 | + log_scope_name: 'my-log-scope' |
| 33 | + log_view_name_1: 'view1' |
| 34 | + log_view_name_2: 'view2' |
| 35 | + test_env_vars: |
| 36 | + project: :PROJECT_NAME |
| 37 | +custom_code: !ruby/object:Provider::Terraform::CustomCode |
| 38 | + encoder: templates/terraform/encoders/logging_log_scope.go.erb |
| 39 | +parameters: |
| 40 | + - !ruby/object:Api::Type::String |
| 41 | + name: parent |
| 42 | + description: The parent of the resource. |
| 43 | + url_param_only: true |
| 44 | + immutable: true |
| 45 | + default_from_api: true |
| 46 | + diff_suppress_func: 'tpgresource.CompareSelfLinkOrResourceName' |
| 47 | + - !ruby/object:Api::Type::String |
| 48 | + name: location |
| 49 | + description: |
| 50 | + 'The location of the resource. The supported locations are: global, |
| 51 | + us-central1, us-east1, us-west1, asia-east1, europe-west1.' |
| 52 | + url_param_only: true |
| 53 | + immutable: true |
| 54 | + default_from_api: true |
| 55 | +properties: |
| 56 | + - !ruby/object:Api::Type::String |
| 57 | + name: name |
| 58 | + description: |
| 59 | + 'The resource name of the log scope. For example: |
| 60 | + \`projects/my-project/locations/global/logScopes/my-log-scope\`' |
| 61 | + required: true |
| 62 | + immutable: true |
| 63 | + ignore_read: true |
| 64 | + diff_suppress_func: 'tpgresource.CompareResourceNames' |
| 65 | + - !ruby/object:Api::Type::Array |
| 66 | + # This has to be camelCase, even though it's snakeCase in proto definiation. |
| 67 | + name: resourceNames |
| 68 | + item_type: Api::Type::String |
| 69 | + required: true |
| 70 | + description: |
| 71 | + 'Names of one or more parent resources : * \`projects/[PROJECT_ID]\` |
| 72 | + May alternatively be one or more views : |
| 73 | + * \`projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]\` |
| 74 | + A log scope can include a maximum of 50 projects and a maximum of 100 resources in total.' |
| 75 | + - !ruby/object:Api::Type::String |
| 76 | + name: description |
| 77 | + description: Describes this log scopes. |
| 78 | + - !ruby/object:Api::Type::String |
| 79 | + name: createTime |
| 80 | + description: Output only. The creation timestamp of the log scopes. |
| 81 | + output: true |
| 82 | + - !ruby/object:Api::Type::String |
| 83 | + name: updateTime |
| 84 | + description: Output only. The last update timestamp of the log scopes. |
| 85 | + output: true |
0 commit comments