Skip to content

Commit 1e1eab9

Browse files
committed
OCPBUGS-27426:Add admin groups info to NetObserv
1 parent 4902ae0 commit 1e1eab9

6 files changed

+35
-9
lines changed

logging/log_storage/cluster-logging-loki.adoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ ifdef::openshift-enterprise[]
3939
* xref:../../nodes/scheduling/nodes-scheduler-pod-topology-spread-constraints.adoc#nodes-scheduler-pod-topology-spread-constraints-configuring[Controlling pod placement by using pod topology spread constraints]
4040
endif::[]
4141

42-
include::modules/logging-loki-log-access.adoc[leveloffset=+1]
42+
include::modules/logging-loki-log-access.adoc[leveloffset=+1,tag=ForLoki]
43+
4344

4445
[role="_additional-resources"]
4546
.Additional resources

modules/logging-creating-new-group-cluster-admin-user-role.adoc

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// Module included in the following assemblies:
22

3-
// cluster-logging-loki.adoc
3+
// * cluster-logging-loki.adoc
4+
// * network_observability/installing-operators.adoc
45

56
:_mod-docs-content-type: PROCEDURE
67
[id="logging-creating-new-group-cluster-admin-user-role_{context}"]

modules/logging-loki-log-access.adoc

+29
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
// Module included in the following assemblies:
22
//
3+
// * network_observability/installing-operators.adoc
34
// * logging/cluster-logging-loki.adoc
45

56
:_mod-docs-content-type: CONCEPT
67
[id="logging-loki-log-access_{context}"]
8+
tag::ForLoki[]
79
= Fine grained access for Loki logs
810

911
In {logging} 5.8 and later, the {clo} does not grant all users access to logs by default. As an administrator, you must configure your users' access unless the Operator was upgraded and prior configurations are in place. Depending on your configuration and need, you can configure fine grain access to logs using the following:
@@ -93,3 +95,30 @@ spec:
9395
<1> Custom admin groups are only available in this mode.
9496
<2> Entering an empty list `[]` value for this field disables admin groups.
9597
<3> Overrides the default groups (`system:cluster-admins`, `cluster-admin`, `dedicated-admin`)
98+
end::ForLoki[]
99+
100+
tag::ForNetObserv[]
101+
= Custom admin group access
102+
103+
If you have a large deployment with a number of users who require broader permissions, you can create a custom group using the `adminGroup` field. Users who are members of any group specified in the `adminGroups` field of the `LokiStack` CR are considered admins. Admin users have access to all application logs in all namespaces, if they also get assigned the `cluster-logging-application-view` role.
104+
105+
.Example LokiStack CR
106+
[source,yaml]
107+
----
108+
apiVersion: loki.grafana.com/v1
109+
kind: LokiStack
110+
metadata:
111+
name: logging-loki
112+
namespace: openshift-logging
113+
spec:
114+
tenants:
115+
mode: openshift-network # <1>
116+
openshift:
117+
adminGroups: # <2>
118+
- cluster-admin
119+
- custom-admin-group # <3>
120+
----
121+
<1> Custom admin groups are only available in this mode.
122+
<2> Entering an empty list `[]` value for this field disables admin groups.
123+
<3> Overrides the default groups (`system:cluster-admins`, `cluster-admin`, `dedicated-admin`)
124+
end::ForNetObserv[]

modules/network-observability-lokistack-create.adoc

-3
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,6 @@
88

99
You can deploy a LokiStack using the web console or CLI to create a namespace, or new project.
1010

11-
include::snippets/logging-clusteradmin-access-logs-snip.adoc[]
12-
For more information about creating a `cluster-admin` group, see the "Additional resources" section.
13-
1411
.Procedure
1512

1613
. Navigate to *Operators* -> *Installed Operators*, viewing *All projects* from the *Project* dropdown.

network_observability/installing-operators.adoc

+2-3
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,9 @@ include::modules/network-observability-loki-secret.adoc[leveloffset=+2]
2929
* xref:../logging/log_storage/installing-log-storage.adoc#logging-loki-storage_installing-log-storage[Loki object storage]
3030
3131
include::modules/network-observability-lokistack-create.adoc[leveloffset=+2]
32+
include::modules/logging-creating-new-group-cluster-admin-user-role.adoc[leveloffset=+2]
33+
include::modules/logging-loki-log-access.adoc[leveloffset=+1,tag=ForNetObserv]
3234
33-
[role="_additional-resources"]
34-
.Additional resources
35-
* xref:../logging/log_storage/cluster-logging-loki.adoc#logging-creating-new-group-cluster-admin-user-role_cluster-logging-loki[Creating a new group for the cluster-admin user role]
3635
3736
include::modules/loki-deployment-sizing.adoc[leveloffset=+2]
3837
include::modules/network-observability-lokistack-ingestion-query.adoc[leveloffset=+2]

snippets/logging-clusteradmin-access-logs-snip.adoc

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
// Text snippet included in the following modules:
55
//
66
// * modules/logging-creating-new-group-cluster-admin-user-role.adoc
7-
// * modules/network-observability-lokistack-create.adoc
87
//
98
:_mod-docs-content-type: SNIPPET
109

0 commit comments

Comments
 (0)