Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .codespellignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
notin
coo
#a real typo from upstream k8s.io/apiserver
fileds
2 changes: 2 additions & 0 deletions .golangci.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
version: "2"
linters:
default: standard
enable:
- misspell
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -100,17 +100,23 @@ build-debug:
docs: docs/reference/operator/api_observability_v1.adoc docs/reference/operator/api_logging_v1alpha1.adoc docs/reference/datamodels/viaq/v1.adoc
.PHONY: docs

.PHONY: docs-spell-check
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably should be added to either the linter script or lint target

Copy link
Copy Markdown
Contributor Author

@vparfonov vparfonov May 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

enable misspell linter for Go comments and strings

docs-spell-check:
podman run --rm -v $(PWD):/workdir:z registry.access.redhat.com/ubi9/python-312:latest sh -c 'pip install --quiet codespell && codespell /workdir/docs/ -I /workdir/.codespellignore'

docs/reference/operator/api_observability_v1.adoc: $(GEN_CRD_API_REFERENCE_DOCS)
$(GEN_CRD_API_REFERENCE_DOCS) -api-dir "github.com/openshift/cluster-logging-operator/api" -config "$(PWD)/config/docs/config_observability_v1.json" -template-dir "$(PWD)/config/docs/templates/apis/asciidoc" -out-file "$(PWD)/$@"
@perl -pi -e 's/\|\|/\\|\\|/g' "$(PWD)/$@"
@perl hack/fix-asciidoc.pl "$(PWD)/$@"
.PHONY: docs/reference/operator/api_observability_v1.adoc

docs/reference/operator/api_logging_v1alpha1.adoc: $(GEN_CRD_API_REFERENCE_DOCS)
$(GEN_CRD_API_REFERENCE_DOCS) -api-dir "github.com/openshift/cluster-logging-operator/api" -config "$(PWD)/config/docs/config_logging_v1alpha1.json" -template-dir "$(PWD)/config/docs/templates/apis/asciidoc" -out-file "$(PWD)/$@"
@perl hack/fix-asciidoc.pl "$(PWD)/$@"
.PHONY: docs/reference/operator/api_observability_v1.adoc

docs/reference/datamodels/viaq/v1.adoc: $(GEN_CRD_API_REFERENCE_DOCS)
$(GEN_CRD_API_REFERENCE_DOCS) -api-dir "github.com/openshift/cluster-logging-operator/internal/datamodels/viaq/v1" -config "$(PWD)/config/docs/config_observability_v1.json" -template-dir "$(PWD)/config/docs/templates/datamodels/asciidoc" -out-file "$(PWD)/$@"
@perl hack/fix-asciidoc.pl "$(PWD)/$@"
.PHONY: docs/reference/datamodels/viaq/v1.adoc

# Run the CLO locally - see HACKING.md
Expand Down
2 changes: 1 addition & 1 deletion README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ pods), _infrastructure_ logs (from system pods and node logs), and _audit_ logs

The CLO deploys:

