LoggingLogView


Property Value
Google Cloud Service Name Cloud Logging
Google Cloud Service Documentation /logging/docs/
Google Cloud REST Resource Name
v2.billingAccounts.locations.buckets.views
v2.folders.locations.buckets.views
v2.organizations.locations.buckets.views
v2.projects.locations.buckets.views
Google Cloud REST Resource Documentation
/logging/docs/reference/v2/rest/v2/billingAccounts.locations.buckets.views
/logging/docs/reference/v2/rest/v2/folders.locations.buckets.views
/logging/docs/reference/v2/rest/v2/organizations.locations.buckets.views
/logging/docs/reference/v2/rest/v2/projects.locations.buckets.views
Config Connector Resource Short Names gcplogginglogview
gcplogginglogviews
logginglogview
Config Connector Service Name logging.googleapis.com
Config Connector Resource Fully Qualified Name logginglogviews.logging.cnrm.cloud.google.com
Can Be Referenced by IAMPolicy/IAMPolicyMember No
Config Connector Default Average Reconcile Interval In Seconds 600

Custom Resource Definition Properties

Annotations

Fields
cnrm.cloud.google.com/state-into-spec

Spec

Schema

billingAccountRef:
  external: string
  name: string
  namespace: string
bucketRef:
  external: string
  name: string
  namespace: string
description: string
filter: string
folderRef:
  external: string
  name: string
  namespace: string
location: string
organizationRef:
  external: string
  name: string
  namespace: string
projectRef:
  external: string
  name: string
  namespace: string
resourceID: string
Fields

billingAccountRef

Optional

object

Immutable. The BillingAccount that this resource belongs to. Only one of [billingAccountRef, folderRef, organizationRef, projectRef] may be specified.

billingAccountRef.external

Optional

string

Allowed value: The Google Cloud resource name of a Google Cloud Billing Account (format: `billingAccounts/{{name}}`).

billingAccountRef.name

Optional

string

[WARNING] BillingAccount not yet supported in Config Connector, use 'external' field to reference existing resources. Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

billingAccountRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

bucketRef

Required

object

Immutable.

bucketRef.external

Optional

string

The bucket of the resource Allowed value: The Google Cloud resource name of a `LoggingLogBucket` resource (format: `{{parent}}/locations/{{location}}/buckets/{{name}}`).

bucketRef.name

Optional

string

Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

bucketRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

description

Optional

string

Describes this view.

filter

Optional

string

Filter that restricts which log entries in a bucket are visible in this view. Filters are restricted to be a logical AND of ==/!= of any of the following: - originating project/folder/organization/billing account. - resource type - log id For example: SOURCE("projects/myproject") AND resource.type = "gce_instance" AND LOG_ID("stdout")

folderRef

Optional

object

Immutable. The Folder that this resource belongs to. Only one of [billingAccountRef, folderRef, organizationRef, projectRef] may be specified.

folderRef.external

Optional

string

Allowed value: The Google Cloud resource name of a `Folder` resource (format: `folders/{{name}}`).

folderRef.name

Optional

string

Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

folderRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

location

Optional

string

Immutable. The location of the resource. The supported locations are: global, us-central1, us-east1, us-west1, asia-east1, europe-west1.

organizationRef

Optional

object

Immutable. The Organization that this resource belongs to. Only one of [billingAccountRef, folderRef, organizationRef, projectRef] may be specified.

organizationRef.external

Optional

string

Allowed value: The Google Cloud resource name of a Google Cloud Organization (format: `organizations/{{name}}`).

organizationRef.name

Optional

string

[WARNING] Organization not yet supported in Config Connector, use 'external' field to reference existing resources. Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

organizationRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

projectRef

Optional

object

Immutable. The Project that this resource belongs to. Only one of [billingAccountRef, folderRef, organizationRef, projectRef] may be specified.

projectRef.external

Optional

string

Allowed value: The Google Cloud resource name of a `Project` resource (format: `projects/{{name}}`).

projectRef.name

Optional

string

Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

projectRef.namespace

Optional

string

Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/

resourceID

Optional

string

Immutable. Optional. The name of the resource. Used for creation and acquisition. When unset, the value of `metadata.name` is used as the default.

Status

Schema

conditions:
- lastTransitionTime: string
  message: string
  reason: string
  status: string
  type: string
createTime: string
observedGeneration: integer
updateTime: string
Fields
conditions

list (object)

Conditions represent the latest available observation of the resource's current state.

conditions[]

object

conditions[].lastTransitionTime

string

Last time the condition transitioned from one status to another.

conditions[].message

string

Human-readable message indicating details about last transition.

conditions[].reason

string

Unique, one-word, CamelCase reason for the condition's last transition.

conditions[].status

string

Status is the status of the condition. Can be True, False, Unknown.

conditions[].type

string

Type is the type of the condition.

createTime

string

Output only. The creation timestamp of the view.

observedGeneration

integer

ObservedGeneration is the generation of the resource that was most recently observed by the Config Connector controller. If this is equal to metadata.generation, then that means that the current reported status reflects the most recent desired state of the resource.

updateTime

string

Output only. The last update timestamp of the view.

Sample YAML(s)

Organization Log View

# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

apiVersion: logging.cnrm.cloud.google.com/v1beta1
kind: LoggingLogView
metadata:
  name: logginglogview-sample-organizationlogview
spec:
  bucketRef:
    # Replace "${ORG_ID?}" with the numeric ID for your organization
    external: "organizations/${ORG_ID?}/locations/global/buckets/_Default"
  organizationRef:
    # Replace "${ORG_ID?}" with the numeric ID for your organization
    external: "organizations/${ORG_ID?}"

Project Log View

# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

apiVersion: logging.cnrm.cloud.google.com/v1beta1
kind: LoggingLogView
metadata:
  name: logginglogview-sample-projectlogview
spec:
  bucketRef:
    name: "logginglogview-dep-projectlogview"
  description: "A project-level log view"
  filter: "SOURCE(\"projects/myproject\") AND resource.type = \"gce_instance\" AND\
    \ LOG_ID(\"stdout\")"
---
apiVersion: logging.cnrm.cloud.google.com/v1beta1
kind: LoggingLogBucket
metadata:
  name: logginglogview-dep-projectlogview
spec:
  projectRef:
    # Replace ${PROJECT_ID?} with your project ID
    external: "projects/${PROJECT_ID?}"
  location: "global"
  description: "A sample log bucket"
  locked: false
  retentionDays: 30