Skip to content

Commit f5e7b87

Browse files
committed
add mermaid flowchart
Signed-off-by: Rita Zhang <[email protected]>
1 parent f76ea34 commit f5e7b87

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

keps/sig-auth/5018-dra-adminaccess/README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,9 +287,18 @@ been added to the REST storage layer to only authorize `ResourceClaim` or
287287
the `kubernetes.io/dra-admin-access` label to only allow it for users with
288288
additional privileges.
289289

290+
The below flowchart starts with `ResourceClaim` creation from
291+
`ResourceClaimTemplate` in kube-controller-manager and ends with the node
292+
operations.
293+
290294
```mermaid
291295
flowchart TD
292-
A[Admission Request to Create/Update ResourceClaim or ResourceClaimTemplate] --> B{adminAccess: true?}
296+
AA[Pod needs ResourceClaim for ResourceClaimTemplate] --> AB{adminAccess: true?}
297+
AB -- No --> A
298+
AB -- Yes --> AC{feature enabled?}
299+
AC -- No --> AY[refuse to create ResourceClaim, Pod remains pending]
300+
AC -- Yes --> A
301+
A[Request to API server to Create/Update ResourceClaim or ResourceClaimTemplate] --> B{adminAccess: true and feature enabled?}
293302
B -- No --> E
294303
B -- Yes --> D[Check Namespace Label]
295304
D -- Label Present --> E[Request Allowed]
@@ -298,6 +307,11 @@ flowchart TD
298307
G --> H[Kubernetes Scheduler evaluates ResourceClaim]
299308
H -- Admin Access Devices --> I[Skip allocation checks; Device is not allocated]
300309
H -- Standard Claims --> J[Proceed with standard allocation checks]
310+
J --> K
311+
I --> K
312+
K[kubelet asks DRA driver to prepare the ResourceClaim] --> L
313+
L[DRA driver reads full ResourceClaim] --> M
314+
M[DRA driver may grant additional permissions for devices with admin access]
301315
```
302316

303317
The `DRAAdminAccess` feature gate controls whether users can set the

0 commit comments

Comments
 (0)