* A log collector/forwarder (current implimentation is https://vector.dev/[Vector])
* A log collector/forwarder (current implementation is https://vector.dev/[Vector])

and relies upon:

Expand Down
2 changes: 1 addition & 1 deletion api/logging/v1alpha1/doc.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// package v1alpha1 custom resorces for the cluster logging operator.
// package v1alpha1 custom resources for the cluster logging operator.
//
// NOTE: This API is under construction and subject to change.
//
Expand Down
10 changes: 5 additions & 5 deletions api/observability/v1/filter_api_audit_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import auditv1 "k8s.io/apiserver/pkg/apis/audit/v1"

// KubeAPIAudit filter Kube API server audit logs, as described in [Kubernetes Auditing].
//
// # Policy Filtering
// == Policy Filtering
//
// Policy event rules are the same format as the [Kube Audit Policy] with some minor extensions.
// The extensions are described here, see the [Kube Audit Policy] for the standard rule behavior.
Expand All @@ -34,11 +34,11 @@ import auditv1 "k8s.io/apiserver/pkg/apis/audit/v1"
// - RequestResponse: All data is included: metadata, request body and response body. Note the response body can be very large.
// For example the a command like `oc get -A pods` generates a response body containing the YAML description of every pod in the cluster.
//
// # Extensions
// == Extensions
//
// The following features are extensions to the standard [Kube Audit Policy]
//
// ## Wildcards
// === Wildcards
//
// Names of users, groups, namespaces, and resources can have a leading or trailing '*' character.
// For example namespace 'openshift-*' matches 'openshift-apiserver' or 'openshift-authentication.
Expand All @@ -48,7 +48,7 @@ import auditv1 "k8s.io/apiserver/pkg/apis/audit/v1"
// fields with a forward slash. This means rules that rely upon a resource type that may or
// may not include the subresource should be adjusted to cover all the required use-cases (i.e. ['pod','pod/*']).
//
// ## Default Rules
// === Default Rules
//
// Events that do not match any rule in the policy are filtered as follows:
// - User events (ie. non-system and non-serviceaccount) are forwarded
Expand All @@ -59,7 +59,7 @@ import auditv1 "k8s.io/apiserver/pkg/apis/audit/v1"
// If you want to disable these defaults, end your rules list with rule that has only a `level` field.
// An empty rule matches any event, and prevents the defaults from taking effect.
//
// ## Omit Response Codes
// === Omit Response Codes
//
// You can drop events based on the HTTP status code in the response. See the OmitResponseCodes field.
//
Expand Down
2 changes: 1 addition & 1 deletion api/observability/v1/filter_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ type DropTest struct {
// +kubebuilder:validation:XValidation:rule="!(has(self.matches) && has(self.notMatches))", message="only one of matches or notMatches can be defined per field"
type DropCondition struct {
// A dot delimited path to a field in the log record. It must start with a `.`.
// The path can contain alpha-numeric characters and underscores (a-zA-Z0-9_).
// The path can contain alphanumeric characters and underscores (a-zA-Z0-9_).
// If segments contain characters outside of this range, the segment must be quoted.
// Examples: `.kubernetes.namespace_name`, `.log_type`, '.kubernetes.labels.foobar', `.kubernetes.labels."foo-bar/baz"`
//
Expand Down
2 changes: 1 addition & 1 deletion api/observability/v1/input_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ type ReceiverSpec struct {
// 1. http
// - Currently only supports kubernetes audit logs (log_type = "audit")
// 2. syslog
// - Currently only supports node infrastucture logs (log_type = "infrastructure")
// - Currently only supports node infrastructure logs (log_type = "infrastructure")
//
// +kubebuilder:validation:Required
// +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Receiver Type"
Expand Down
2 changes: 1 addition & 1 deletion api/observability/v1/output_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -1505,7 +1505,7 @@ type Syslog struct {
// +kubebuilder:validation:Optional
// +kubebuilder:validation:Pattern:=`^(([a-zA-Z0-9-_.\/])*(\{(\.[a-zA-Z0-9_]+|\."[^"]+")+((\|\|)(\.[a-zA-Z0-9_]+|\.?"[^"]+")+)*\|\|"[^"]*"\})*)*$`
// +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="App Name",xDescriptors={"urn:alm:descriptor:com.tectonic.ui:text"}
// TODO: DETERMIN HOW to default the app name that isnt based on fluentd assumptions of "tag" when this is empty
// TODO: DETERMINE HOW to default the app name that isn't based on fluentd assumptions of "tag" when this is empty
AppName string `json:"appName,omitempty"`

// ProcId is PROCID part of the syslog-msg header. This supports template syntax to allow dynamic per-event values.
Expand Down
4 changes: 2 additions & 2 deletions bundle/manifests/cluster-logging.clusterserviceversion.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ spec:
path: filters[0].drop[0].test
- description: |-
A dot delimited path to a field in the log record. It must start with a `.`.
The path can contain alpha-numeric characters and underscores (a-zA-Z0-9_).
The path can contain alphanumeric characters and underscores (a-zA-Z0-9_).
If segments contain characters outside of this range, the segment must be quoted.
Examples: `.kubernetes.namespace_name`, `.log_type`, '.kubernetes.labels.foobar', `.kubernetes.labels."foo-bar/baz"`
displayName: Field Path
Expand Down Expand Up @@ -462,7 +462,7 @@ spec:
1. http
- Currently only supports kubernetes audit logs (log_type = "audit")
2. syslog
- Currently only supports node infrastucture logs (log_type = "infrastructure")
- Currently only supports node infrastructure logs (log_type = "infrastructure")
displayName: Receiver Type
path: inputs[0].receiver.type
- description: Type of output sink.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1097,7 +1097,7 @@ spec:
field:
description: |-
A dot delimited path to a field in the log record. It must start with a `.`.
The path can contain alpha-numeric characters and underscores (a-zA-Z0-9_).
The path can contain alphanumeric characters and underscores (a-zA-Z0-9_).
If segments contain characters outside of this range, the segment must be quoted.
Examples: `.kubernetes.namespace_name`, `.log_type`, '.kubernetes.labels.foobar', `.kubernetes.labels."foo-bar/baz"`
pattern: ^(\.[a-zA-Z0-9_]+|\."[^"]+")(\.[a-zA-Z0-9_]+|\."[^"]+")*$
Expand Down Expand Up @@ -1129,7 +1129,7 @@ spec:
description: |-
KubeAPIAudit filter Kube API server audit logs, as described in [Kubernetes Auditing].

# Policy Filtering
== Policy Filtering

Policy event rules are the same format as the [Kube Audit Policy] with some minor extensions.
The extensions are described here, see the [Kube Audit Policy] for the standard rule behavior.
Expand All @@ -1145,11 +1145,11 @@ spec:
- RequestResponse: All data is included: metadata, request body and response body. Note the response body can be very large.
For example the a command like `oc get -A pods` generates a response body containing the YAML description of every pod in the cluster.

# Extensions
== Extensions

The following features are extensions to the standard [Kube Audit Policy]

## Wildcards
=== Wildcards

Names of users, groups, namespaces, and resources can have a leading or trailing '*' character.
For example namespace 'openshift-*' matches 'openshift-apiserver' or 'openshift-authentication.
Expand All @@ -1159,7 +1159,7 @@ spec:
fields with a forward slash. This means rules that rely upon a resource type that may or
may not include the subresource should be adjusted to cover all the required use-cases (i.e. ['pod','pod/*']).

## Default Rules
=== Default Rules

Events that do not match any rule in the policy are filtered as follows:
- User events (ie. non-system and non-serviceaccount) are forwarded
Expand All @@ -1170,7 +1170,7 @@ spec:
If you want to disable these defaults, end your rules list with rule that has only a `level` field.
An empty rule matches any event, and prevents the defaults from taking effect.

## Omit Response Codes
=== Omit Response Codes

You can drop events based on the HTTP status code in the response. See the OmitResponseCodes field.

Expand Down Expand Up @@ -1798,7 +1798,7 @@ spec:
1. http
- Currently only supports kubernetes audit logs (log_type = "audit")
2. syslog
- Currently only supports node infrastucture logs (log_type = "infrastructure")
- Currently only supports node infrastructure logs (log_type = "infrastructure")
enum:
- http
- syslog
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1097,7 +1097,7 @@ spec:
field:
description: |-
A dot delimited path to a field in the log record. It must start with a `.`.
The path can contain alpha-numeric characters and underscores (a-zA-Z0-9_).
The path can contain alphanumeric characters and underscores (a-zA-Z0-9_).
If segments contain characters outside of this range, the segment must be quoted.
Examples: `.kubernetes.namespace_name`, `.log_type`, '.kubernetes.labels.foobar', `.kubernetes.labels."foo-bar/baz"`
pattern: ^(\.[a-zA-Z0-9_]+|\."[^"]+")(\.[a-zA-Z0-9_]+|\."[^"]+")*$
Expand Down Expand Up @@ -1129,7 +1129,7 @@ spec:
description: |-
KubeAPIAudit filter Kube API server audit logs, as described in [Kubernetes Auditing].

# Policy Filtering
== Policy Filtering

Policy event rules are the same format as the [Kube Audit Policy] with some minor extensions.
The extensions are described here, see the [Kube Audit Policy] for the standard rule behavior.
Expand All @@ -1145,11 +1145,11 @@ spec:
- RequestResponse: All data is included: metadata, request body and response body. Note the response body can be very large.
For example the a command like `oc get -A pods` generates a response body containing the YAML description of every pod in the cluster.

# Extensions
== Extensions

The following features are extensions to the standard [Kube Audit Policy]

## Wildcards
=== Wildcards

Names of users, groups, namespaces, and resources can have a leading or trailing '*' character.
For example namespace 'openshift-*' matches 'openshift-apiserver' or 'openshift-authentication.
Expand All @@ -1159,7 +1159,7 @@ spec:
fields with a forward slash. This means rules that rely upon a resource type that may or
may not include the subresource should be adjusted to cover all the required use-cases (i.e. ['pod','pod/*']).

## Default Rules
=== Default Rules

Events that do not match any rule in the policy are filtered as follows:
- User events (ie. non-system and non-serviceaccount) are forwarded
Expand All @@ -1170,7 +1170,7 @@ spec:
If you want to disable these defaults, end your rules list with rule that has only a `level` field.
An empty rule matches any event, and prevents the defaults from taking effect.

## Omit Response Codes
=== Omit Response Codes

You can drop events based on the HTTP status code in the response. See the OmitResponseCodes field.

Expand Down Expand Up @@ -1798,7 +1798,7 @@ spec:
1. http
- Currently only supports kubernetes audit logs (log_type = "audit")
2. syslog
- Currently only supports node infrastucture logs (log_type = "infrastructure")
- Currently only supports node infrastructure logs (log_type = "infrastructure")
enum:
- http
- syslog
Expand Down
4 changes: 2 additions & 2 deletions config/docs/templates/datamodels/asciidoc/members.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

{{ if not (fieldEmbedded .Member) }}
=== {{ .Path }}
===== Description
==== Description
{{ $extra := "" }}
{{ if (isDeprecatedMember .Member) }}
{{ $extra = "**(DEPRECATED)**" }}
Expand All @@ -15,7 +15,7 @@
{{ end }}
{{$extra}} {{ (comments .CommentLines) }}

===== Type
==== Type
* {{ (yamlType .Type) }}
{{ end }}
{{ if not (or .Type.IsPrimitive (eq (yamlType .Type) "string")) }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ spec:
path: filters[0].drop[0].test
- description: |-
A dot delimited path to a field in the log record. It must start with a `.`.
The path can contain alpha-numeric characters and underscores (a-zA-Z0-9_).
The path can contain alphanumeric characters and underscores (a-zA-Z0-9_).
If segments contain characters outside of this range, the segment must be quoted.
Examples: `.kubernetes.namespace_name`, `.log_type`, '.kubernetes.labels.foobar', `.kubernetes.labels."foo-bar/baz"`
displayName: Field Path
Expand Down Expand Up @@ -385,7 +385,7 @@ spec:
1. http
- Currently only supports kubernetes audit logs (log_type = "audit")
2. syslog
- Currently only supports node infrastucture logs (log_type = "infrastructure")
- Currently only supports node infrastructure logs (log_type = "infrastructure")
displayName: Receiver Type
path: inputs[0].receiver.type
- description: Type of output sink.
Expand Down
4 changes: 2 additions & 2 deletions docs/README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ Open an issue in this repository
* link:administration/troubleshooting.md[Troubleshooting the cluster logging operator]
* link:administration/output_url_field.md[Using the clusterlogforwarder.output.url field]
* link:contributing/how-to-add-new-output.md[How-to add a new output type]
* link:features/logforwarding/outputs/google-cloud-forwarding.adoc[Forward logs to Google Cloud Logging]
* link:features/logforwarding/outputs/googlecloud/google-cloud-forwarding.adoc[Forward logs to Google Cloud Logging]
* link:features/logforwarding/outputs/splunk-forwarding.adoc[Forward logs to Splunk]
* link:features/logforwarding/outputs/send-logs-to-fluentd-http.adoc[Send logs to Fluentd over Http]
* link:features/logforwarding/filters/api-audit-filter.adoc[Filter API audit logs using a policiy]
* link:features/logforwarding/filters/api-audit-filter.adoc[Filter API audit logs using a policy]

== Relevant links

Expand Down
2 changes: 1 addition & 1 deletion docs/administration/clusterlogforwarder.adoc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
= Cluster Log Forwarding

The link:../reference/operator/api_observability_v1.adoc[ClusterLogForwarder] custom resource is the API for specifying the collection and forwarding
of cluster logs (e.g. application, infrastructure, audit). This API is part of the *observability.openshift.io* group and replaces the similiarly named
of cluster logs (e.g. application, infrastructure, audit). This API is part of the *observability.openshift.io* group and replaces the similarly named
link:https://github.com/openshift/cluster-logging-operator/blob/release-5.9/docs/reference/operator/api.adoc[resource] that was part of the *logging.openshift.io* group

== High-level Features
Expand Down
4 changes: 2 additions & 2 deletions docs/administration/lokistack.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Openshift LokiStack Docs:: https://docs.openshift.com/container-platform/4.16/ob
aws s3api create-bucket --acl private --region us-east-1 --bucket my-bucket-logging-loki
----
+
.Addtional option required for any region other than *us-east-1*
.Additional option required for any region other than *us-east-1*
----
--create-bucket-configuration LocationConstraint="$REGION"
----
Expand Down Expand Up @@ -392,7 +392,7 @@ For the internal loki gateway service, we use the url format *<service_name>.<na
----
NOTE: Use `logcli help` and `logcli query help` to see all options for interacting with loki

== Addtional References
== Additional References
Loki Operator user-guide:: https://github.com/grafana/loki/blob/main/operator/docs/user-guides/forwarding_logs_to_gateway.md
Loki Operator object-storage:: https://github.com/grafana/loki/blob/main/operator/docs/lokistack/object_storage.md
Observability Operator plugin:: https://github.com/rhobs/observability-operator/blob/main/docs/user-guides/observability-ui-plugins.md#logging
Expand Down
2 changes: 1 addition & 1 deletion docs/administration/upgrade/v6.0_changes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
== Overview
Logging version 6.0 is a major change from earlier releases and is the realization of several longstanding goals.

The following documentation is intended to assist administrators in converting exising **ClusterLogging.logging.openshift.io** and **ClusterLogForwarder.logging.openshift.io** specifications to the new observability API.
The following documentation is intended to assist administrators in converting existing **ClusterLogging.logging.openshift.io** and **ClusterLogForwarder.logging.openshift.io** specifications to the new observability API.

We've provided an overview of the changes, as well as complete **ClusterLogForwarder** resource examples for several common use cases.

Expand Down
Loading